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 Platform data
89	CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
90
91	// View, manage and query your Dialogflow agents
92	DialogflowScope = "https://www.googleapis.com/auth/dialogflow"
93)
94
95// NewService creates a new Service.
96func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
97	scopesOption := option.WithScopes(
98		"https://www.googleapis.com/auth/cloud-platform",
99		"https://www.googleapis.com/auth/dialogflow",
100	)
101	// NOTE: prepend, so we don't override user-specified scopes.
102	opts = append([]option.ClientOption{scopesOption}, opts...)
103	opts = append(opts, internaloption.WithDefaultEndpoint(basePath))
104	opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath))
105	client, endpoint, err := htransport.NewClient(ctx, opts...)
106	if err != nil {
107		return nil, err
108	}
109	s, err := New(client)
110	if err != nil {
111		return nil, err
112	}
113	if endpoint != "" {
114		s.BasePath = endpoint
115	}
116	return s, nil
117}
118
119// New creates a new Service. It uses the provided http.Client for requests.
120//
121// Deprecated: please use NewService instead.
122// To provide a custom HTTP client, use option.WithHTTPClient.
123// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
124func New(client *http.Client) (*Service, error) {
125	if client == nil {
126		return nil, errors.New("client is nil")
127	}
128	s := &Service{client: client, BasePath: basePath}
129	s.Projects = NewProjectsService(s)
130	return s, nil
131}
132
133type Service struct {
134	client    *http.Client
135	BasePath  string // API endpoint base URL
136	UserAgent string // optional additional User-Agent fragment
137
138	Projects *ProjectsService
139}
140
141func (s *Service) userAgent() string {
142	if s.UserAgent == "" {
143		return googleapi.UserAgent
144	}
145	return googleapi.UserAgent + " " + s.UserAgent
146}
147
148func NewProjectsService(s *Service) *ProjectsService {
149	rs := &ProjectsService{s: s}
150	rs.Agent = NewProjectsAgentService(s)
151	rs.AnswerRecords = NewProjectsAnswerRecordsService(s)
152	rs.ConversationProfiles = NewProjectsConversationProfilesService(s)
153	rs.Conversations = NewProjectsConversationsService(s)
154	rs.KnowledgeBases = NewProjectsKnowledgeBasesService(s)
155	rs.Locations = NewProjectsLocationsService(s)
156	rs.Operations = NewProjectsOperationsService(s)
157	return rs
158}
159
160type ProjectsService struct {
161	s *Service
162
163	Agent *ProjectsAgentService
164
165	AnswerRecords *ProjectsAnswerRecordsService
166
167	ConversationProfiles *ProjectsConversationProfilesService
168
169	Conversations *ProjectsConversationsService
170
171	KnowledgeBases *ProjectsKnowledgeBasesService
172
173	Locations *ProjectsLocationsService
174
175	Operations *ProjectsOperationsService
176}
177
178func NewProjectsAgentService(s *Service) *ProjectsAgentService {
179	rs := &ProjectsAgentService{s: s}
180	rs.EntityTypes = NewProjectsAgentEntityTypesService(s)
181	rs.Environments = NewProjectsAgentEnvironmentsService(s)
182	rs.Intents = NewProjectsAgentIntentsService(s)
183	rs.KnowledgeBases = NewProjectsAgentKnowledgeBasesService(s)
184	rs.Sessions = NewProjectsAgentSessionsService(s)
185	return rs
186}
187
188type ProjectsAgentService struct {
189	s *Service
190
191	EntityTypes *ProjectsAgentEntityTypesService
192
193	Environments *ProjectsAgentEnvironmentsService
194
195	Intents *ProjectsAgentIntentsService
196
197	KnowledgeBases *ProjectsAgentKnowledgeBasesService
198
199	Sessions *ProjectsAgentSessionsService
200}
201
202func NewProjectsAgentEntityTypesService(s *Service) *ProjectsAgentEntityTypesService {
203	rs := &ProjectsAgentEntityTypesService{s: s}
204	rs.Entities = NewProjectsAgentEntityTypesEntitiesService(s)
205	return rs
206}
207
208type ProjectsAgentEntityTypesService struct {
209	s *Service
210
211	Entities *ProjectsAgentEntityTypesEntitiesService
212}
213
214func NewProjectsAgentEntityTypesEntitiesService(s *Service) *ProjectsAgentEntityTypesEntitiesService {
215	rs := &ProjectsAgentEntityTypesEntitiesService{s: s}
216	return rs
217}
218
219type ProjectsAgentEntityTypesEntitiesService struct {
220	s *Service
221}
222
223func NewProjectsAgentEnvironmentsService(s *Service) *ProjectsAgentEnvironmentsService {
224	rs := &ProjectsAgentEnvironmentsService{s: s}
225	rs.Intents = NewProjectsAgentEnvironmentsIntentsService(s)
226	rs.Users = NewProjectsAgentEnvironmentsUsersService(s)
227	return rs
228}
229
230type ProjectsAgentEnvironmentsService struct {
231	s *Service
232
233	Intents *ProjectsAgentEnvironmentsIntentsService
234
235	Users *ProjectsAgentEnvironmentsUsersService
236}
237
238func NewProjectsAgentEnvironmentsIntentsService(s *Service) *ProjectsAgentEnvironmentsIntentsService {
239	rs := &ProjectsAgentEnvironmentsIntentsService{s: s}
240	return rs
241}
242
243type ProjectsAgentEnvironmentsIntentsService struct {
244	s *Service
245}
246
247func NewProjectsAgentEnvironmentsUsersService(s *Service) *ProjectsAgentEnvironmentsUsersService {
248	rs := &ProjectsAgentEnvironmentsUsersService{s: s}
249	rs.Sessions = NewProjectsAgentEnvironmentsUsersSessionsService(s)
250	return rs
251}
252
253type ProjectsAgentEnvironmentsUsersService struct {
254	s *Service
255
256	Sessions *ProjectsAgentEnvironmentsUsersSessionsService
257}
258
259func NewProjectsAgentEnvironmentsUsersSessionsService(s *Service) *ProjectsAgentEnvironmentsUsersSessionsService {
260	rs := &ProjectsAgentEnvironmentsUsersSessionsService{s: s}
261	rs.Contexts = NewProjectsAgentEnvironmentsUsersSessionsContextsService(s)
262	rs.EntityTypes = NewProjectsAgentEnvironmentsUsersSessionsEntityTypesService(s)
263	return rs
264}
265
266type ProjectsAgentEnvironmentsUsersSessionsService struct {
267	s *Service
268
269	Contexts *ProjectsAgentEnvironmentsUsersSessionsContextsService
270
271	EntityTypes *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService
272}
273
274func NewProjectsAgentEnvironmentsUsersSessionsContextsService(s *Service) *ProjectsAgentEnvironmentsUsersSessionsContextsService {
275	rs := &ProjectsAgentEnvironmentsUsersSessionsContextsService{s: s}
276	return rs
277}
278
279type ProjectsAgentEnvironmentsUsersSessionsContextsService struct {
280	s *Service
281}
282
283func NewProjectsAgentEnvironmentsUsersSessionsEntityTypesService(s *Service) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService {
284	rs := &ProjectsAgentEnvironmentsUsersSessionsEntityTypesService{s: s}
285	return rs
286}
287
288type ProjectsAgentEnvironmentsUsersSessionsEntityTypesService struct {
289	s *Service
290}
291
292func NewProjectsAgentIntentsService(s *Service) *ProjectsAgentIntentsService {
293	rs := &ProjectsAgentIntentsService{s: s}
294	return rs
295}
296
297type ProjectsAgentIntentsService struct {
298	s *Service
299}
300
301func NewProjectsAgentKnowledgeBasesService(s *Service) *ProjectsAgentKnowledgeBasesService {
302	rs := &ProjectsAgentKnowledgeBasesService{s: s}
303	rs.Documents = NewProjectsAgentKnowledgeBasesDocumentsService(s)
304	return rs
305}
306
307type ProjectsAgentKnowledgeBasesService struct {
308	s *Service
309
310	Documents *ProjectsAgentKnowledgeBasesDocumentsService
311}
312
313func NewProjectsAgentKnowledgeBasesDocumentsService(s *Service) *ProjectsAgentKnowledgeBasesDocumentsService {
314	rs := &ProjectsAgentKnowledgeBasesDocumentsService{s: s}
315	return rs
316}
317
318type ProjectsAgentKnowledgeBasesDocumentsService struct {
319	s *Service
320}
321
322func NewProjectsAgentSessionsService(s *Service) *ProjectsAgentSessionsService {
323	rs := &ProjectsAgentSessionsService{s: s}
324	rs.Contexts = NewProjectsAgentSessionsContextsService(s)
325	rs.EntityTypes = NewProjectsAgentSessionsEntityTypesService(s)
326	return rs
327}
328
329type ProjectsAgentSessionsService struct {
330	s *Service
331
332	Contexts *ProjectsAgentSessionsContextsService
333
334	EntityTypes *ProjectsAgentSessionsEntityTypesService
335}
336
337func NewProjectsAgentSessionsContextsService(s *Service) *ProjectsAgentSessionsContextsService {
338	rs := &ProjectsAgentSessionsContextsService{s: s}
339	return rs
340}
341
342type ProjectsAgentSessionsContextsService struct {
343	s *Service
344}
345
346func NewProjectsAgentSessionsEntityTypesService(s *Service) *ProjectsAgentSessionsEntityTypesService {
347	rs := &ProjectsAgentSessionsEntityTypesService{s: s}
348	return rs
349}
350
351type ProjectsAgentSessionsEntityTypesService struct {
352	s *Service
353}
354
355func NewProjectsAnswerRecordsService(s *Service) *ProjectsAnswerRecordsService {
356	rs := &ProjectsAnswerRecordsService{s: s}
357	return rs
358}
359
360type ProjectsAnswerRecordsService struct {
361	s *Service
362}
363
364func NewProjectsConversationProfilesService(s *Service) *ProjectsConversationProfilesService {
365	rs := &ProjectsConversationProfilesService{s: s}
366	return rs
367}
368
369type ProjectsConversationProfilesService struct {
370	s *Service
371}
372
373func NewProjectsConversationsService(s *Service) *ProjectsConversationsService {
374	rs := &ProjectsConversationsService{s: s}
375	rs.Messages = NewProjectsConversationsMessagesService(s)
376	rs.Participants = NewProjectsConversationsParticipantsService(s)
377	return rs
378}
379
380type ProjectsConversationsService struct {
381	s *Service
382
383	Messages *ProjectsConversationsMessagesService
384
385	Participants *ProjectsConversationsParticipantsService
386}
387
388func NewProjectsConversationsMessagesService(s *Service) *ProjectsConversationsMessagesService {
389	rs := &ProjectsConversationsMessagesService{s: s}
390	return rs
391}
392
393type ProjectsConversationsMessagesService struct {
394	s *Service
395}
396
397func NewProjectsConversationsParticipantsService(s *Service) *ProjectsConversationsParticipantsService {
398	rs := &ProjectsConversationsParticipantsService{s: s}
399	rs.Suggestions = NewProjectsConversationsParticipantsSuggestionsService(s)
400	return rs
401}
402
403type ProjectsConversationsParticipantsService struct {
404	s *Service
405
406	Suggestions *ProjectsConversationsParticipantsSuggestionsService
407}
408
409func NewProjectsConversationsParticipantsSuggestionsService(s *Service) *ProjectsConversationsParticipantsSuggestionsService {
410	rs := &ProjectsConversationsParticipantsSuggestionsService{s: s}
411	return rs
412}
413
414type ProjectsConversationsParticipantsSuggestionsService struct {
415	s *Service
416}
417
418func NewProjectsKnowledgeBasesService(s *Service) *ProjectsKnowledgeBasesService {
419	rs := &ProjectsKnowledgeBasesService{s: s}
420	rs.Documents = NewProjectsKnowledgeBasesDocumentsService(s)
421	return rs
422}
423
424type ProjectsKnowledgeBasesService struct {
425	s *Service
426
427	Documents *ProjectsKnowledgeBasesDocumentsService
428}
429
430func NewProjectsKnowledgeBasesDocumentsService(s *Service) *ProjectsKnowledgeBasesDocumentsService {
431	rs := &ProjectsKnowledgeBasesDocumentsService{s: s}
432	return rs
433}
434
435type ProjectsKnowledgeBasesDocumentsService struct {
436	s *Service
437}
438
439func NewProjectsLocationsService(s *Service) *ProjectsLocationsService {
440	rs := &ProjectsLocationsService{s: s}
441	rs.Agent = NewProjectsLocationsAgentService(s)
442	rs.AnswerRecords = NewProjectsLocationsAnswerRecordsService(s)
443	rs.ConversationProfiles = NewProjectsLocationsConversationProfilesService(s)
444	rs.Conversations = NewProjectsLocationsConversationsService(s)
445	rs.KnowledgeBases = NewProjectsLocationsKnowledgeBasesService(s)
446	rs.Operations = NewProjectsLocationsOperationsService(s)
447	return rs
448}
449
450type ProjectsLocationsService struct {
451	s *Service
452
453	Agent *ProjectsLocationsAgentService
454
455	AnswerRecords *ProjectsLocationsAnswerRecordsService
456
457	ConversationProfiles *ProjectsLocationsConversationProfilesService
458
459	Conversations *ProjectsLocationsConversationsService
460
461	KnowledgeBases *ProjectsLocationsKnowledgeBasesService
462
463	Operations *ProjectsLocationsOperationsService
464}
465
466func NewProjectsLocationsAgentService(s *Service) *ProjectsLocationsAgentService {
467	rs := &ProjectsLocationsAgentService{s: s}
468	rs.EntityTypes = NewProjectsLocationsAgentEntityTypesService(s)
469	rs.Environments = NewProjectsLocationsAgentEnvironmentsService(s)
470	rs.Intents = NewProjectsLocationsAgentIntentsService(s)
471	rs.Sessions = NewProjectsLocationsAgentSessionsService(s)
472	return rs
473}
474
475type ProjectsLocationsAgentService struct {
476	s *Service
477
478	EntityTypes *ProjectsLocationsAgentEntityTypesService
479
480	Environments *ProjectsLocationsAgentEnvironmentsService
481
482	Intents *ProjectsLocationsAgentIntentsService
483
484	Sessions *ProjectsLocationsAgentSessionsService
485}
486
487func NewProjectsLocationsAgentEntityTypesService(s *Service) *ProjectsLocationsAgentEntityTypesService {
488	rs := &ProjectsLocationsAgentEntityTypesService{s: s}
489	rs.Entities = NewProjectsLocationsAgentEntityTypesEntitiesService(s)
490	return rs
491}
492
493type ProjectsLocationsAgentEntityTypesService struct {
494	s *Service
495
496	Entities *ProjectsLocationsAgentEntityTypesEntitiesService
497}
498
499func NewProjectsLocationsAgentEntityTypesEntitiesService(s *Service) *ProjectsLocationsAgentEntityTypesEntitiesService {
500	rs := &ProjectsLocationsAgentEntityTypesEntitiesService{s: s}
501	return rs
502}
503
504type ProjectsLocationsAgentEntityTypesEntitiesService struct {
505	s *Service
506}
507
508func NewProjectsLocationsAgentEnvironmentsService(s *Service) *ProjectsLocationsAgentEnvironmentsService {
509	rs := &ProjectsLocationsAgentEnvironmentsService{s: s}
510	rs.Users = NewProjectsLocationsAgentEnvironmentsUsersService(s)
511	return rs
512}
513
514type ProjectsLocationsAgentEnvironmentsService struct {
515	s *Service
516
517	Users *ProjectsLocationsAgentEnvironmentsUsersService
518}
519
520func NewProjectsLocationsAgentEnvironmentsUsersService(s *Service) *ProjectsLocationsAgentEnvironmentsUsersService {
521	rs := &ProjectsLocationsAgentEnvironmentsUsersService{s: s}
522	rs.Sessions = NewProjectsLocationsAgentEnvironmentsUsersSessionsService(s)
523	return rs
524}
525
526type ProjectsLocationsAgentEnvironmentsUsersService struct {
527	s *Service
528
529	Sessions *ProjectsLocationsAgentEnvironmentsUsersSessionsService
530}
531
532func NewProjectsLocationsAgentEnvironmentsUsersSessionsService(s *Service) *ProjectsLocationsAgentEnvironmentsUsersSessionsService {
533	rs := &ProjectsLocationsAgentEnvironmentsUsersSessionsService{s: s}
534	rs.Contexts = NewProjectsLocationsAgentEnvironmentsUsersSessionsContextsService(s)
535	rs.EntityTypes = NewProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService(s)
536	return rs
537}
538
539type ProjectsLocationsAgentEnvironmentsUsersSessionsService struct {
540	s *Service
541
542	Contexts *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService
543
544	EntityTypes *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService
545}
546
547func NewProjectsLocationsAgentEnvironmentsUsersSessionsContextsService(s *Service) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService {
548	rs := &ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService{s: s}
549	return rs
550}
551
552type ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService struct {
553	s *Service
554}
555
556func NewProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService(s *Service) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService {
557	rs := &ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService{s: s}
558	return rs
559}
560
561type ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService struct {
562	s *Service
563}
564
565func NewProjectsLocationsAgentIntentsService(s *Service) *ProjectsLocationsAgentIntentsService {
566	rs := &ProjectsLocationsAgentIntentsService{s: s}
567	return rs
568}
569
570type ProjectsLocationsAgentIntentsService struct {
571	s *Service
572}
573
574func NewProjectsLocationsAgentSessionsService(s *Service) *ProjectsLocationsAgentSessionsService {
575	rs := &ProjectsLocationsAgentSessionsService{s: s}
576	rs.Contexts = NewProjectsLocationsAgentSessionsContextsService(s)
577	rs.EntityTypes = NewProjectsLocationsAgentSessionsEntityTypesService(s)
578	return rs
579}
580
581type ProjectsLocationsAgentSessionsService struct {
582	s *Service
583
584	Contexts *ProjectsLocationsAgentSessionsContextsService
585
586	EntityTypes *ProjectsLocationsAgentSessionsEntityTypesService
587}
588
589func NewProjectsLocationsAgentSessionsContextsService(s *Service) *ProjectsLocationsAgentSessionsContextsService {
590	rs := &ProjectsLocationsAgentSessionsContextsService{s: s}
591	return rs
592}
593
594type ProjectsLocationsAgentSessionsContextsService struct {
595	s *Service
596}
597
598func NewProjectsLocationsAgentSessionsEntityTypesService(s *Service) *ProjectsLocationsAgentSessionsEntityTypesService {
599	rs := &ProjectsLocationsAgentSessionsEntityTypesService{s: s}
600	return rs
601}
602
603type ProjectsLocationsAgentSessionsEntityTypesService struct {
604	s *Service
605}
606
607func NewProjectsLocationsAnswerRecordsService(s *Service) *ProjectsLocationsAnswerRecordsService {
608	rs := &ProjectsLocationsAnswerRecordsService{s: s}
609	return rs
610}
611
612type ProjectsLocationsAnswerRecordsService struct {
613	s *Service
614}
615
616func NewProjectsLocationsConversationProfilesService(s *Service) *ProjectsLocationsConversationProfilesService {
617	rs := &ProjectsLocationsConversationProfilesService{s: s}
618	return rs
619}
620
621type ProjectsLocationsConversationProfilesService struct {
622	s *Service
623}
624
625func NewProjectsLocationsConversationsService(s *Service) *ProjectsLocationsConversationsService {
626	rs := &ProjectsLocationsConversationsService{s: s}
627	rs.Messages = NewProjectsLocationsConversationsMessagesService(s)
628	rs.Participants = NewProjectsLocationsConversationsParticipantsService(s)
629	return rs
630}
631
632type ProjectsLocationsConversationsService struct {
633	s *Service
634
635	Messages *ProjectsLocationsConversationsMessagesService
636
637	Participants *ProjectsLocationsConversationsParticipantsService
638}
639
640func NewProjectsLocationsConversationsMessagesService(s *Service) *ProjectsLocationsConversationsMessagesService {
641	rs := &ProjectsLocationsConversationsMessagesService{s: s}
642	return rs
643}
644
645type ProjectsLocationsConversationsMessagesService struct {
646	s *Service
647}
648
649func NewProjectsLocationsConversationsParticipantsService(s *Service) *ProjectsLocationsConversationsParticipantsService {
650	rs := &ProjectsLocationsConversationsParticipantsService{s: s}
651	rs.Suggestions = NewProjectsLocationsConversationsParticipantsSuggestionsService(s)
652	return rs
653}
654
655type ProjectsLocationsConversationsParticipantsService struct {
656	s *Service
657
658	Suggestions *ProjectsLocationsConversationsParticipantsSuggestionsService
659}
660
661func NewProjectsLocationsConversationsParticipantsSuggestionsService(s *Service) *ProjectsLocationsConversationsParticipantsSuggestionsService {
662	rs := &ProjectsLocationsConversationsParticipantsSuggestionsService{s: s}
663	return rs
664}
665
666type ProjectsLocationsConversationsParticipantsSuggestionsService struct {
667	s *Service
668}
669
670func NewProjectsLocationsKnowledgeBasesService(s *Service) *ProjectsLocationsKnowledgeBasesService {
671	rs := &ProjectsLocationsKnowledgeBasesService{s: s}
672	rs.Documents = NewProjectsLocationsKnowledgeBasesDocumentsService(s)
673	return rs
674}
675
676type ProjectsLocationsKnowledgeBasesService struct {
677	s *Service
678
679	Documents *ProjectsLocationsKnowledgeBasesDocumentsService
680}
681
682func NewProjectsLocationsKnowledgeBasesDocumentsService(s *Service) *ProjectsLocationsKnowledgeBasesDocumentsService {
683	rs := &ProjectsLocationsKnowledgeBasesDocumentsService{s: s}
684	return rs
685}
686
687type ProjectsLocationsKnowledgeBasesDocumentsService struct {
688	s *Service
689}
690
691func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService {
692	rs := &ProjectsLocationsOperationsService{s: s}
693	return rs
694}
695
696type ProjectsLocationsOperationsService struct {
697	s *Service
698}
699
700func NewProjectsOperationsService(s *Service) *ProjectsOperationsService {
701	rs := &ProjectsOperationsService{s: s}
702	return rs
703}
704
705type ProjectsOperationsService struct {
706	s *Service
707}
708
709// GoogleCloudDialogflowCxV3AudioInput: Represents the natural speech
710// audio to be processed.
711type GoogleCloudDialogflowCxV3AudioInput struct {
712	// Audio: The natural language speech audio to be processed. A single
713	// request can contain up to 1 minute of speech audio data. The
714	// transcribed text cannot contain more than 256 bytes. For
715	// non-streaming audio detect intent, both `config` and `audio` must be
716	// provided. For streaming audio detect intent, `config` must be
717	// provided in the first request and `audio` must be provided in all
718	// following requests.
719	Audio string `json:"audio,omitempty"`
720
721	// Config: Required. Instructs the speech recognizer how to process the
722	// speech audio.
723	Config *GoogleCloudDialogflowCxV3InputAudioConfig `json:"config,omitempty"`
724
725	// ForceSendFields is a list of field names (e.g. "Audio") to
726	// unconditionally include in API requests. By default, fields with
727	// empty values are omitted from API requests. However, any non-pointer,
728	// non-interface field appearing in ForceSendFields will be sent to the
729	// server regardless of whether the field is empty or not. This may be
730	// used to include empty fields in Patch requests.
731	ForceSendFields []string `json:"-"`
732
733	// NullFields is a list of field names (e.g. "Audio") to include in API
734	// requests with the JSON null value. By default, fields with empty
735	// values are omitted from API requests. However, any field with an
736	// empty value appearing in NullFields will be sent to the server as
737	// null. It is an error if a field in this list has a non-empty value.
738	// This may be used to include null fields in Patch requests.
739	NullFields []string `json:"-"`
740}
741
742func (s *GoogleCloudDialogflowCxV3AudioInput) MarshalJSON() ([]byte, error) {
743	type NoMethod GoogleCloudDialogflowCxV3AudioInput
744	raw := NoMethod(*s)
745	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
746}
747
748// GoogleCloudDialogflowCxV3BatchRunTestCasesMetadata: Metadata returned
749// for the TestCases.BatchRunTestCases long running operation.
750type GoogleCloudDialogflowCxV3BatchRunTestCasesMetadata struct {
751	// Errors: The test errors.
752	Errors []*GoogleCloudDialogflowCxV3TestError `json:"errors,omitempty"`
753
754	// ForceSendFields is a list of field names (e.g. "Errors") to
755	// unconditionally include in API requests. By default, fields with
756	// empty values are omitted from API requests. However, any non-pointer,
757	// non-interface field appearing in ForceSendFields will be sent to the
758	// server regardless of whether the field is empty or not. This may be
759	// used to include empty fields in Patch requests.
760	ForceSendFields []string `json:"-"`
761
762	// NullFields is a list of field names (e.g. "Errors") to include in API
763	// requests with the JSON null value. By default, fields with empty
764	// values are omitted from API requests. However, any field with an
765	// empty value appearing in NullFields will be sent to the server as
766	// null. It is an error if a field in this list has a non-empty value.
767	// This may be used to include null fields in Patch requests.
768	NullFields []string `json:"-"`
769}
770
771func (s *GoogleCloudDialogflowCxV3BatchRunTestCasesMetadata) MarshalJSON() ([]byte, error) {
772	type NoMethod GoogleCloudDialogflowCxV3BatchRunTestCasesMetadata
773	raw := NoMethod(*s)
774	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
775}
776
777// GoogleCloudDialogflowCxV3BatchRunTestCasesResponse: The response
778// message for TestCases.BatchRunTestCases.
779type GoogleCloudDialogflowCxV3BatchRunTestCasesResponse struct {
780	// Results: The test case results. The detailed conversation turns are
781	// empty in this response.
782	Results []*GoogleCloudDialogflowCxV3TestCaseResult `json:"results,omitempty"`
783
784	// ForceSendFields is a list of field names (e.g. "Results") to
785	// unconditionally include in API requests. By default, fields with
786	// empty values are omitted from API requests. However, any non-pointer,
787	// non-interface field appearing in ForceSendFields will be sent to the
788	// server regardless of whether the field is empty or not. This may be
789	// used to include empty fields in Patch requests.
790	ForceSendFields []string `json:"-"`
791
792	// NullFields is a list of field names (e.g. "Results") to include in
793	// API requests with the JSON null value. By default, fields with empty
794	// values are omitted from API requests. However, any field with an
795	// empty value appearing in NullFields will be sent to the server as
796	// null. It is an error if a field in this list has a non-empty value.
797	// This may be used to include null fields in Patch requests.
798	NullFields []string `json:"-"`
799}
800
801func (s *GoogleCloudDialogflowCxV3BatchRunTestCasesResponse) MarshalJSON() ([]byte, error) {
802	type NoMethod GoogleCloudDialogflowCxV3BatchRunTestCasesResponse
803	raw := NoMethod(*s)
804	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
805}
806
807// GoogleCloudDialogflowCxV3ConversationTurn: One interaction between a
808// human and virtual agent. The human provides some input and the
809// virtual agent provides a response.
810type GoogleCloudDialogflowCxV3ConversationTurn struct {
811	// UserInput: The user input.
812	UserInput *GoogleCloudDialogflowCxV3ConversationTurnUserInput `json:"userInput,omitempty"`
813
814	// VirtualAgentOutput: The virtual agent output.
815	VirtualAgentOutput *GoogleCloudDialogflowCxV3ConversationTurnVirtualAgentOutput `json:"virtualAgentOutput,omitempty"`
816
817	// ForceSendFields is a list of field names (e.g. "UserInput") to
818	// unconditionally include in API requests. By default, fields with
819	// empty values are omitted from API requests. However, any non-pointer,
820	// non-interface field appearing in ForceSendFields will be sent to the
821	// server regardless of whether the field is empty or not. This may be
822	// used to include empty fields in Patch requests.
823	ForceSendFields []string `json:"-"`
824
825	// NullFields is a list of field names (e.g. "UserInput") to include in
826	// API requests with the JSON null value. By default, fields with empty
827	// values are omitted from API requests. However, any field with an
828	// empty value appearing in NullFields will be sent to the server as
829	// null. It is an error if a field in this list has a non-empty value.
830	// This may be used to include null fields in Patch requests.
831	NullFields []string `json:"-"`
832}
833
834func (s *GoogleCloudDialogflowCxV3ConversationTurn) MarshalJSON() ([]byte, error) {
835	type NoMethod GoogleCloudDialogflowCxV3ConversationTurn
836	raw := NoMethod(*s)
837	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
838}
839
840// GoogleCloudDialogflowCxV3ConversationTurnUserInput: The input from
841// the human user.
842type GoogleCloudDialogflowCxV3ConversationTurnUserInput struct {
843	// InjectedParameters: Parameters that need to be injected into the
844	// conversation during intent detection.
845	InjectedParameters googleapi.RawMessage `json:"injectedParameters,omitempty"`
846
847	// Input: Supports text input, event input, dtmf input in the test case.
848	Input *GoogleCloudDialogflowCxV3QueryInput `json:"input,omitempty"`
849
850	// IsWebhookEnabled: If webhooks should be allowed to trigger in
851	// response to the user utterance. Often if parameters are injected,
852	// webhooks should not be enabled.
853	IsWebhookEnabled bool `json:"isWebhookEnabled,omitempty"`
854
855	// ForceSendFields is a list of field names (e.g. "InjectedParameters")
856	// to unconditionally include in API requests. By default, fields with
857	// empty values are omitted from API requests. However, any non-pointer,
858	// non-interface field appearing in ForceSendFields will be sent to the
859	// server regardless of whether the field is empty or not. This may be
860	// used to include empty fields in Patch requests.
861	ForceSendFields []string `json:"-"`
862
863	// NullFields is a list of field names (e.g. "InjectedParameters") to
864	// include in API requests with the JSON null value. By default, fields
865	// with empty values are omitted from API requests. However, any field
866	// with an empty value appearing in NullFields will be sent to the
867	// server as null. It is an error if a field in this list has a
868	// non-empty value. This may be used to include null fields in Patch
869	// requests.
870	NullFields []string `json:"-"`
871}
872
873func (s *GoogleCloudDialogflowCxV3ConversationTurnUserInput) MarshalJSON() ([]byte, error) {
874	type NoMethod GoogleCloudDialogflowCxV3ConversationTurnUserInput
875	raw := NoMethod(*s)
876	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
877}
878
879// GoogleCloudDialogflowCxV3ConversationTurnVirtualAgentOutput: The
880// output from the virtual agent.
881type GoogleCloudDialogflowCxV3ConversationTurnVirtualAgentOutput struct {
882	// CurrentPage: The Page on which the utterance was spoken. Only name
883	// and displayName will be set.
884	CurrentPage *GoogleCloudDialogflowCxV3Page `json:"currentPage,omitempty"`
885
886	// DiagnosticInfo: Required. Input only. The diagnostic info output for
887	// the turn.
888	DiagnosticInfo googleapi.RawMessage `json:"diagnosticInfo,omitempty"`
889
890	// Differences: Output only. If this is part of a result conversation
891	// turn, the list of differences between the original run and the replay
892	// for this output, if any.
893	Differences []*GoogleCloudDialogflowCxV3TestRunDifference `json:"differences,omitempty"`
894
895	// SessionParameters: The session parameters available to the bot at
896	// this point.
897	SessionParameters googleapi.RawMessage `json:"sessionParameters,omitempty"`
898
899	// Status: Response error from the agent in the test result. If set,
900	// other output is empty.
901	Status *GoogleRpcStatus `json:"status,omitempty"`
902
903	// TextResponses: The text responses from the agent for the turn.
904	TextResponses []*GoogleCloudDialogflowCxV3ResponseMessageText `json:"textResponses,omitempty"`
905
906	// TriggeredIntent: The Intent that triggered the response. Only name
907	// and displayName will be set.
908	TriggeredIntent *GoogleCloudDialogflowCxV3Intent `json:"triggeredIntent,omitempty"`
909
910	// ForceSendFields is a list of field names (e.g. "CurrentPage") to
911	// unconditionally include in API requests. By default, fields with
912	// empty values are omitted from API requests. However, any non-pointer,
913	// non-interface field appearing in ForceSendFields will be sent to the
914	// server regardless of whether the field is empty or not. This may be
915	// used to include empty fields in Patch requests.
916	ForceSendFields []string `json:"-"`
917
918	// NullFields is a list of field names (e.g. "CurrentPage") to include
919	// in API requests with the JSON null value. By default, fields with
920	// empty values are omitted from API requests. However, any field with
921	// an empty value appearing in NullFields will be sent to the server as
922	// null. It is an error if a field in this list has a non-empty value.
923	// This may be used to include null fields in Patch requests.
924	NullFields []string `json:"-"`
925}
926
927func (s *GoogleCloudDialogflowCxV3ConversationTurnVirtualAgentOutput) MarshalJSON() ([]byte, error) {
928	type NoMethod GoogleCloudDialogflowCxV3ConversationTurnVirtualAgentOutput
929	raw := NoMethod(*s)
930	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
931}
932
933// GoogleCloudDialogflowCxV3CreateDocumentOperationMetadata: Metadata
934// for CreateDocument operation.
935type GoogleCloudDialogflowCxV3CreateDocumentOperationMetadata struct {
936	// GenericMetadata: The generic information of the operation.
937	GenericMetadata *GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
938
939	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
940	// unconditionally include in API requests. By default, fields with
941	// empty values are omitted from API requests. However, any non-pointer,
942	// non-interface field appearing in ForceSendFields will be sent to the
943	// server regardless of whether the field is empty or not. This may be
944	// used to include empty fields in Patch requests.
945	ForceSendFields []string `json:"-"`
946
947	// NullFields is a list of field names (e.g. "GenericMetadata") to
948	// include in API requests with the JSON null value. By default, fields
949	// with empty values are omitted from API requests. However, any field
950	// with an empty value appearing in NullFields will be sent to the
951	// server as null. It is an error if a field in this list has a
952	// non-empty value. This may be used to include null fields in Patch
953	// requests.
954	NullFields []string `json:"-"`
955}
956
957func (s *GoogleCloudDialogflowCxV3CreateDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
958	type NoMethod GoogleCloudDialogflowCxV3CreateDocumentOperationMetadata
959	raw := NoMethod(*s)
960	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
961}
962
963// GoogleCloudDialogflowCxV3CreateVersionOperationMetadata: Metadata
964// associated with the long running operation for
965// Versions.CreateVersion.
966type GoogleCloudDialogflowCxV3CreateVersionOperationMetadata struct {
967	// Version: Name of the created version. Format:
968	// `projects//locations//agents//flows//versions/`.
969	Version string `json:"version,omitempty"`
970
971	// ForceSendFields is a list of field names (e.g. "Version") to
972	// unconditionally include in API requests. By default, fields with
973	// empty values are omitted from API requests. However, any non-pointer,
974	// non-interface field appearing in ForceSendFields will be sent to the
975	// server regardless of whether the field is empty or not. This may be
976	// used to include empty fields in Patch requests.
977	ForceSendFields []string `json:"-"`
978
979	// NullFields is a list of field names (e.g. "Version") to include in
980	// API requests with the JSON null value. By default, fields with empty
981	// values are omitted from API requests. However, any field with an
982	// empty value appearing in NullFields will be sent to the server as
983	// null. It is an error if a field in this list has a non-empty value.
984	// This may be used to include null fields in Patch requests.
985	NullFields []string `json:"-"`
986}
987
988func (s *GoogleCloudDialogflowCxV3CreateVersionOperationMetadata) MarshalJSON() ([]byte, error) {
989	type NoMethod GoogleCloudDialogflowCxV3CreateVersionOperationMetadata
990	raw := NoMethod(*s)
991	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
992}
993
994// GoogleCloudDialogflowCxV3DeleteDocumentOperationMetadata: Metadata
995// for DeleteDocument operation.
996type GoogleCloudDialogflowCxV3DeleteDocumentOperationMetadata struct {
997	// GenericMetadata: The generic information of the operation.
998	GenericMetadata *GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
999
1000	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
1001	// unconditionally include in API requests. By default, fields with
1002	// empty values are omitted from API requests. However, any non-pointer,
1003	// non-interface field appearing in ForceSendFields will be sent to the
1004	// server regardless of whether the field is empty or not. This may be
1005	// used to include empty fields in Patch requests.
1006	ForceSendFields []string `json:"-"`
1007
1008	// NullFields is a list of field names (e.g. "GenericMetadata") to
1009	// include in API requests with the JSON null value. By default, fields
1010	// with empty values are omitted from API requests. However, any field
1011	// with an empty value appearing in NullFields will be sent to the
1012	// server as null. It is an error if a field in this list has a
1013	// non-empty value. This may be used to include null fields in Patch
1014	// requests.
1015	NullFields []string `json:"-"`
1016}
1017
1018func (s *GoogleCloudDialogflowCxV3DeleteDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
1019	type NoMethod GoogleCloudDialogflowCxV3DeleteDocumentOperationMetadata
1020	raw := NoMethod(*s)
1021	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1022}
1023
1024// GoogleCloudDialogflowCxV3DtmfInput: Represents the input for dtmf
1025// event.
1026type GoogleCloudDialogflowCxV3DtmfInput struct {
1027	// Digits: The dtmf digits.
1028	Digits string `json:"digits,omitempty"`
1029
1030	// FinishDigit: The finish digit (if any).
1031	FinishDigit string `json:"finishDigit,omitempty"`
1032
1033	// ForceSendFields is a list of field names (e.g. "Digits") to
1034	// unconditionally include in API requests. By default, fields with
1035	// empty values are omitted from API requests. However, any non-pointer,
1036	// non-interface field appearing in ForceSendFields will be sent to the
1037	// server regardless of whether the field is empty or not. This may be
1038	// used to include empty fields in Patch requests.
1039	ForceSendFields []string `json:"-"`
1040
1041	// NullFields is a list of field names (e.g. "Digits") to include in API
1042	// requests with the JSON null value. By default, fields with empty
1043	// values are omitted from API requests. However, any field with an
1044	// empty value appearing in NullFields will be sent to the server as
1045	// null. It is an error if a field in this list has a non-empty value.
1046	// This may be used to include null fields in Patch requests.
1047	NullFields []string `json:"-"`
1048}
1049
1050func (s *GoogleCloudDialogflowCxV3DtmfInput) MarshalJSON() ([]byte, error) {
1051	type NoMethod GoogleCloudDialogflowCxV3DtmfInput
1052	raw := NoMethod(*s)
1053	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1054}
1055
1056// GoogleCloudDialogflowCxV3EventHandler: An event handler specifies an
1057// event that can be handled during a session. When the specified event
1058// happens, the following actions are taken in order: * If there is a
1059// `trigger_fulfillment` associated with the event, it will be called. *
1060// If there is a `target_page` associated with the event, the session
1061// will transition into the specified page. * If there is a
1062// `target_flow` associated with the event, the session will transition
1063// into the specified flow.
1064type GoogleCloudDialogflowCxV3EventHandler struct {
1065	// Event: Required. The name of the event to handle.
1066	Event string `json:"event,omitempty"`
1067
1068	// Name: Output only. The unique identifier of this event handler.
1069	Name string `json:"name,omitempty"`
1070
1071	// TargetFlow: The target flow to transition to. Format:
1072	// `projects//locations//agents//flows/`.
1073	TargetFlow string `json:"targetFlow,omitempty"`
1074
1075	// TargetPage: The target page to transition to. Format:
1076	// `projects//locations//agents//flows//pages/`.
1077	TargetPage string `json:"targetPage,omitempty"`
1078
1079	// TriggerFulfillment: The fulfillment to call when the event occurs.
1080	// Handling webhook errors with a fulfillment enabled with webhook could
1081	// cause infinite loop. It is invalid to specify such fulfillment for a
1082	// handler handling webhooks.
1083	TriggerFulfillment *GoogleCloudDialogflowCxV3Fulfillment `json:"triggerFulfillment,omitempty"`
1084
1085	// ForceSendFields is a list of field names (e.g. "Event") to
1086	// unconditionally include in API requests. By default, fields with
1087	// empty values are omitted from API requests. However, any non-pointer,
1088	// non-interface field appearing in ForceSendFields will be sent to the
1089	// server regardless of whether the field is empty or not. This may be
1090	// used to include empty fields in Patch requests.
1091	ForceSendFields []string `json:"-"`
1092
1093	// NullFields is a list of field names (e.g. "Event") to include in API
1094	// requests with the JSON null value. By default, fields with empty
1095	// values are omitted from API requests. However, any field with an
1096	// empty value appearing in NullFields will be sent to the server as
1097	// null. It is an error if a field in this list has a non-empty value.
1098	// This may be used to include null fields in Patch requests.
1099	NullFields []string `json:"-"`
1100}
1101
1102func (s *GoogleCloudDialogflowCxV3EventHandler) MarshalJSON() ([]byte, error) {
1103	type NoMethod GoogleCloudDialogflowCxV3EventHandler
1104	raw := NoMethod(*s)
1105	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1106}
1107
1108// GoogleCloudDialogflowCxV3EventInput: Represents the event to trigger.
1109type GoogleCloudDialogflowCxV3EventInput struct {
1110	// Event: Name of the event.
1111	Event string `json:"event,omitempty"`
1112
1113	// ForceSendFields is a list of field names (e.g. "Event") to
1114	// unconditionally include in API requests. By default, fields with
1115	// empty values are omitted from API requests. However, any non-pointer,
1116	// non-interface field appearing in ForceSendFields will be sent to the
1117	// server regardless of whether the field is empty or not. This may be
1118	// used to include empty fields in Patch requests.
1119	ForceSendFields []string `json:"-"`
1120
1121	// NullFields is a list of field names (e.g. "Event") to include in API
1122	// requests with the JSON null value. By default, fields with empty
1123	// values are omitted from API requests. However, any field with an
1124	// empty value appearing in NullFields will be sent to the server as
1125	// null. It is an error if a field in this list has a non-empty value.
1126	// This may be used to include null fields in Patch requests.
1127	NullFields []string `json:"-"`
1128}
1129
1130func (s *GoogleCloudDialogflowCxV3EventInput) MarshalJSON() ([]byte, error) {
1131	type NoMethod GoogleCloudDialogflowCxV3EventInput
1132	raw := NoMethod(*s)
1133	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1134}
1135
1136// GoogleCloudDialogflowCxV3ExportAgentResponse: The response message
1137// for Agents.ExportAgent.
1138type GoogleCloudDialogflowCxV3ExportAgentResponse struct {
1139	// AgentContent: Uncompressed raw byte content for agent.
1140	AgentContent string `json:"agentContent,omitempty"`
1141
1142	// AgentUri: The URI to a file containing the exported agent. This field
1143	// is populated only if `agent_uri` is specified in ExportAgentRequest.
1144	AgentUri string `json:"agentUri,omitempty"`
1145
1146	// ForceSendFields is a list of field names (e.g. "AgentContent") to
1147	// unconditionally include in API requests. By default, fields with
1148	// empty values are omitted from API requests. However, any non-pointer,
1149	// non-interface field appearing in ForceSendFields will be sent to the
1150	// server regardless of whether the field is empty or not. This may be
1151	// used to include empty fields in Patch requests.
1152	ForceSendFields []string `json:"-"`
1153
1154	// NullFields is a list of field names (e.g. "AgentContent") to include
1155	// in API requests with the JSON null value. By default, fields with
1156	// empty values are omitted from API requests. However, any field with
1157	// an empty value appearing in NullFields will be sent to the server as
1158	// null. It is an error if a field in this list has a non-empty value.
1159	// This may be used to include null fields in Patch requests.
1160	NullFields []string `json:"-"`
1161}
1162
1163func (s *GoogleCloudDialogflowCxV3ExportAgentResponse) MarshalJSON() ([]byte, error) {
1164	type NoMethod GoogleCloudDialogflowCxV3ExportAgentResponse
1165	raw := NoMethod(*s)
1166	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1167}
1168
1169// GoogleCloudDialogflowCxV3ExportTestCasesMetadata: Metadata returned
1170// for the TestCases.ExportTestCases long running operation.
1171type GoogleCloudDialogflowCxV3ExportTestCasesMetadata struct {
1172}
1173
1174// GoogleCloudDialogflowCxV3ExportTestCasesResponse: The response
1175// message for TestCases.ExportTestCases.
1176type GoogleCloudDialogflowCxV3ExportTestCasesResponse struct {
1177	// Content: Uncompressed raw byte content for test cases.
1178	Content string `json:"content,omitempty"`
1179
1180	// GcsUri: The URI to a file containing the exported test cases. This
1181	// field is populated only if `gcs_uri` is specified in
1182	// ExportTestCasesRequest.
1183	GcsUri string `json:"gcsUri,omitempty"`
1184
1185	// ForceSendFields is a list of field names (e.g. "Content") to
1186	// unconditionally include in API requests. By default, fields with
1187	// empty values are omitted from API requests. However, any non-pointer,
1188	// non-interface field appearing in ForceSendFields will be sent to the
1189	// server regardless of whether the field is empty or not. This may be
1190	// used to include empty fields in Patch requests.
1191	ForceSendFields []string `json:"-"`
1192
1193	// NullFields is a list of field names (e.g. "Content") to include in
1194	// API requests with the JSON null value. By default, fields with empty
1195	// values are omitted from API requests. However, any field with an
1196	// empty value appearing in NullFields will be sent to the server as
1197	// null. It is an error if a field in this list has a non-empty value.
1198	// This may be used to include null fields in Patch requests.
1199	NullFields []string `json:"-"`
1200}
1201
1202func (s *GoogleCloudDialogflowCxV3ExportTestCasesResponse) MarshalJSON() ([]byte, error) {
1203	type NoMethod GoogleCloudDialogflowCxV3ExportTestCasesResponse
1204	raw := NoMethod(*s)
1205	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1206}
1207
1208// GoogleCloudDialogflowCxV3Form: A form is a data model that groups
1209// related parameters that can be collected from the user. The process
1210// in which the agent prompts the user and collects parameter values
1211// from the user is called form filling. A form can be added to a page.
1212// When form filling is done, the filled parameters will be written to
1213// the session.
1214type GoogleCloudDialogflowCxV3Form struct {
1215	// Parameters: Parameters to collect from the user.
1216	Parameters []*GoogleCloudDialogflowCxV3FormParameter `json:"parameters,omitempty"`
1217
1218	// ForceSendFields is a list of field names (e.g. "Parameters") to
1219	// unconditionally include in API requests. By default, fields with
1220	// empty values are omitted from API requests. However, any non-pointer,
1221	// non-interface field appearing in ForceSendFields will be sent to the
1222	// server regardless of whether the field is empty or not. This may be
1223	// used to include empty fields in Patch requests.
1224	ForceSendFields []string `json:"-"`
1225
1226	// NullFields is a list of field names (e.g. "Parameters") to include in
1227	// API requests with the JSON null value. By default, fields with empty
1228	// values are omitted from API requests. However, any field with an
1229	// empty value appearing in NullFields will be sent to the server as
1230	// null. It is an error if a field in this list has a non-empty value.
1231	// This may be used to include null fields in Patch requests.
1232	NullFields []string `json:"-"`
1233}
1234
1235func (s *GoogleCloudDialogflowCxV3Form) MarshalJSON() ([]byte, error) {
1236	type NoMethod GoogleCloudDialogflowCxV3Form
1237	raw := NoMethod(*s)
1238	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1239}
1240
1241// GoogleCloudDialogflowCxV3FormParameter: Represents a form parameter.
1242type GoogleCloudDialogflowCxV3FormParameter struct {
1243	// DefaultValue: The default value of an optional parameter. If the
1244	// parameter is required, the default value will be ignored.
1245	DefaultValue interface{} `json:"defaultValue,omitempty"`
1246
1247	// DisplayName: Required. The human-readable name of the parameter,
1248	// unique within the form.
1249	DisplayName string `json:"displayName,omitempty"`
1250
1251	// EntityType: Required. The entity type of the parameter. Format:
1252	// `projects/-/locations/-/agents/-/entityTypes/` for system entity
1253	// types (for example,
1254	// `projects/-/locations/-/agents/-/entityTypes/sys.date`), or
1255	// `projects//locations//agents//entityTypes/` for developer entity
1256	// types.
1257	EntityType string `json:"entityType,omitempty"`
1258
1259	// FillBehavior: Required. Defines fill behavior for the parameter.
1260	FillBehavior *GoogleCloudDialogflowCxV3FormParameterFillBehavior `json:"fillBehavior,omitempty"`
1261
1262	// IsList: Indicates whether the parameter represents a list of values.
1263	IsList bool `json:"isList,omitempty"`
1264
1265	// Redact: Indicates whether the parameter content should be redacted in
1266	// log. If redaction is enabled, the parameter content will be replaced
1267	// by parameter name during logging. Note: the parameter content is
1268	// subject to redaction if either parameter level redaction or entity
1269	// type level redaction is enabled.
1270	Redact bool `json:"redact,omitempty"`
1271
1272	// Required: Indicates whether the parameter is required. Optional
1273	// parameters will not trigger prompts; however, they are filled if the
1274	// user specifies them. Required parameters must be filled before form
1275	// filling concludes.
1276	Required bool `json:"required,omitempty"`
1277
1278	// ForceSendFields is a list of field names (e.g. "DefaultValue") to
1279	// unconditionally include in API requests. By default, fields with
1280	// empty values are omitted from API requests. However, any non-pointer,
1281	// non-interface field appearing in ForceSendFields will be sent to the
1282	// server regardless of whether the field is empty or not. This may be
1283	// used to include empty fields in Patch requests.
1284	ForceSendFields []string `json:"-"`
1285
1286	// NullFields is a list of field names (e.g. "DefaultValue") to include
1287	// in API requests with the JSON null value. By default, fields with
1288	// empty values are omitted from API requests. However, any field with
1289	// an empty value appearing in NullFields will be sent to the server as
1290	// null. It is an error if a field in this list has a non-empty value.
1291	// This may be used to include null fields in Patch requests.
1292	NullFields []string `json:"-"`
1293}
1294
1295func (s *GoogleCloudDialogflowCxV3FormParameter) MarshalJSON() ([]byte, error) {
1296	type NoMethod GoogleCloudDialogflowCxV3FormParameter
1297	raw := NoMethod(*s)
1298	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1299}
1300
1301// GoogleCloudDialogflowCxV3FormParameterFillBehavior: Configuration for
1302// how the filling of a parameter should be handled.
1303type GoogleCloudDialogflowCxV3FormParameterFillBehavior struct {
1304	// InitialPromptFulfillment: Required. The fulfillment to provide the
1305	// initial prompt that the agent can present to the user in order to
1306	// fill the parameter.
1307	InitialPromptFulfillment *GoogleCloudDialogflowCxV3Fulfillment `json:"initialPromptFulfillment,omitempty"`
1308
1309	// RepromptEventHandlers: The handlers for parameter-level events, used
1310	// to provide reprompt for the parameter or transition to a different
1311	// page/flow. The supported events are: * `sys.no-match-`, where N can
1312	// be from 1 to 6 * `sys.no-match-default` * `sys.no-input-`, where N
1313	// can be from 1 to 6 * `sys.no-input-default` * `sys.invalid-parameter`
1314	// `initial_prompt_fulfillment` provides the first prompt for the
1315	// parameter. If the user's response does not fill the parameter, a
1316	// no-match/no-input event will be triggered, and the fulfillment
1317	// associated with the `sys.no-match-1`/`sys.no-input-1` handler (if
1318	// defined) will be called to provide a prompt. The
1319	// `sys.no-match-2`/`sys.no-input-2` handler (if defined) will respond
1320	// to the next no-match/no-input event, and so on. A
1321	// `sys.no-match-default` or `sys.no-input-default` handler will be used
1322	// to handle all following no-match/no-input events after all numbered
1323	// no-match/no-input handlers for the parameter are consumed. A
1324	// `sys.invalid-parameter` handler can be defined to handle the case
1325	// where the parameter values have been `invalidated` by webhook. For
1326	// example, if the user's response fill the parameter, however the
1327	// parameter was invalidated by webhook, the fulfillment associated with
1328	// the `sys.invalid-parameter` handler (if defined) will be called to
1329	// provide a prompt. If the event handler for the corresponding event
1330	// can't be found on the parameter, `initial_prompt_fulfillment` will be
1331	// re-prompted.
1332	RepromptEventHandlers []*GoogleCloudDialogflowCxV3EventHandler `json:"repromptEventHandlers,omitempty"`
1333
1334	// ForceSendFields is a list of field names (e.g.
1335	// "InitialPromptFulfillment") to unconditionally include in API
1336	// requests. By default, fields with empty values are omitted from API
1337	// requests. However, any non-pointer, non-interface field appearing in
1338	// ForceSendFields will be sent to the server regardless of whether the
1339	// field is empty or not. This may be used to include empty fields in
1340	// Patch requests.
1341	ForceSendFields []string `json:"-"`
1342
1343	// NullFields is a list of field names (e.g. "InitialPromptFulfillment")
1344	// to include in API requests with the JSON null value. By default,
1345	// fields with empty values are omitted from API requests. However, any
1346	// field with an empty value appearing in NullFields will be sent to the
1347	// server as null. It is an error if a field in this list has a
1348	// non-empty value. This may be used to include null fields in Patch
1349	// requests.
1350	NullFields []string `json:"-"`
1351}
1352
1353func (s *GoogleCloudDialogflowCxV3FormParameterFillBehavior) MarshalJSON() ([]byte, error) {
1354	type NoMethod GoogleCloudDialogflowCxV3FormParameterFillBehavior
1355	raw := NoMethod(*s)
1356	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1357}
1358
1359// GoogleCloudDialogflowCxV3Fulfillment: A fulfillment can do one or
1360// more of the following actions at the same time: * Generate rich
1361// message responses. * Set parameter values. * Call the webhook.
1362// Fulfillments can be called at various stages in the Page or Form
1363// lifecycle. For example, when a DetectIntentRequest drives a session
1364// to enter a new page, the page's entry fulfillment can add a static
1365// response to the QueryResult in the returning DetectIntentResponse,
1366// call the webhook (for example, to load user data from a database), or
1367// both.
1368type GoogleCloudDialogflowCxV3Fulfillment struct {
1369	// ConditionalCases: Conditional cases for this fulfillment.
1370	ConditionalCases []*GoogleCloudDialogflowCxV3FulfillmentConditionalCases `json:"conditionalCases,omitempty"`
1371
1372	// Messages: The list of rich message responses to present to the user.
1373	Messages []*GoogleCloudDialogflowCxV3ResponseMessage `json:"messages,omitempty"`
1374
1375	// SetParameterActions: Set parameter values before executing the
1376	// webhook.
1377	SetParameterActions []*GoogleCloudDialogflowCxV3FulfillmentSetParameterAction `json:"setParameterActions,omitempty"`
1378
1379	// Tag: The tag used by the webhook to identify which fulfillment is
1380	// being called. This field is required if `webhook` is specified.
1381	Tag string `json:"tag,omitempty"`
1382
1383	// Webhook: The webhook to call. Format:
1384	// `projects//locations//agents//webhooks/`.
1385	Webhook string `json:"webhook,omitempty"`
1386
1387	// ForceSendFields is a list of field names (e.g. "ConditionalCases") to
1388	// unconditionally include in API requests. By default, fields with
1389	// empty values are omitted from API requests. However, any non-pointer,
1390	// non-interface field appearing in ForceSendFields will be sent to the
1391	// server regardless of whether the field is empty or not. This may be
1392	// used to include empty fields in Patch requests.
1393	ForceSendFields []string `json:"-"`
1394
1395	// NullFields is a list of field names (e.g. "ConditionalCases") to
1396	// include in API requests with the JSON null value. By default, fields
1397	// with empty values are omitted from API requests. However, any field
1398	// with an empty value appearing in NullFields will be sent to the
1399	// server as null. It is an error if a field in this list has a
1400	// non-empty value. This may be used to include null fields in Patch
1401	// requests.
1402	NullFields []string `json:"-"`
1403}
1404
1405func (s *GoogleCloudDialogflowCxV3Fulfillment) MarshalJSON() ([]byte, error) {
1406	type NoMethod GoogleCloudDialogflowCxV3Fulfillment
1407	raw := NoMethod(*s)
1408	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1409}
1410
1411// GoogleCloudDialogflowCxV3FulfillmentConditionalCases: A list of
1412// cascading if-else conditions. Cases are mutually exclusive. The first
1413// one with a matching condition is selected, all the rest ignored.
1414type GoogleCloudDialogflowCxV3FulfillmentConditionalCases struct {
1415	// Cases: A list of cascading if-else conditions.
1416	Cases []*GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCase `json:"cases,omitempty"`
1417
1418	// ForceSendFields is a list of field names (e.g. "Cases") to
1419	// unconditionally include in API requests. By default, fields with
1420	// empty values are omitted from API requests. However, any non-pointer,
1421	// non-interface field appearing in ForceSendFields will be sent to the
1422	// server regardless of whether the field is empty or not. This may be
1423	// used to include empty fields in Patch requests.
1424	ForceSendFields []string `json:"-"`
1425
1426	// NullFields is a list of field names (e.g. "Cases") to include in API
1427	// requests with the JSON null value. By default, fields with empty
1428	// values are omitted from API requests. However, any field with an
1429	// empty value appearing in NullFields will be sent to the server as
1430	// null. It is an error if a field in this list has a non-empty value.
1431	// This may be used to include null fields in Patch requests.
1432	NullFields []string `json:"-"`
1433}
1434
1435func (s *GoogleCloudDialogflowCxV3FulfillmentConditionalCases) MarshalJSON() ([]byte, error) {
1436	type NoMethod GoogleCloudDialogflowCxV3FulfillmentConditionalCases
1437	raw := NoMethod(*s)
1438	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1439}
1440
1441// GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCase: Each case
1442// has a Boolean condition. When it is evaluated to be True, the
1443// corresponding messages will be selected and evaluated recursively.
1444type GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCase struct {
1445	// CaseContent: A list of case content.
1446	CaseContent []*GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCaseCaseContent `json:"caseContent,omitempty"`
1447
1448	// Condition: The condition to activate and select this case. Empty
1449	// means the condition is always true. The condition is evaluated
1450	// against form parameters or session parameters. See the conditions
1451	// reference
1452	// (https://cloud.google.com/dialogflow/cx/docs/reference/condition).
1453	Condition string `json:"condition,omitempty"`
1454
1455	// ForceSendFields is a list of field names (e.g. "CaseContent") to
1456	// unconditionally include in API requests. By default, fields with
1457	// empty values are omitted from API requests. However, any non-pointer,
1458	// non-interface field appearing in ForceSendFields will be sent to the
1459	// server regardless of whether the field is empty or not. This may be
1460	// used to include empty fields in Patch requests.
1461	ForceSendFields []string `json:"-"`
1462
1463	// NullFields is a list of field names (e.g. "CaseContent") to include
1464	// in API requests with the JSON null value. By default, fields with
1465	// empty values are omitted from API requests. However, any field with
1466	// an empty value appearing in NullFields will be sent to the server as
1467	// null. It is an error if a field in this list has a non-empty value.
1468	// This may be used to include null fields in Patch requests.
1469	NullFields []string `json:"-"`
1470}
1471
1472func (s *GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCase) MarshalJSON() ([]byte, error) {
1473	type NoMethod GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCase
1474	raw := NoMethod(*s)
1475	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1476}
1477
1478// GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCaseCaseContent:
1479// The list of messages or conditional cases to activate for this case.
1480type GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCaseCaseContent struct {
1481	// AdditionalCases: Additional cases to be evaluated.
1482	AdditionalCases *GoogleCloudDialogflowCxV3FulfillmentConditionalCases `json:"additionalCases,omitempty"`
1483
1484	// Message: Returned message.
1485	Message *GoogleCloudDialogflowCxV3ResponseMessage `json:"message,omitempty"`
1486
1487	// ForceSendFields is a list of field names (e.g. "AdditionalCases") to
1488	// unconditionally include in API requests. By default, fields with
1489	// empty values are omitted from API requests. However, any non-pointer,
1490	// non-interface field appearing in ForceSendFields will be sent to the
1491	// server regardless of whether the field is empty or not. This may be
1492	// used to include empty fields in Patch requests.
1493	ForceSendFields []string `json:"-"`
1494
1495	// NullFields is a list of field names (e.g. "AdditionalCases") to
1496	// include in API requests with the JSON null value. By default, fields
1497	// with empty values are omitted from API requests. However, any field
1498	// with an empty value appearing in NullFields will be sent to the
1499	// server as null. It is an error if a field in this list has a
1500	// non-empty value. This may be used to include null fields in Patch
1501	// requests.
1502	NullFields []string `json:"-"`
1503}
1504
1505func (s *GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCaseCaseContent) MarshalJSON() ([]byte, error) {
1506	type NoMethod GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCaseCaseContent
1507	raw := NoMethod(*s)
1508	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1509}
1510
1511// GoogleCloudDialogflowCxV3FulfillmentSetParameterAction: Setting a
1512// parameter value.
1513type GoogleCloudDialogflowCxV3FulfillmentSetParameterAction struct {
1514	// Parameter: Display name of the parameter.
1515	Parameter string `json:"parameter,omitempty"`
1516
1517	// Value: The new value of the parameter. A null value clears the
1518	// parameter.
1519	Value interface{} `json:"value,omitempty"`
1520
1521	// ForceSendFields is a list of field names (e.g. "Parameter") to
1522	// unconditionally include in API requests. By default, fields with
1523	// empty values are omitted from API requests. However, any non-pointer,
1524	// non-interface field appearing in ForceSendFields will be sent to the
1525	// server regardless of whether the field is empty or not. This may be
1526	// used to include empty fields in Patch requests.
1527	ForceSendFields []string `json:"-"`
1528
1529	// NullFields is a list of field names (e.g. "Parameter") to include in
1530	// API requests with the JSON null value. By default, fields with empty
1531	// values are omitted from API requests. However, any field with an
1532	// empty value appearing in NullFields will be sent to the server as
1533	// null. It is an error if a field in this list has a non-empty value.
1534	// This may be used to include null fields in Patch requests.
1535	NullFields []string `json:"-"`
1536}
1537
1538func (s *GoogleCloudDialogflowCxV3FulfillmentSetParameterAction) MarshalJSON() ([]byte, error) {
1539	type NoMethod GoogleCloudDialogflowCxV3FulfillmentSetParameterAction
1540	raw := NoMethod(*s)
1541	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1542}
1543
1544// GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata: Metadata
1545// in google::longrunning::Operation for Knowledge operations.
1546type GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata struct {
1547	// State: Required. Output only. The current state of this operation.
1548	//
1549	// Possible values:
1550	//   "STATE_UNSPECIFIED" - State unspecified.
1551	//   "PENDING" - The operation has been created.
1552	//   "RUNNING" - The operation is currently running.
1553	//   "DONE" - The operation is done, either cancelled or completed.
1554	State string `json:"state,omitempty"`
1555
1556	// ForceSendFields is a list of field names (e.g. "State") to
1557	// unconditionally include in API requests. By default, fields with
1558	// empty values are omitted from API requests. However, any non-pointer,
1559	// non-interface field appearing in ForceSendFields will be sent to the
1560	// server regardless of whether the field is empty or not. This may be
1561	// used to include empty fields in Patch requests.
1562	ForceSendFields []string `json:"-"`
1563
1564	// NullFields is a list of field names (e.g. "State") to include in API
1565	// requests with the JSON null value. By default, fields with empty
1566	// values are omitted from API requests. However, any field with an
1567	// empty value appearing in NullFields will be sent to the server as
1568	// null. It is an error if a field in this list has a non-empty value.
1569	// This may be used to include null fields in Patch requests.
1570	NullFields []string `json:"-"`
1571}
1572
1573func (s *GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata) MarshalJSON() ([]byte, error) {
1574	type NoMethod GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata
1575	raw := NoMethod(*s)
1576	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1577}
1578
1579// GoogleCloudDialogflowCxV3ImportDocumentsOperationMetadata: Metadata
1580// for ImportDocuments operation.
1581type GoogleCloudDialogflowCxV3ImportDocumentsOperationMetadata struct {
1582	// GenericMetadata: The generic information of the operation.
1583	GenericMetadata *GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
1584
1585	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
1586	// unconditionally include in API requests. By default, fields with
1587	// empty values are omitted from API requests. However, any non-pointer,
1588	// non-interface field appearing in ForceSendFields will be sent to the
1589	// server regardless of whether the field is empty or not. This may be
1590	// used to include empty fields in Patch requests.
1591	ForceSendFields []string `json:"-"`
1592
1593	// NullFields is a list of field names (e.g. "GenericMetadata") to
1594	// include in API requests with the JSON null value. By default, fields
1595	// with empty values are omitted from API requests. However, any field
1596	// with an empty value appearing in NullFields will be sent to the
1597	// server as null. It is an error if a field in this list has a
1598	// non-empty value. This may be used to include null fields in Patch
1599	// requests.
1600	NullFields []string `json:"-"`
1601}
1602
1603func (s *GoogleCloudDialogflowCxV3ImportDocumentsOperationMetadata) MarshalJSON() ([]byte, error) {
1604	type NoMethod GoogleCloudDialogflowCxV3ImportDocumentsOperationMetadata
1605	raw := NoMethod(*s)
1606	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1607}
1608
1609// GoogleCloudDialogflowCxV3ImportDocumentsResponse: Response message
1610// for Documents.ImportDocuments.
1611type GoogleCloudDialogflowCxV3ImportDocumentsResponse struct {
1612	// Warnings: Includes details about skipped documents or any other
1613	// warnings.
1614	Warnings []*GoogleRpcStatus `json:"warnings,omitempty"`
1615
1616	// ForceSendFields is a list of field names (e.g. "Warnings") to
1617	// unconditionally include in API requests. By default, fields with
1618	// empty values are omitted from API requests. However, any non-pointer,
1619	// non-interface field appearing in ForceSendFields will be sent to the
1620	// server regardless of whether the field is empty or not. This may be
1621	// used to include empty fields in Patch requests.
1622	ForceSendFields []string `json:"-"`
1623
1624	// NullFields is a list of field names (e.g. "Warnings") to include in
1625	// API requests with the JSON null value. By default, fields with empty
1626	// values are omitted from API requests. However, any field with an
1627	// empty value appearing in NullFields will be sent to the server as
1628	// null. It is an error if a field in this list has a non-empty value.
1629	// This may be used to include null fields in Patch requests.
1630	NullFields []string `json:"-"`
1631}
1632
1633func (s *GoogleCloudDialogflowCxV3ImportDocumentsResponse) MarshalJSON() ([]byte, error) {
1634	type NoMethod GoogleCloudDialogflowCxV3ImportDocumentsResponse
1635	raw := NoMethod(*s)
1636	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1637}
1638
1639// GoogleCloudDialogflowCxV3ImportTestCasesMetadata: Metadata returned
1640// for the TestCases.ImportTestCases long running operation.
1641type GoogleCloudDialogflowCxV3ImportTestCasesMetadata struct {
1642	// Errors: Errors for failed test cases.
1643	Errors []*GoogleCloudDialogflowCxV3TestCaseError `json:"errors,omitempty"`
1644
1645	// ForceSendFields is a list of field names (e.g. "Errors") to
1646	// unconditionally include in API requests. By default, fields with
1647	// empty values are omitted from API requests. However, any non-pointer,
1648	// non-interface field appearing in ForceSendFields will be sent to the
1649	// server regardless of whether the field is empty or not. This may be
1650	// used to include empty fields in Patch requests.
1651	ForceSendFields []string `json:"-"`
1652
1653	// NullFields is a list of field names (e.g. "Errors") to include in API
1654	// requests with the JSON null value. By default, fields with empty
1655	// values are omitted from API requests. However, any field with an
1656	// empty value appearing in NullFields will be sent to the server as
1657	// null. It is an error if a field in this list has a non-empty value.
1658	// This may be used to include null fields in Patch requests.
1659	NullFields []string `json:"-"`
1660}
1661
1662func (s *GoogleCloudDialogflowCxV3ImportTestCasesMetadata) MarshalJSON() ([]byte, error) {
1663	type NoMethod GoogleCloudDialogflowCxV3ImportTestCasesMetadata
1664	raw := NoMethod(*s)
1665	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1666}
1667
1668// GoogleCloudDialogflowCxV3ImportTestCasesResponse: The response
1669// message for TestCases.ImportTestCases.
1670type GoogleCloudDialogflowCxV3ImportTestCasesResponse struct {
1671	// Names: The unique identifiers of the new test cases. Format:
1672	// `projects//locations//agents//testCases/`.
1673	Names []string `json:"names,omitempty"`
1674
1675	// ForceSendFields is a list of field names (e.g. "Names") to
1676	// unconditionally include in API requests. By default, fields with
1677	// empty values are omitted from API requests. However, any non-pointer,
1678	// non-interface field appearing in ForceSendFields will be sent to the
1679	// server regardless of whether the field is empty or not. This may be
1680	// used to include empty fields in Patch requests.
1681	ForceSendFields []string `json:"-"`
1682
1683	// NullFields is a list of field names (e.g. "Names") to include in API
1684	// requests with the JSON null value. By default, fields with empty
1685	// values are omitted from API requests. However, any field with an
1686	// empty value appearing in NullFields will be sent to the server as
1687	// null. It is an error if a field in this list has a non-empty value.
1688	// This may be used to include null fields in Patch requests.
1689	NullFields []string `json:"-"`
1690}
1691
1692func (s *GoogleCloudDialogflowCxV3ImportTestCasesResponse) MarshalJSON() ([]byte, error) {
1693	type NoMethod GoogleCloudDialogflowCxV3ImportTestCasesResponse
1694	raw := NoMethod(*s)
1695	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1696}
1697
1698// GoogleCloudDialogflowCxV3InputAudioConfig: Instructs the speech
1699// recognizer on how to process the audio content.
1700type GoogleCloudDialogflowCxV3InputAudioConfig struct {
1701	// AudioEncoding: Required. Audio encoding of the audio content to
1702	// process.
1703	//
1704	// Possible values:
1705	//   "AUDIO_ENCODING_UNSPECIFIED" - Not specified.
1706	//   "AUDIO_ENCODING_LINEAR_16" - Uncompressed 16-bit signed
1707	// little-endian samples (Linear PCM).
1708	//   "AUDIO_ENCODING_FLAC" -
1709	// [`FLAC`](https://xiph.org/flac/documentation.html) (Free Lossless
1710	// Audio Codec) is the recommended encoding because it is lossless
1711	// (therefore recognition is not compromised) and requires only about
1712	// half the bandwidth of `LINEAR16`. `FLAC` stream encoding supports
1713	// 16-bit and 24-bit samples, however, not all fields in `STREAMINFO`
1714	// are supported.
1715	//   "AUDIO_ENCODING_MULAW" - 8-bit samples that compand 14-bit audio
1716	// samples using G.711 PCMU/mu-law.
1717	//   "AUDIO_ENCODING_AMR" - Adaptive Multi-Rate Narrowband codec.
1718	// `sample_rate_hertz` must be 8000.
1719	//   "AUDIO_ENCODING_AMR_WB" - Adaptive Multi-Rate Wideband codec.
1720	// `sample_rate_hertz` must be 16000.
1721	//   "AUDIO_ENCODING_OGG_OPUS" - Opus encoded audio frames in Ogg
1722	// container ([OggOpus](https://wiki.xiph.org/OggOpus)).
1723	// `sample_rate_hertz` must be 16000.
1724	//   "AUDIO_ENCODING_SPEEX_WITH_HEADER_BYTE" - Although the use of lossy
1725	// encodings is not recommended, if a very low bitrate encoding is
1726	// required, `OGG_OPUS` is highly preferred over Speex encoding. The
1727	// [Speex](https://speex.org/) encoding supported by Dialogflow API has
1728	// a header byte in each block, as in MIME type
1729	// `audio/x-speex-with-header-byte`. It is a variant of the RTP Speex
1730	// encoding defined in [RFC 5574](https://tools.ietf.org/html/rfc5574).
1731	// The stream is a sequence of blocks, one block per RTP packet. Each
1732	// block starts with a byte containing the length of the block, in
1733	// bytes, followed by one or more frames of Speex data, padded to an
1734	// integral number of bytes (octets) as specified in RFC 5574. In other
1735	// words, each RTP header is replaced with a single byte containing the
1736	// block length. Only Speex wideband is supported. `sample_rate_hertz`
1737	// must be 16000.
1738	AudioEncoding string `json:"audioEncoding,omitempty"`
1739
1740	// EnableWordInfo: Optional. If `true`, Dialogflow returns
1741	// SpeechWordInfo in StreamingRecognitionResult with information about
1742	// the recognized speech words, e.g. start and end time offsets. If
1743	// false or unspecified, Speech doesn't return any word-level
1744	// information.
1745	EnableWordInfo bool `json:"enableWordInfo,omitempty"`
1746
1747	// Model: Optional. Which Speech model to select for the given request.
1748	// Select the model best suited to your domain to get best results. If a
1749	// model is not explicitly specified, then we auto-select a model based
1750	// on the parameters in the InputAudioConfig. If enhanced speech model
1751	// is enabled for the agent and an enhanced version of the specified
1752	// model for the language does not exist, then the speech is recognized
1753	// using the standard version of the specified model. Refer to Cloud
1754	// Speech API documentation
1755	// (https://cloud.google.com/speech-to-text/docs/basics#select-model)
1756	// for more details.
1757	Model string `json:"model,omitempty"`
1758
1759	// ModelVariant: Optional. Which variant of the Speech model to use.
1760	//
1761	// Possible values:
1762	//   "SPEECH_MODEL_VARIANT_UNSPECIFIED" - No model variant specified. In
1763	// this case Dialogflow defaults to USE_BEST_AVAILABLE.
1764	//   "USE_BEST_AVAILABLE" - Use the best available variant of the Speech
1765	// model that the caller is eligible for. Please see the [Dialogflow
1766	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
1767	// to make your project eligible for enhanced models.
1768	//   "USE_STANDARD" - Use standard model variant even if an enhanced
1769	// model is available. See the [Cloud Speech
1770	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
1771	// odels) for details about enhanced models.
1772	//   "USE_ENHANCED" - Use an enhanced model variant: * If an enhanced
1773	// variant does not exist for the given model and request language,
1774	// Dialogflow falls back to the standard variant. The [Cloud Speech
1775	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
1776	// odels) describes which models have enhanced variants. * If the API
1777	// caller isn't eligible for enhanced models, Dialogflow returns an
1778	// error. Please see the [Dialogflow
1779	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
1780	// to make your project eligible.
1781	ModelVariant string `json:"modelVariant,omitempty"`
1782
1783	// PhraseHints: Optional. A list of strings containing words and phrases
1784	// that the speech recognizer should recognize with higher likelihood.
1785	// See the Cloud Speech documentation
1786	// (https://cloud.google.com/speech-to-text/docs/basics#phrase-hints)
1787	// for more details.
1788	PhraseHints []string `json:"phraseHints,omitempty"`
1789
1790	// SampleRateHertz: Sample rate (in Hertz) of the audio content sent in
1791	// the query. Refer to Cloud Speech API documentation
1792	// (https://cloud.google.com/speech-to-text/docs/basics) for more
1793	// details.
1794	SampleRateHertz int64 `json:"sampleRateHertz,omitempty"`
1795
1796	// SingleUtterance: Optional. If `false` (default), recognition does not
1797	// cease until the client closes the stream. If `true`, the recognizer
1798	// will detect a single spoken utterance in input audio. Recognition
1799	// ceases when it detects the audio's voice has stopped or paused. In
1800	// this case, once a detected intent is received, the client should
1801	// close the stream and start a new request with a new stream as needed.
1802	// Note: This setting is relevant only for streaming methods.
1803	SingleUtterance bool `json:"singleUtterance,omitempty"`
1804
1805	// ForceSendFields is a list of field names (e.g. "AudioEncoding") to
1806	// unconditionally include in API requests. By default, fields with
1807	// empty values are omitted from API requests. However, any non-pointer,
1808	// non-interface field appearing in ForceSendFields will be sent to the
1809	// server regardless of whether the field is empty or not. This may be
1810	// used to include empty fields in Patch requests.
1811	ForceSendFields []string `json:"-"`
1812
1813	// NullFields is a list of field names (e.g. "AudioEncoding") to include
1814	// in API requests with the JSON null value. By default, fields with
1815	// empty values are omitted from API requests. However, any field with
1816	// an empty value appearing in NullFields will be sent to the server as
1817	// null. It is an error if a field in this list has a non-empty value.
1818	// This may be used to include null fields in Patch requests.
1819	NullFields []string `json:"-"`
1820}
1821
1822func (s *GoogleCloudDialogflowCxV3InputAudioConfig) MarshalJSON() ([]byte, error) {
1823	type NoMethod GoogleCloudDialogflowCxV3InputAudioConfig
1824	raw := NoMethod(*s)
1825	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1826}
1827
1828// GoogleCloudDialogflowCxV3Intent: An intent represents a user's intent
1829// to interact with a conversational agent. You can provide information
1830// for the Dialogflow API to use to match user input to an intent by
1831// adding training phrases (i.e., examples of user input) to your
1832// intent.
1833type GoogleCloudDialogflowCxV3Intent struct {
1834	// Description: Optional. Human readable description for better
1835	// understanding an intent like its scope, content, result etc. Maximum
1836	// character limit: 140 characters.
1837	Description string `json:"description,omitempty"`
1838
1839	// DisplayName: Required. The human-readable name of the intent, unique
1840	// within the agent.
1841	DisplayName string `json:"displayName,omitempty"`
1842
1843	// IsFallback: Indicates whether this is a fallback intent. Currently
1844	// only default fallback intent is allowed in the agent, which is added
1845	// upon agent creation. Adding training phrases to fallback intent is
1846	// useful in the case of requests that are mistakenly matched, since
1847	// training phrases assigned to fallback intents act as negative
1848	// examples that triggers no-match event.
1849	IsFallback bool `json:"isFallback,omitempty"`
1850
1851	// Labels: Optional. The key/value metadata to label an intent. Labels
1852	// can contain lowercase letters, digits and the symbols '-' and '_'.
1853	// International characters are allowed, including letters from unicase
1854	// alphabets. Keys must start with a letter. Keys and values can be no
1855	// longer than 63 characters and no more than 128 bytes. Prefix "sys."
1856	// is reserved for Dialogflow defined labels. Currently allowed
1857	// Dialogflow defined labels include: * sys.head * sys.contextual The
1858	// above labels do not require value. "sys.head" means the intent is a
1859	// head intent. "sys.contextual" means the intent is a contextual
1860	// intent.
1861	Labels map[string]string `json:"labels,omitempty"`
1862
1863	// Name: The unique identifier of the intent. Required for the
1864	// Intents.UpdateIntent method. Intents.CreateIntent populates the name
1865	// automatically. Format: `projects//locations//agents//intents/`.
1866	Name string `json:"name,omitempty"`
1867
1868	// Parameters: The collection of parameters associated with the intent.
1869	Parameters []*GoogleCloudDialogflowCxV3IntentParameter `json:"parameters,omitempty"`
1870
1871	// Priority: The priority of this intent. Higher numbers represent
1872	// higher priorities. - If the supplied value is unspecified or 0, the
1873	// service translates the value to 500,000, which corresponds to the
1874	// `Normal` priority in the console. - If the supplied value is
1875	// negative, the intent is ignored in runtime detect intent requests.
1876	Priority int64 `json:"priority,omitempty"`
1877
1878	// TrainingPhrases: The collection of training phrases the agent is
1879	// trained on to identify the intent.
1880	TrainingPhrases []*GoogleCloudDialogflowCxV3IntentTrainingPhrase `json:"trainingPhrases,omitempty"`
1881
1882	// ForceSendFields is a list of field names (e.g. "Description") to
1883	// unconditionally include in API requests. By default, fields with
1884	// empty values are omitted from API requests. However, any non-pointer,
1885	// non-interface field appearing in ForceSendFields will be sent to the
1886	// server regardless of whether the field is empty or not. This may be
1887	// used to include empty fields in Patch requests.
1888	ForceSendFields []string `json:"-"`
1889
1890	// NullFields is a list of field names (e.g. "Description") to include
1891	// in API requests with the JSON null value. By default, fields with
1892	// empty values are omitted from API requests. However, any field with
1893	// an empty value appearing in NullFields will be sent to the server as
1894	// null. It is an error if a field in this list has a non-empty value.
1895	// This may be used to include null fields in Patch requests.
1896	NullFields []string `json:"-"`
1897}
1898
1899func (s *GoogleCloudDialogflowCxV3Intent) MarshalJSON() ([]byte, error) {
1900	type NoMethod GoogleCloudDialogflowCxV3Intent
1901	raw := NoMethod(*s)
1902	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1903}
1904
1905// GoogleCloudDialogflowCxV3IntentInput: Represents the intent to
1906// trigger programmatically rather than as a result of natural language
1907// processing.
1908type GoogleCloudDialogflowCxV3IntentInput struct {
1909	// Intent: Required. The unique identifier of the intent. Format:
1910	// `projects//locations//agents//intents/`.
1911	Intent string `json:"intent,omitempty"`
1912
1913	// ForceSendFields is a list of field names (e.g. "Intent") to
1914	// unconditionally include in API requests. By default, fields with
1915	// empty values are omitted from API requests. However, any non-pointer,
1916	// non-interface field appearing in ForceSendFields will be sent to the
1917	// server regardless of whether the field is empty or not. This may be
1918	// used to include empty fields in Patch requests.
1919	ForceSendFields []string `json:"-"`
1920
1921	// NullFields is a list of field names (e.g. "Intent") to include in API
1922	// requests with the JSON null value. By default, fields with empty
1923	// values are omitted from API requests. However, any field with an
1924	// empty value appearing in NullFields will be sent to the server as
1925	// null. It is an error if a field in this list has a non-empty value.
1926	// This may be used to include null fields in Patch requests.
1927	NullFields []string `json:"-"`
1928}
1929
1930func (s *GoogleCloudDialogflowCxV3IntentInput) MarshalJSON() ([]byte, error) {
1931	type NoMethod GoogleCloudDialogflowCxV3IntentInput
1932	raw := NoMethod(*s)
1933	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1934}
1935
1936// GoogleCloudDialogflowCxV3IntentParameter: Represents an intent
1937// parameter.
1938type GoogleCloudDialogflowCxV3IntentParameter struct {
1939	// EntityType: Required. The entity type of the parameter. Format:
1940	// `projects/-/locations/-/agents/-/entityTypes/` for system entity
1941	// types (for example,
1942	// `projects/-/locations/-/agents/-/entityTypes/sys.date`), or
1943	// `projects//locations//agents//entityTypes/` for developer entity
1944	// types.
1945	EntityType string `json:"entityType,omitempty"`
1946
1947	// Id: Required. The unique identifier of the parameter. This field is
1948	// used by training phrases to annotate their parts.
1949	Id string `json:"id,omitempty"`
1950
1951	// IsList: Indicates whether the parameter represents a list of values.
1952	IsList bool `json:"isList,omitempty"`
1953
1954	// Redact: Indicates whether the parameter content should be redacted in
1955	// log. If redaction is enabled, the parameter content will be replaced
1956	// by parameter name during logging. Note: the parameter content is
1957	// subject to redaction if either parameter level redaction or entity
1958	// type level redaction is enabled.
1959	Redact bool `json:"redact,omitempty"`
1960
1961	// ForceSendFields is a list of field names (e.g. "EntityType") to
1962	// unconditionally include in API requests. By default, fields with
1963	// empty values are omitted from API requests. However, any non-pointer,
1964	// non-interface field appearing in ForceSendFields will be sent to the
1965	// server regardless of whether the field is empty or not. This may be
1966	// used to include empty fields in Patch requests.
1967	ForceSendFields []string `json:"-"`
1968
1969	// NullFields is a list of field names (e.g. "EntityType") to include in
1970	// API requests with the JSON null value. By default, fields with empty
1971	// values are omitted from API requests. However, any field with an
1972	// empty value appearing in NullFields will be sent to the server as
1973	// null. It is an error if a field in this list has a non-empty value.
1974	// This may be used to include null fields in Patch requests.
1975	NullFields []string `json:"-"`
1976}
1977
1978func (s *GoogleCloudDialogflowCxV3IntentParameter) MarshalJSON() ([]byte, error) {
1979	type NoMethod GoogleCloudDialogflowCxV3IntentParameter
1980	raw := NoMethod(*s)
1981	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1982}
1983
1984// GoogleCloudDialogflowCxV3IntentTrainingPhrase: Represents an example
1985// that the agent is trained on to identify the intent.
1986type GoogleCloudDialogflowCxV3IntentTrainingPhrase struct {
1987	// Id: Output only. The unique identifier of the training phrase.
1988	Id string `json:"id,omitempty"`
1989
1990	// Parts: Required. The ordered list of training phrase parts. The parts
1991	// are concatenated in order to form the training phrase. Note: The API
1992	// does not automatically annotate training phrases like the Dialogflow
1993	// Console does. Note: Do not forget to include whitespace at part
1994	// boundaries, so the training phrase is well formatted when the parts
1995	// are concatenated. If the training phrase does not need to be
1996	// annotated with parameters, you just need a single part with only the
1997	// Part.text field set. If you want to annotate the training phrase, you
1998	// must create multiple parts, where the fields of each part are
1999	// populated in one of two ways: - `Part.text` is set to a part of the
2000	// phrase that has no parameters. - `Part.text` is set to a part of the
2001	// phrase that you want to annotate, and the `parameter_id` field is
2002	// set.
2003	Parts []*GoogleCloudDialogflowCxV3IntentTrainingPhrasePart `json:"parts,omitempty"`
2004
2005	// RepeatCount: Indicates how many times this example was added to the
2006	// intent.
2007	RepeatCount int64 `json:"repeatCount,omitempty"`
2008
2009	// ForceSendFields is a list of field names (e.g. "Id") to
2010	// unconditionally include in API requests. By default, fields with
2011	// empty values are omitted from API requests. However, any non-pointer,
2012	// non-interface field appearing in ForceSendFields will be sent to the
2013	// server regardless of whether the field is empty or not. This may be
2014	// used to include empty fields in Patch requests.
2015	ForceSendFields []string `json:"-"`
2016
2017	// NullFields is a list of field names (e.g. "Id") to include in API
2018	// requests with the JSON null value. By default, fields with empty
2019	// values are omitted from API requests. However, any field with an
2020	// empty value appearing in NullFields will be sent to the server as
2021	// null. It is an error if a field in this list has a non-empty value.
2022	// This may be used to include null fields in Patch requests.
2023	NullFields []string `json:"-"`
2024}
2025
2026func (s *GoogleCloudDialogflowCxV3IntentTrainingPhrase) MarshalJSON() ([]byte, error) {
2027	type NoMethod GoogleCloudDialogflowCxV3IntentTrainingPhrase
2028	raw := NoMethod(*s)
2029	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2030}
2031
2032// GoogleCloudDialogflowCxV3IntentTrainingPhrasePart: Represents a part
2033// of a training phrase.
2034type GoogleCloudDialogflowCxV3IntentTrainingPhrasePart struct {
2035	// ParameterId: The parameter used to annotate this part of the training
2036	// phrase. This field is required for annotated parts of the training
2037	// phrase.
2038	ParameterId string `json:"parameterId,omitempty"`
2039
2040	// Text: Required. The text for this part.
2041	Text string `json:"text,omitempty"`
2042
2043	// ForceSendFields is a list of field names (e.g. "ParameterId") to
2044	// unconditionally include in API requests. By default, fields with
2045	// empty values are omitted from API requests. However, any non-pointer,
2046	// non-interface field appearing in ForceSendFields will be sent to the
2047	// server regardless of whether the field is empty or not. This may be
2048	// used to include empty fields in Patch requests.
2049	ForceSendFields []string `json:"-"`
2050
2051	// NullFields is a list of field names (e.g. "ParameterId") to include
2052	// in API requests with the JSON null value. By default, fields with
2053	// empty values are omitted from API requests. However, any field with
2054	// an empty value appearing in NullFields will be sent to the server as
2055	// null. It is an error if a field in this list has a non-empty value.
2056	// This may be used to include null fields in Patch requests.
2057	NullFields []string `json:"-"`
2058}
2059
2060func (s *GoogleCloudDialogflowCxV3IntentTrainingPhrasePart) MarshalJSON() ([]byte, error) {
2061	type NoMethod GoogleCloudDialogflowCxV3IntentTrainingPhrasePart
2062	raw := NoMethod(*s)
2063	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2064}
2065
2066// GoogleCloudDialogflowCxV3Page: A Dialogflow CX conversation (session)
2067// can be described and visualized as a state machine. The states of a
2068// CX session are represented by pages. For each flow, you define many
2069// pages, where your combined pages can handle a complete conversation
2070// on the topics the flow is designed for. At any given moment, exactly
2071// one page is the current page, the current page is considered active,
2072// and the flow associated with that page is considered active. Every
2073// flow has a special start page. When a flow initially becomes active,
2074// the start page page becomes the current page. For each conversational
2075// turn, the current page will either stay the same or transition to
2076// another page. You configure each page to collect information from the
2077// end-user that is relevant for the conversational state represented by
2078// the page. For more information, see the Page guide
2079// (https://cloud.google.com/dialogflow/cx/docs/concept/page).
2080type GoogleCloudDialogflowCxV3Page struct {
2081	// DisplayName: Required. The human-readable name of the page, unique
2082	// within the agent.
2083	DisplayName string `json:"displayName,omitempty"`
2084
2085	// EntryFulfillment: The fulfillment to call when the session is
2086	// entering the page.
2087	EntryFulfillment *GoogleCloudDialogflowCxV3Fulfillment `json:"entryFulfillment,omitempty"`
2088
2089	// EventHandlers: Handlers associated with the page to handle events
2090	// such as webhook errors, no match or no input.
2091	EventHandlers []*GoogleCloudDialogflowCxV3EventHandler `json:"eventHandlers,omitempty"`
2092
2093	// Form: The form associated with the page, used for collecting
2094	// parameters relevant to the page.
2095	Form *GoogleCloudDialogflowCxV3Form `json:"form,omitempty"`
2096
2097	// Name: The unique identifier of the page. Required for the
2098	// Pages.UpdatePage method. Pages.CreatePage populates the name
2099	// automatically. Format: `projects//locations//agents//flows//pages/`.
2100	Name string `json:"name,omitempty"`
2101
2102	// TransitionRouteGroups: Ordered list of `TransitionRouteGroups`
2103	// associated with the page. Transition route groups must be unique
2104	// within a page. * If multiple transition routes within a page scope
2105	// refer to the same intent, then the precedence order is: page's
2106	// transition route -> page's transition route group -> flow's
2107	// transition routes. * If multiple transition route groups within a
2108	// page contain the same intent, then the first group in the ordered
2109	// list takes precedence.
2110	// Format:`projects//locations//agents//flows//transitionRouteGroups/`.
2111	TransitionRouteGroups []string `json:"transitionRouteGroups,omitempty"`
2112
2113	// TransitionRoutes: A list of transitions for the transition rules of
2114	// this page. They route the conversation to another page in the same
2115	// flow, or another flow. When we are in a certain page, the
2116	// TransitionRoutes are evalauted in the following order: *
2117	// TransitionRoutes defined in the page with intent specified. *
2118	// TransitionRoutes defined in the transition route groups with intent
2119	// specified. * TransitionRoutes defined in flow with intent specified.
2120	// * TransitionRoutes defined in the transition route groups with intent
2121	// specified. * TransitionRoutes defined in the page with only condition
2122	// specified. * TransitionRoutes defined in the transition route groups
2123	// with only condition specified.
2124	TransitionRoutes []*GoogleCloudDialogflowCxV3TransitionRoute `json:"transitionRoutes,omitempty"`
2125
2126	// ForceSendFields is a list of field names (e.g. "DisplayName") to
2127	// unconditionally include in API requests. By default, fields with
2128	// empty values are omitted from API requests. However, any non-pointer,
2129	// non-interface field appearing in ForceSendFields will be sent to the
2130	// server regardless of whether the field is empty or not. This may be
2131	// used to include empty fields in Patch requests.
2132	ForceSendFields []string `json:"-"`
2133
2134	// NullFields is a list of field names (e.g. "DisplayName") to include
2135	// in API requests with the JSON null value. By default, fields with
2136	// empty values are omitted from API requests. However, any field with
2137	// an empty value appearing in NullFields will be sent to the server as
2138	// null. It is an error if a field in this list has a non-empty value.
2139	// This may be used to include null fields in Patch requests.
2140	NullFields []string `json:"-"`
2141}
2142
2143func (s *GoogleCloudDialogflowCxV3Page) MarshalJSON() ([]byte, error) {
2144	type NoMethod GoogleCloudDialogflowCxV3Page
2145	raw := NoMethod(*s)
2146	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2147}
2148
2149// GoogleCloudDialogflowCxV3PageInfo: Represents page information
2150// communicated to and from the webhook.
2151type GoogleCloudDialogflowCxV3PageInfo struct {
2152	// CurrentPage: Always present for WebhookRequest. Ignored for
2153	// WebhookResponse. The unique identifier of the current page. Format:
2154	// `projects//locations//agents//flows//pages/`.
2155	CurrentPage string `json:"currentPage,omitempty"`
2156
2157	// FormInfo: Optional for both WebhookRequest and WebhookResponse.
2158	// Information about the form.
2159	FormInfo *GoogleCloudDialogflowCxV3PageInfoFormInfo `json:"formInfo,omitempty"`
2160
2161	// ForceSendFields is a list of field names (e.g. "CurrentPage") to
2162	// unconditionally include in API requests. By default, fields with
2163	// empty values are omitted from API requests. However, any non-pointer,
2164	// non-interface field appearing in ForceSendFields will be sent to the
2165	// server regardless of whether the field is empty or not. This may be
2166	// used to include empty fields in Patch requests.
2167	ForceSendFields []string `json:"-"`
2168
2169	// NullFields is a list of field names (e.g. "CurrentPage") to include
2170	// in API requests with the JSON null value. By default, fields with
2171	// empty values are omitted from API requests. However, any field with
2172	// an empty value appearing in NullFields will be sent to the server as
2173	// null. It is an error if a field in this list has a non-empty value.
2174	// This may be used to include null fields in Patch requests.
2175	NullFields []string `json:"-"`
2176}
2177
2178func (s *GoogleCloudDialogflowCxV3PageInfo) MarshalJSON() ([]byte, error) {
2179	type NoMethod GoogleCloudDialogflowCxV3PageInfo
2180	raw := NoMethod(*s)
2181	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2182}
2183
2184// GoogleCloudDialogflowCxV3PageInfoFormInfo: Represents form
2185// information.
2186type GoogleCloudDialogflowCxV3PageInfoFormInfo struct {
2187	// ParameterInfo: Optional for both WebhookRequest and WebhookResponse.
2188	// The parameters contained in the form. Note that the webhook cannot
2189	// add or remove any form parameter.
2190	ParameterInfo []*GoogleCloudDialogflowCxV3PageInfoFormInfoParameterInfo `json:"parameterInfo,omitempty"`
2191
2192	// ForceSendFields is a list of field names (e.g. "ParameterInfo") to
2193	// unconditionally include in API requests. By default, fields with
2194	// empty values are omitted from API requests. However, any non-pointer,
2195	// non-interface field appearing in ForceSendFields will be sent to the
2196	// server regardless of whether the field is empty or not. This may be
2197	// used to include empty fields in Patch requests.
2198	ForceSendFields []string `json:"-"`
2199
2200	// NullFields is a list of field names (e.g. "ParameterInfo") to include
2201	// in API requests with the JSON null value. By default, fields with
2202	// empty values are omitted from API requests. However, any field with
2203	// an empty value appearing in NullFields will be sent to the server as
2204	// null. It is an error if a field in this list has a non-empty value.
2205	// This may be used to include null fields in Patch requests.
2206	NullFields []string `json:"-"`
2207}
2208
2209func (s *GoogleCloudDialogflowCxV3PageInfoFormInfo) MarshalJSON() ([]byte, error) {
2210	type NoMethod GoogleCloudDialogflowCxV3PageInfoFormInfo
2211	raw := NoMethod(*s)
2212	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2213}
2214
2215// GoogleCloudDialogflowCxV3PageInfoFormInfoParameterInfo: Represents
2216// parameter information.
2217type GoogleCloudDialogflowCxV3PageInfoFormInfoParameterInfo struct {
2218	// DisplayName: Always present for WebhookRequest. Required for
2219	// WebhookResponse. The human-readable name of the parameter, unique
2220	// within the form. This field cannot be modified by the webhook.
2221	DisplayName string `json:"displayName,omitempty"`
2222
2223	// JustCollected: Optional for WebhookRequest. Ignored for
2224	// WebhookResponse. Indicates if the parameter value was just collected
2225	// on the last conversation turn.
2226	JustCollected bool `json:"justCollected,omitempty"`
2227
2228	// Required: Optional for both WebhookRequest and WebhookResponse.
2229	// Indicates whether the parameter is required. Optional parameters will
2230	// not trigger prompts; however, they are filled if the user specifies
2231	// them. Required parameters must be filled before form filling
2232	// concludes.
2233	Required bool `json:"required,omitempty"`
2234
2235	// State: Always present for WebhookRequest. Required for
2236	// WebhookResponse. The state of the parameter. This field can be set to
2237	// INVALID by the webhook to invalidate the parameter; other values set
2238	// by the webhook will be ignored.
2239	//
2240	// Possible values:
2241	//   "PARAMETER_STATE_UNSPECIFIED" - Not specified. This value should be
2242	// never used.
2243	//   "EMPTY" - Indicates that the parameter does not have a value.
2244	//   "INVALID" - Indicates that the parameter value is invalid. This
2245	// field can be used by the webhook to invalidate the parameter and ask
2246	// the server to collect it from the user again.
2247	//   "FILLED" - Indicates that the parameter has a value.
2248	State string `json:"state,omitempty"`
2249
2250	// Value: Optional for both WebhookRequest and WebhookResponse. The
2251	// value of the parameter. This field can be set by the webhook to
2252	// change the parameter value.
2253	Value interface{} `json:"value,omitempty"`
2254
2255	// ForceSendFields is a list of field names (e.g. "DisplayName") to
2256	// unconditionally include in API requests. By default, fields with
2257	// empty values are omitted from API requests. However, any non-pointer,
2258	// non-interface field appearing in ForceSendFields will be sent to the
2259	// server regardless of whether the field is empty or not. This may be
2260	// used to include empty fields in Patch requests.
2261	ForceSendFields []string `json:"-"`
2262
2263	// NullFields is a list of field names (e.g. "DisplayName") to include
2264	// in API requests with the JSON null value. By default, fields with
2265	// empty values are omitted from API requests. However, any field with
2266	// an empty value appearing in NullFields will be sent to the server as
2267	// null. It is an error if a field in this list has a non-empty value.
2268	// This may be used to include null fields in Patch requests.
2269	NullFields []string `json:"-"`
2270}
2271
2272func (s *GoogleCloudDialogflowCxV3PageInfoFormInfoParameterInfo) MarshalJSON() ([]byte, error) {
2273	type NoMethod GoogleCloudDialogflowCxV3PageInfoFormInfoParameterInfo
2274	raw := NoMethod(*s)
2275	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2276}
2277
2278// GoogleCloudDialogflowCxV3QueryInput: Represents the query input. It
2279// can contain one of: 1. A conversational query in the form of text. 2.
2280// An intent query that specifies which intent to trigger. 3. Natural
2281// language speech audio to be processed. 4. An event to be triggered.
2282type GoogleCloudDialogflowCxV3QueryInput struct {
2283	// Audio: The natural language speech audio to be processed.
2284	Audio *GoogleCloudDialogflowCxV3AudioInput `json:"audio,omitempty"`
2285
2286	// Dtmf: The DTMF event to be handled.
2287	Dtmf *GoogleCloudDialogflowCxV3DtmfInput `json:"dtmf,omitempty"`
2288
2289	// Event: The event to be triggered.
2290	Event *GoogleCloudDialogflowCxV3EventInput `json:"event,omitempty"`
2291
2292	// Intent: The intent to be triggered.
2293	Intent *GoogleCloudDialogflowCxV3IntentInput `json:"intent,omitempty"`
2294
2295	// LanguageCode: Required. The language of the input. See Language
2296	// Support
2297	// (https://cloud.google.com/dialogflow/cx/docs/reference/language) for
2298	// a list of the currently supported language codes. Note that queries
2299	// in the same session do not necessarily need to specify the same
2300	// language.
2301	LanguageCode string `json:"languageCode,omitempty"`
2302
2303	// Text: The natural language text to be processed.
2304	Text *GoogleCloudDialogflowCxV3TextInput `json:"text,omitempty"`
2305
2306	// ForceSendFields is a list of field names (e.g. "Audio") to
2307	// unconditionally include in API requests. By default, fields with
2308	// empty values are omitted from API requests. However, any non-pointer,
2309	// non-interface field appearing in ForceSendFields will be sent to the
2310	// server regardless of whether the field is empty or not. This may be
2311	// used to include empty fields in Patch requests.
2312	ForceSendFields []string `json:"-"`
2313
2314	// NullFields is a list of field names (e.g. "Audio") to include in API
2315	// requests with the JSON null value. By default, fields with empty
2316	// values are omitted from API requests. However, any field with an
2317	// empty value appearing in NullFields will be sent to the server as
2318	// null. It is an error if a field in this list has a non-empty value.
2319	// This may be used to include null fields in Patch requests.
2320	NullFields []string `json:"-"`
2321}
2322
2323func (s *GoogleCloudDialogflowCxV3QueryInput) MarshalJSON() ([]byte, error) {
2324	type NoMethod GoogleCloudDialogflowCxV3QueryInput
2325	raw := NoMethod(*s)
2326	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2327}
2328
2329// GoogleCloudDialogflowCxV3ReloadDocumentOperationMetadata: Metadata
2330// for ReloadDocument operation.
2331type GoogleCloudDialogflowCxV3ReloadDocumentOperationMetadata struct {
2332	// GenericMetadata: The generic information of the operation.
2333	GenericMetadata *GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
2334
2335	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
2336	// unconditionally include in API requests. By default, fields with
2337	// empty values are omitted from API requests. However, any non-pointer,
2338	// non-interface field appearing in ForceSendFields will be sent to the
2339	// server regardless of whether the field is empty or not. This may be
2340	// used to include empty fields in Patch requests.
2341	ForceSendFields []string `json:"-"`
2342
2343	// NullFields is a list of field names (e.g. "GenericMetadata") to
2344	// include in API requests with the JSON null value. By default, fields
2345	// with empty values are omitted from API requests. However, any field
2346	// with an empty value appearing in NullFields will be sent to the
2347	// server as null. It is an error if a field in this list has a
2348	// non-empty value. This may be used to include null fields in Patch
2349	// requests.
2350	NullFields []string `json:"-"`
2351}
2352
2353func (s *GoogleCloudDialogflowCxV3ReloadDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
2354	type NoMethod GoogleCloudDialogflowCxV3ReloadDocumentOperationMetadata
2355	raw := NoMethod(*s)
2356	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2357}
2358
2359// GoogleCloudDialogflowCxV3ResponseMessage: Represents a response
2360// message that can be returned by a conversational agent. Response
2361// messages are also used for output audio synthesis. The approach is as
2362// follows: * If at least one OutputAudioText response is present, then
2363// all OutputAudioText responses are linearly concatenated, and the
2364// result is used for output audio synthesis. * If the OutputAudioText
2365// responses are a mixture of text and SSML, then the concatenated
2366// result is treated as SSML; otherwise, the result is treated as either
2367// text or SSML as appropriate. The agent designer should ideally use
2368// either text or SSML consistently throughout the bot design. *
2369// Otherwise, all Text responses are linearly concatenated, and the
2370// result is used for output audio synthesis. This approach allows for
2371// more sophisticated user experience scenarios, where the text
2372// displayed to the user may differ from what is heard.
2373type GoogleCloudDialogflowCxV3ResponseMessage struct {
2374	// ConversationSuccess: Indicates that the conversation succeeded.
2375	ConversationSuccess *GoogleCloudDialogflowCxV3ResponseMessageConversationSuccess `json:"conversationSuccess,omitempty"`
2376
2377	// EndInteraction: Output only. A signal that indicates the interaction
2378	// with the Dialogflow agent has ended. This message is generated by
2379	// Dialogflow only when the conversation reaches `END_SESSION` page. It
2380	// is not supposed to be defined by the user. It's guaranteed that there
2381	// is at most one such message in each response.
2382	EndInteraction *GoogleCloudDialogflowCxV3ResponseMessageEndInteraction `json:"endInteraction,omitempty"`
2383
2384	// LiveAgentHandoff: Hands off conversation to a human agent.
2385	LiveAgentHandoff *GoogleCloudDialogflowCxV3ResponseMessageLiveAgentHandoff `json:"liveAgentHandoff,omitempty"`
2386
2387	// MixedAudio: Output only. An audio response message composed of both
2388	// the synthesized Dialogflow agent responses and responses defined via
2389	// play_audio. This message is generated by Dialogflow only and not
2390	// supposed to be defined by the user.
2391	MixedAudio *GoogleCloudDialogflowCxV3ResponseMessageMixedAudio `json:"mixedAudio,omitempty"`
2392
2393	// OutputAudioText: A text or ssml response that is preferentially used
2394	// for TTS output audio synthesis, as described in the comment on the
2395	// ResponseMessage message.
2396	OutputAudioText *GoogleCloudDialogflowCxV3ResponseMessageOutputAudioText `json:"outputAudioText,omitempty"`
2397
2398	// Payload: Returns a response containing a custom, platform-specific
2399	// payload.
2400	Payload googleapi.RawMessage `json:"payload,omitempty"`
2401
2402	// PlayAudio: Signal that the client should play an audio clip hosted at
2403	// a client-specific URI. Dialogflow uses this to construct mixed_audio.
2404	// However, Dialogflow itself does not try to read or process the URI in
2405	// any way.
2406	PlayAudio *GoogleCloudDialogflowCxV3ResponseMessagePlayAudio `json:"playAudio,omitempty"`
2407
2408	// Text: Returns a text response.
2409	Text *GoogleCloudDialogflowCxV3ResponseMessageText `json:"text,omitempty"`
2410
2411	// ForceSendFields is a list of field names (e.g. "ConversationSuccess")
2412	// to unconditionally include in API requests. By default, fields with
2413	// empty values are omitted from API requests. However, any non-pointer,
2414	// non-interface field appearing in ForceSendFields will be sent to the
2415	// server regardless of whether the field is empty or not. This may be
2416	// used to include empty fields in Patch requests.
2417	ForceSendFields []string `json:"-"`
2418
2419	// NullFields is a list of field names (e.g. "ConversationSuccess") to
2420	// include in API requests with the JSON null value. By default, fields
2421	// with empty values are omitted from API requests. However, any field
2422	// with an empty value appearing in NullFields will be sent to the
2423	// server as null. It is an error if a field in this list has a
2424	// non-empty value. This may be used to include null fields in Patch
2425	// requests.
2426	NullFields []string `json:"-"`
2427}
2428
2429func (s *GoogleCloudDialogflowCxV3ResponseMessage) MarshalJSON() ([]byte, error) {
2430	type NoMethod GoogleCloudDialogflowCxV3ResponseMessage
2431	raw := NoMethod(*s)
2432	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2433}
2434
2435// GoogleCloudDialogflowCxV3ResponseMessageConversationSuccess:
2436// Indicates that the conversation succeeded, i.e., the bot handled the
2437// issue that the customer talked to it about. Dialogflow only uses this
2438// to determine which conversations should be counted as successful and
2439// doesn't process the metadata in this message in any way. Note that
2440// Dialogflow also considers conversations that get to the conversation
2441// end page as successful even if they don't return ConversationSuccess.
2442// You may set this, for example: * In the entry_fulfillment of a Page
2443// if entering the page indicates that the conversation succeeded. * In
2444// a webhook response when you determine that you handled the customer
2445// issue.
2446type GoogleCloudDialogflowCxV3ResponseMessageConversationSuccess struct {
2447	// Metadata: Custom metadata. Dialogflow doesn't impose any structure on
2448	// this.
2449	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
2450
2451	// ForceSendFields is a list of field names (e.g. "Metadata") to
2452	// unconditionally include in API requests. By default, fields with
2453	// empty values are omitted from API requests. However, any non-pointer,
2454	// non-interface field appearing in ForceSendFields will be sent to the
2455	// server regardless of whether the field is empty or not. This may be
2456	// used to include empty fields in Patch requests.
2457	ForceSendFields []string `json:"-"`
2458
2459	// NullFields is a list of field names (e.g. "Metadata") to include in
2460	// API requests with the JSON null value. By default, fields with empty
2461	// values are omitted from API requests. However, any field with an
2462	// empty value appearing in NullFields will be sent to the server as
2463	// null. It is an error if a field in this list has a non-empty value.
2464	// This may be used to include null fields in Patch requests.
2465	NullFields []string `json:"-"`
2466}
2467
2468func (s *GoogleCloudDialogflowCxV3ResponseMessageConversationSuccess) MarshalJSON() ([]byte, error) {
2469	type NoMethod GoogleCloudDialogflowCxV3ResponseMessageConversationSuccess
2470	raw := NoMethod(*s)
2471	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2472}
2473
2474// GoogleCloudDialogflowCxV3ResponseMessageEndInteraction: Indicates
2475// that interaction with the Dialogflow agent has ended. This message is
2476// generated by Dialogflow only and not supposed to be defined by the
2477// user.
2478type GoogleCloudDialogflowCxV3ResponseMessageEndInteraction struct {
2479}
2480
2481// GoogleCloudDialogflowCxV3ResponseMessageLiveAgentHandoff: Indicates
2482// that the conversation should be handed off to a live agent.
2483// Dialogflow only uses this to determine which conversations were
2484// handed off to a human agent for measurement purposes. What else to do
2485// with this signal is up to you and your handoff procedures. You may
2486// set this, for example: * In the entry_fulfillment of a Page if
2487// entering the page indicates something went extremely wrong in the
2488// conversation. * In a webhook response when you determine that the
2489// customer issue can only be handled by a human.
2490type GoogleCloudDialogflowCxV3ResponseMessageLiveAgentHandoff struct {
2491	// Metadata: Custom metadata for your handoff procedure. Dialogflow
2492	// doesn't impose any structure on this.
2493	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
2494
2495	// ForceSendFields is a list of field names (e.g. "Metadata") to
2496	// unconditionally include in API requests. By default, fields with
2497	// empty values are omitted from API requests. However, any non-pointer,
2498	// non-interface field appearing in ForceSendFields will be sent to the
2499	// server regardless of whether the field is empty or not. This may be
2500	// used to include empty fields in Patch requests.
2501	ForceSendFields []string `json:"-"`
2502
2503	// NullFields is a list of field names (e.g. "Metadata") to include in
2504	// API requests with the JSON null value. By default, fields with empty
2505	// values are omitted from API requests. However, any field with an
2506	// empty value appearing in NullFields will be sent to the server as
2507	// null. It is an error if a field in this list has a non-empty value.
2508	// This may be used to include null fields in Patch requests.
2509	NullFields []string `json:"-"`
2510}
2511
2512func (s *GoogleCloudDialogflowCxV3ResponseMessageLiveAgentHandoff) MarshalJSON() ([]byte, error) {
2513	type NoMethod GoogleCloudDialogflowCxV3ResponseMessageLiveAgentHandoff
2514	raw := NoMethod(*s)
2515	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2516}
2517
2518// GoogleCloudDialogflowCxV3ResponseMessageMixedAudio: Represents an
2519// audio message that is composed of both segments synthesized from the
2520// Dialogflow agent prompts and ones hosted externally at the specified
2521// URIs. The external URIs are specified via play_audio. This message is
2522// generated by Dialogflow only and not supposed to be defined by the
2523// user.
2524type GoogleCloudDialogflowCxV3ResponseMessageMixedAudio struct {
2525	// Segments: Segments this audio response is composed of.
2526	Segments []*GoogleCloudDialogflowCxV3ResponseMessageMixedAudioSegment `json:"segments,omitempty"`
2527
2528	// ForceSendFields is a list of field names (e.g. "Segments") to
2529	// unconditionally include in API requests. By default, fields with
2530	// empty values are omitted from API requests. However, any non-pointer,
2531	// non-interface field appearing in ForceSendFields will be sent to the
2532	// server regardless of whether the field is empty or not. This may be
2533	// used to include empty fields in Patch requests.
2534	ForceSendFields []string `json:"-"`
2535
2536	// NullFields is a list of field names (e.g. "Segments") to include in
2537	// API requests with the JSON null value. By default, fields with empty
2538	// values are omitted from API requests. However, any field with an
2539	// empty value appearing in NullFields will be sent to the server as
2540	// null. It is an error if a field in this list has a non-empty value.
2541	// This may be used to include null fields in Patch requests.
2542	NullFields []string `json:"-"`
2543}
2544
2545func (s *GoogleCloudDialogflowCxV3ResponseMessageMixedAudio) MarshalJSON() ([]byte, error) {
2546	type NoMethod GoogleCloudDialogflowCxV3ResponseMessageMixedAudio
2547	raw := NoMethod(*s)
2548	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2549}
2550
2551// GoogleCloudDialogflowCxV3ResponseMessageMixedAudioSegment: Represents
2552// one segment of audio.
2553type GoogleCloudDialogflowCxV3ResponseMessageMixedAudioSegment struct {
2554	// AllowPlaybackInterruption: Output only. Whether the playback of this
2555	// segment can be interrupted by the end user's speech and the client
2556	// should then start the next Dialogflow request.
2557	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
2558
2559	// Audio: Raw audio synthesized from the Dialogflow agent's response
2560	// using the output config specified in the request.
2561	Audio string `json:"audio,omitempty"`
2562
2563	// Uri: Client-specific URI that points to an audio clip accessible to
2564	// the client. Dialogflow does not impose any validation on it.
2565	Uri string `json:"uri,omitempty"`
2566
2567	// ForceSendFields is a list of field names (e.g.
2568	// "AllowPlaybackInterruption") to unconditionally include in API
2569	// requests. By default, fields with empty values are omitted from API
2570	// requests. However, any non-pointer, non-interface field appearing in
2571	// ForceSendFields will be sent to the server regardless of whether the
2572	// field is empty or not. This may be used to include empty fields in
2573	// Patch requests.
2574	ForceSendFields []string `json:"-"`
2575
2576	// NullFields is a list of field names (e.g.
2577	// "AllowPlaybackInterruption") to include in API requests with the JSON
2578	// null value. By default, fields with empty values are omitted from API
2579	// requests. However, any field with an empty value appearing in
2580	// NullFields will be sent to the server as null. It is an error if a
2581	// field in this list has a non-empty value. This may be used to include
2582	// null fields in Patch requests.
2583	NullFields []string `json:"-"`
2584}
2585
2586func (s *GoogleCloudDialogflowCxV3ResponseMessageMixedAudioSegment) MarshalJSON() ([]byte, error) {
2587	type NoMethod GoogleCloudDialogflowCxV3ResponseMessageMixedAudioSegment
2588	raw := NoMethod(*s)
2589	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2590}
2591
2592// GoogleCloudDialogflowCxV3ResponseMessageOutputAudioText: A text or
2593// ssml response that is preferentially used for TTS output audio
2594// synthesis, as described in the comment on the ResponseMessage
2595// message.
2596type GoogleCloudDialogflowCxV3ResponseMessageOutputAudioText struct {
2597	// AllowPlaybackInterruption: Output only. Whether the playback of this
2598	// message can be interrupted by the end user's speech and the client
2599	// can then starts the next Dialogflow request.
2600	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
2601
2602	// Ssml: The SSML text to be synthesized. For more information, see SSML
2603	// (/speech/text-to-speech/docs/ssml).
2604	Ssml string `json:"ssml,omitempty"`
2605
2606	// Text: The raw text to be synthesized.
2607	Text string `json:"text,omitempty"`
2608
2609	// ForceSendFields is a list of field names (e.g.
2610	// "AllowPlaybackInterruption") to unconditionally include in API
2611	// requests. By default, fields with empty values are omitted from API
2612	// requests. However, any non-pointer, non-interface field appearing in
2613	// ForceSendFields will be sent to the server regardless of whether the
2614	// field is empty or not. This may be used to include empty fields in
2615	// Patch requests.
2616	ForceSendFields []string `json:"-"`
2617
2618	// NullFields is a list of field names (e.g.
2619	// "AllowPlaybackInterruption") to include in API requests with the JSON
2620	// null value. By default, fields with empty values are omitted from API
2621	// requests. However, any field with an empty value appearing in
2622	// NullFields will be sent to the server as null. It is an error if a
2623	// field in this list has a non-empty value. This may be used to include
2624	// null fields in Patch requests.
2625	NullFields []string `json:"-"`
2626}
2627
2628func (s *GoogleCloudDialogflowCxV3ResponseMessageOutputAudioText) MarshalJSON() ([]byte, error) {
2629	type NoMethod GoogleCloudDialogflowCxV3ResponseMessageOutputAudioText
2630	raw := NoMethod(*s)
2631	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2632}
2633
2634// GoogleCloudDialogflowCxV3ResponseMessagePlayAudio: Specifies an audio
2635// clip to be played by the client as part of the response.
2636type GoogleCloudDialogflowCxV3ResponseMessagePlayAudio struct {
2637	// AllowPlaybackInterruption: Output only. Whether the playback of this
2638	// message can be interrupted by the end user's speech and the client
2639	// can then starts the next Dialogflow request.
2640	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
2641
2642	// AudioUri: Required. URI of the audio clip. Dialogflow does not impose
2643	// any validation on this value. It is specific to the client that reads
2644	// it.
2645	AudioUri string `json:"audioUri,omitempty"`
2646
2647	// ForceSendFields is a list of field names (e.g.
2648	// "AllowPlaybackInterruption") to unconditionally include in API
2649	// requests. By default, fields with empty values are omitted from API
2650	// requests. However, any non-pointer, non-interface field appearing in
2651	// ForceSendFields will be sent to the server regardless of whether the
2652	// field is empty or not. This may be used to include empty fields in
2653	// Patch requests.
2654	ForceSendFields []string `json:"-"`
2655
2656	// NullFields is a list of field names (e.g.
2657	// "AllowPlaybackInterruption") to include in API requests with the JSON
2658	// null value. By default, fields with empty values are omitted from API
2659	// requests. However, any field with an empty value appearing in
2660	// NullFields will be sent to the server as null. It is an error if a
2661	// field in this list has a non-empty value. This may be used to include
2662	// null fields in Patch requests.
2663	NullFields []string `json:"-"`
2664}
2665
2666func (s *GoogleCloudDialogflowCxV3ResponseMessagePlayAudio) MarshalJSON() ([]byte, error) {
2667	type NoMethod GoogleCloudDialogflowCxV3ResponseMessagePlayAudio
2668	raw := NoMethod(*s)
2669	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2670}
2671
2672// GoogleCloudDialogflowCxV3ResponseMessageText: The text response
2673// message.
2674type GoogleCloudDialogflowCxV3ResponseMessageText struct {
2675	// AllowPlaybackInterruption: Output only. Whether the playback of this
2676	// message can be interrupted by the end user's speech and the client
2677	// can then starts the next Dialogflow request.
2678	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
2679
2680	// Text: Required. A collection of text responses.
2681	Text []string `json:"text,omitempty"`
2682
2683	// ForceSendFields is a list of field names (e.g.
2684	// "AllowPlaybackInterruption") to unconditionally include in API
2685	// requests. By default, fields with empty values are omitted from API
2686	// requests. However, any non-pointer, non-interface field appearing in
2687	// ForceSendFields will be sent to the server regardless of whether the
2688	// field is empty or not. This may be used to include empty fields in
2689	// Patch requests.
2690	ForceSendFields []string `json:"-"`
2691
2692	// NullFields is a list of field names (e.g.
2693	// "AllowPlaybackInterruption") to include in API requests with the JSON
2694	// null value. By default, fields with empty values are omitted from API
2695	// requests. However, any field with an empty value appearing in
2696	// NullFields will be sent to the server as null. It is an error if a
2697	// field in this list has a non-empty value. This may be used to include
2698	// null fields in Patch requests.
2699	NullFields []string `json:"-"`
2700}
2701
2702func (s *GoogleCloudDialogflowCxV3ResponseMessageText) MarshalJSON() ([]byte, error) {
2703	type NoMethod GoogleCloudDialogflowCxV3ResponseMessageText
2704	raw := NoMethod(*s)
2705	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2706}
2707
2708// GoogleCloudDialogflowCxV3RunTestCaseMetadata: Metadata returned for
2709// the TestCases.RunTestCase long running operation.
2710type GoogleCloudDialogflowCxV3RunTestCaseMetadata struct {
2711}
2712
2713// GoogleCloudDialogflowCxV3RunTestCaseResponse: The response message
2714// for TestCases.RunTestCase.
2715type GoogleCloudDialogflowCxV3RunTestCaseResponse struct {
2716	// Result: The result.
2717	Result *GoogleCloudDialogflowCxV3TestCaseResult `json:"result,omitempty"`
2718
2719	// ForceSendFields is a list of field names (e.g. "Result") to
2720	// unconditionally include in API requests. By default, fields with
2721	// empty values are omitted from API requests. However, any non-pointer,
2722	// non-interface field appearing in ForceSendFields will be sent to the
2723	// server regardless of whether the field is empty or not. This may be
2724	// used to include empty fields in Patch requests.
2725	ForceSendFields []string `json:"-"`
2726
2727	// NullFields is a list of field names (e.g. "Result") to include in API
2728	// requests with the JSON null value. By default, fields with empty
2729	// values are omitted from API requests. However, any field with an
2730	// empty value appearing in NullFields will be sent to the server as
2731	// null. It is an error if a field in this list has a non-empty value.
2732	// This may be used to include null fields in Patch requests.
2733	NullFields []string `json:"-"`
2734}
2735
2736func (s *GoogleCloudDialogflowCxV3RunTestCaseResponse) MarshalJSON() ([]byte, error) {
2737	type NoMethod GoogleCloudDialogflowCxV3RunTestCaseResponse
2738	raw := NoMethod(*s)
2739	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2740}
2741
2742// GoogleCloudDialogflowCxV3SessionInfo: Represents session information
2743// communicated to and from the webhook.
2744type GoogleCloudDialogflowCxV3SessionInfo struct {
2745	// Parameters: Optional for WebhookRequest. Optional for
2746	// WebhookResponse. All parameters collected from forms and intents
2747	// during the session. Parameters can be created, updated, or removed by
2748	// the webhook. To remove a parameter from the session, the webhook
2749	// should explicitly set the parameter value to null in WebhookResponse.
2750	// The map is keyed by parameters' display names.
2751	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
2752
2753	// Session: Always present for WebhookRequest. Ignored for
2754	// WebhookResponse. The unique identifier of the session. This field can
2755	// be used by the webhook to identify a session. Format:
2756	// `projects//locations//agents//sessions/` or
2757	// `projects//locations//agents//environments//sessions/` if environment
2758	// is specified.
2759	Session string `json:"session,omitempty"`
2760
2761	// ForceSendFields is a list of field names (e.g. "Parameters") to
2762	// unconditionally include in API requests. By default, fields with
2763	// empty values are omitted from API requests. However, any non-pointer,
2764	// non-interface field appearing in ForceSendFields will be sent to the
2765	// server regardless of whether the field is empty or not. This may be
2766	// used to include empty fields in Patch requests.
2767	ForceSendFields []string `json:"-"`
2768
2769	// NullFields is a list of field names (e.g. "Parameters") to include in
2770	// API requests with the JSON null value. By default, fields with empty
2771	// values are omitted from API requests. However, any field with an
2772	// empty value appearing in NullFields will be sent to the server as
2773	// null. It is an error if a field in this list has a non-empty value.
2774	// This may be used to include null fields in Patch requests.
2775	NullFields []string `json:"-"`
2776}
2777
2778func (s *GoogleCloudDialogflowCxV3SessionInfo) MarshalJSON() ([]byte, error) {
2779	type NoMethod GoogleCloudDialogflowCxV3SessionInfo
2780	raw := NoMethod(*s)
2781	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2782}
2783
2784// GoogleCloudDialogflowCxV3TestCase: Represents a test case.
2785type GoogleCloudDialogflowCxV3TestCase struct {
2786	// CreationTime: Output only. When the test was created.
2787	CreationTime string `json:"creationTime,omitempty"`
2788
2789	// DisplayName: Required. The human-readable name of the test case,
2790	// unique within the agent. Limit of 200 characters.
2791	DisplayName string `json:"displayName,omitempty"`
2792
2793	// LastTestResult: The latest test result.
2794	LastTestResult *GoogleCloudDialogflowCxV3TestCaseResult `json:"lastTestResult,omitempty"`
2795
2796	// Name: The unique identifier of the test case.
2797	// TestCases.CreateTestCase will populate the name automatically.
2798	// Otherwise use format: `projects//locations//agents/ /testCases/`.
2799	Name string `json:"name,omitempty"`
2800
2801	// Notes: Additional freeform notes about the test case. Limit of 400
2802	// characters.
2803	Notes string `json:"notes,omitempty"`
2804
2805	// Tags: Tags are short descriptions that users may apply to test cases
2806	// for organizational and filtering purposes. Each tag should start with
2807	// "#" and has a limit of 30 characters.
2808	Tags []string `json:"tags,omitempty"`
2809
2810	// TestCaseConversationTurns: The conversation turns uttered when the
2811	// test case was created, in chronological order. These include the
2812	// canonical set of agent utterances that should occur when the agent is
2813	// working properly.
2814	TestCaseConversationTurns []*GoogleCloudDialogflowCxV3ConversationTurn `json:"testCaseConversationTurns,omitempty"`
2815
2816	// TestConfig: Config for the test case.
2817	TestConfig *GoogleCloudDialogflowCxV3TestConfig `json:"testConfig,omitempty"`
2818
2819	// ForceSendFields is a list of field names (e.g. "CreationTime") to
2820	// unconditionally include in API requests. By default, fields with
2821	// empty values are omitted from API requests. However, any non-pointer,
2822	// non-interface field appearing in ForceSendFields will be sent to the
2823	// server regardless of whether the field is empty or not. This may be
2824	// used to include empty fields in Patch requests.
2825	ForceSendFields []string `json:"-"`
2826
2827	// NullFields is a list of field names (e.g. "CreationTime") to include
2828	// in API requests with the JSON null value. By default, fields with
2829	// empty values are omitted from API requests. However, any field with
2830	// an empty value appearing in NullFields will be sent to the server as
2831	// null. It is an error if a field in this list has a non-empty value.
2832	// This may be used to include null fields in Patch requests.
2833	NullFields []string `json:"-"`
2834}
2835
2836func (s *GoogleCloudDialogflowCxV3TestCase) MarshalJSON() ([]byte, error) {
2837	type NoMethod GoogleCloudDialogflowCxV3TestCase
2838	raw := NoMethod(*s)
2839	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2840}
2841
2842// GoogleCloudDialogflowCxV3TestCaseError: Error info for importing a
2843// test.
2844type GoogleCloudDialogflowCxV3TestCaseError struct {
2845	// Status: The status associated with the test case.
2846	Status *GoogleRpcStatus `json:"status,omitempty"`
2847
2848	// TestCase: The test case.
2849	TestCase *GoogleCloudDialogflowCxV3TestCase `json:"testCase,omitempty"`
2850
2851	// ForceSendFields is a list of field names (e.g. "Status") to
2852	// unconditionally include in API requests. By default, fields with
2853	// empty values are omitted from API requests. However, any non-pointer,
2854	// non-interface field appearing in ForceSendFields will be sent to the
2855	// server regardless of whether the field is empty or not. This may be
2856	// used to include empty fields in Patch requests.
2857	ForceSendFields []string `json:"-"`
2858
2859	// NullFields is a list of field names (e.g. "Status") to include in API
2860	// requests with the JSON null value. By default, fields with empty
2861	// values are omitted from API requests. However, any field with an
2862	// empty value appearing in NullFields will be sent to the server as
2863	// null. It is an error if a field in this list has a non-empty value.
2864	// This may be used to include null fields in Patch requests.
2865	NullFields []string `json:"-"`
2866}
2867
2868func (s *GoogleCloudDialogflowCxV3TestCaseError) MarshalJSON() ([]byte, error) {
2869	type NoMethod GoogleCloudDialogflowCxV3TestCaseError
2870	raw := NoMethod(*s)
2871	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2872}
2873
2874// GoogleCloudDialogflowCxV3TestCaseResult: Represents a result from
2875// running a test case in an agent environment.
2876type GoogleCloudDialogflowCxV3TestCaseResult struct {
2877	// ConversationTurns: The conversation turns uttered during the test
2878	// case replay in chronological order.
2879	ConversationTurns []*GoogleCloudDialogflowCxV3ConversationTurn `json:"conversationTurns,omitempty"`
2880
2881	// Environment: Environment where the test was run. If not set, it
2882	// indicates the draft environment.
2883	Environment string `json:"environment,omitempty"`
2884
2885	// Name: The resource name for the test case result. Format:
2886	// `projects//locations//agents//testCases/ /results/`.
2887	Name string `json:"name,omitempty"`
2888
2889	// TestResult: Whether the test case passed in the agent environment.
2890	//
2891	// Possible values:
2892	//   "TEST_RESULT_UNSPECIFIED" - Not specified. Should never be used.
2893	//   "PASSED" - The test passed.
2894	//   "FAILED" - The test did not pass.
2895	TestResult string `json:"testResult,omitempty"`
2896
2897	// TestTime: The time that the test was run.
2898	TestTime string `json:"testTime,omitempty"`
2899
2900	// ForceSendFields is a list of field names (e.g. "ConversationTurns")
2901	// to unconditionally include in API requests. By default, fields with
2902	// empty values are omitted from API requests. However, any non-pointer,
2903	// non-interface field appearing in ForceSendFields will be sent to the
2904	// server regardless of whether the field is empty or not. This may be
2905	// used to include empty fields in Patch requests.
2906	ForceSendFields []string `json:"-"`
2907
2908	// NullFields is a list of field names (e.g. "ConversationTurns") to
2909	// include in API requests with the JSON null value. By default, fields
2910	// with empty values are omitted from API requests. However, any field
2911	// with an empty value appearing in NullFields will be sent to the
2912	// server as null. It is an error if a field in this list has a
2913	// non-empty value. This may be used to include null fields in Patch
2914	// requests.
2915	NullFields []string `json:"-"`
2916}
2917
2918func (s *GoogleCloudDialogflowCxV3TestCaseResult) MarshalJSON() ([]byte, error) {
2919	type NoMethod GoogleCloudDialogflowCxV3TestCaseResult
2920	raw := NoMethod(*s)
2921	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2922}
2923
2924// GoogleCloudDialogflowCxV3TestConfig: Represents configurations for a
2925// test case.
2926type GoogleCloudDialogflowCxV3TestConfig struct {
2927	// Flow: Flow name. If not set, default start flow is assumed. Format:
2928	// `projects//locations//agents//flows/`.
2929	Flow string `json:"flow,omitempty"`
2930
2931	// TrackingParameters: Session parameters to be compared when
2932	// calculating differences.
2933	TrackingParameters []string `json:"trackingParameters,omitempty"`
2934
2935	// ForceSendFields is a list of field names (e.g. "Flow") to
2936	// unconditionally include in API requests. By default, fields with
2937	// empty values are omitted from API requests. However, any non-pointer,
2938	// non-interface field appearing in ForceSendFields will be sent to the
2939	// server regardless of whether the field is empty or not. This may be
2940	// used to include empty fields in Patch requests.
2941	ForceSendFields []string `json:"-"`
2942
2943	// NullFields is a list of field names (e.g. "Flow") to include in API
2944	// requests with the JSON null value. By default, fields with empty
2945	// values are omitted from API requests. However, any field with an
2946	// empty value appearing in NullFields will be sent to the server as
2947	// null. It is an error if a field in this list has a non-empty value.
2948	// This may be used to include null fields in Patch requests.
2949	NullFields []string `json:"-"`
2950}
2951
2952func (s *GoogleCloudDialogflowCxV3TestConfig) MarshalJSON() ([]byte, error) {
2953	type NoMethod GoogleCloudDialogflowCxV3TestConfig
2954	raw := NoMethod(*s)
2955	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2956}
2957
2958// GoogleCloudDialogflowCxV3TestError: Error info for running a test.
2959type GoogleCloudDialogflowCxV3TestError struct {
2960	// Status: The status associated with the test.
2961	Status *GoogleRpcStatus `json:"status,omitempty"`
2962
2963	// TestCase: The test case resource name.
2964	TestCase string `json:"testCase,omitempty"`
2965
2966	// TestTime: The timestamp when the test was completed.
2967	TestTime string `json:"testTime,omitempty"`
2968
2969	// ForceSendFields is a list of field names (e.g. "Status") to
2970	// unconditionally include in API requests. By default, fields with
2971	// empty values are omitted from API requests. However, any non-pointer,
2972	// non-interface field appearing in ForceSendFields will be sent to the
2973	// server regardless of whether the field is empty or not. This may be
2974	// used to include empty fields in Patch requests.
2975	ForceSendFields []string `json:"-"`
2976
2977	// NullFields is a list of field names (e.g. "Status") to include in API
2978	// requests with the JSON null value. By default, fields with empty
2979	// values are omitted from API requests. However, any field with an
2980	// empty value appearing in NullFields will be sent to the server as
2981	// null. It is an error if a field in this list has a non-empty value.
2982	// This may be used to include null fields in Patch requests.
2983	NullFields []string `json:"-"`
2984}
2985
2986func (s *GoogleCloudDialogflowCxV3TestError) MarshalJSON() ([]byte, error) {
2987	type NoMethod GoogleCloudDialogflowCxV3TestError
2988	raw := NoMethod(*s)
2989	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2990}
2991
2992// GoogleCloudDialogflowCxV3TestRunDifference: The description of
2993// differences between original and replayed agent output.
2994type GoogleCloudDialogflowCxV3TestRunDifference struct {
2995	// Description: A description of the diff, showing the actual output vs
2996	// expected output.
2997	Description string `json:"description,omitempty"`
2998
2999	// Type: The type of diff.
3000	//
3001	// Possible values:
3002	//   "DIFF_TYPE_UNSPECIFIED" - Should never be used.
3003	//   "INTENT" - The intent.
3004	//   "PAGE" - The page.
3005	//   "PARAMETERS" - The parameters.
3006	//   "UTTERANCE" - The message utterance.
3007	Type string `json:"type,omitempty"`
3008
3009	// ForceSendFields is a list of field names (e.g. "Description") to
3010	// unconditionally include in API requests. By default, fields with
3011	// empty values are omitted from API requests. However, any non-pointer,
3012	// non-interface field appearing in ForceSendFields will be sent to the
3013	// server regardless of whether the field is empty or not. This may be
3014	// used to include empty fields in Patch requests.
3015	ForceSendFields []string `json:"-"`
3016
3017	// NullFields is a list of field names (e.g. "Description") to include
3018	// in API requests with the JSON null value. By default, fields with
3019	// empty values are omitted from API requests. However, any field with
3020	// an empty value appearing in NullFields will be sent to the server as
3021	// null. It is an error if a field in this list has a non-empty value.
3022	// This may be used to include null fields in Patch requests.
3023	NullFields []string `json:"-"`
3024}
3025
3026func (s *GoogleCloudDialogflowCxV3TestRunDifference) MarshalJSON() ([]byte, error) {
3027	type NoMethod GoogleCloudDialogflowCxV3TestRunDifference
3028	raw := NoMethod(*s)
3029	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3030}
3031
3032// GoogleCloudDialogflowCxV3TextInput: Represents the natural language
3033// text to be processed.
3034type GoogleCloudDialogflowCxV3TextInput struct {
3035	// Text: Required. The UTF-8 encoded natural language text to be
3036	// processed. Text length must not exceed 256 characters.
3037	Text string `json:"text,omitempty"`
3038
3039	// ForceSendFields is a list of field names (e.g. "Text") to
3040	// unconditionally include in API requests. By default, fields with
3041	// empty values are omitted from API requests. However, any non-pointer,
3042	// non-interface field appearing in ForceSendFields will be sent to the
3043	// server regardless of whether the field is empty or not. This may be
3044	// used to include empty fields in Patch requests.
3045	ForceSendFields []string `json:"-"`
3046
3047	// NullFields is a list of field names (e.g. "Text") to include in API
3048	// requests with the JSON null value. By default, fields with empty
3049	// values are omitted from API requests. However, any field with an
3050	// empty value appearing in NullFields will be sent to the server as
3051	// null. It is an error if a field in this list has a non-empty value.
3052	// This may be used to include null fields in Patch requests.
3053	NullFields []string `json:"-"`
3054}
3055
3056func (s *GoogleCloudDialogflowCxV3TextInput) MarshalJSON() ([]byte, error) {
3057	type NoMethod GoogleCloudDialogflowCxV3TextInput
3058	raw := NoMethod(*s)
3059	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3060}
3061
3062// GoogleCloudDialogflowCxV3TransitionRoute: A transition route
3063// specifies a intent that can be matched and/or a data condition that
3064// can be evaluated during a session. When a specified transition is
3065// matched, the following actions are taken in order: * If there is a
3066// `trigger_fulfillment` associated with the transition, it will be
3067// called. * If there is a `target_page` associated with the transition,
3068// the session will transition into the specified page. * If there is a
3069// `target_flow` associated with the transition, the session will
3070// transition into the specified flow.
3071type GoogleCloudDialogflowCxV3TransitionRoute struct {
3072	// Condition: The condition to evaluate against form parameters or
3073	// session parameters. See the conditions reference
3074	// (https://cloud.google.com/dialogflow/cx/docs/reference/condition). At
3075	// least one of `intent` or `condition` must be specified. When both
3076	// `intent` and `condition` are specified, the transition can only
3077	// happen when both are fulfilled.
3078	Condition string `json:"condition,omitempty"`
3079
3080	// Intent: The unique identifier of an Intent. Format:
3081	// `projects//locations//agents//intents/`. Indicates that the
3082	// transition can only happen when the given intent is matched. At least
3083	// one of `intent` or `condition` must be specified. When both `intent`
3084	// and `condition` are specified, the transition can only happen when
3085	// both are fulfilled.
3086	Intent string `json:"intent,omitempty"`
3087
3088	// Name: Output only. The unique identifier of this transition route.
3089	Name string `json:"name,omitempty"`
3090
3091	// TargetFlow: The target flow to transition to. Format:
3092	// `projects//locations//agents//flows/`.
3093	TargetFlow string `json:"targetFlow,omitempty"`
3094
3095	// TargetPage: The target page to transition to. Format:
3096	// `projects//locations//agents//flows//pages/`.
3097	TargetPage string `json:"targetPage,omitempty"`
3098
3099	// TriggerFulfillment: The fulfillment to call when the condition is
3100	// satisfied. At least one of `trigger_fulfillment` and `target` must be
3101	// specified. When both are defined, `trigger_fulfillment` is executed
3102	// first.
3103	TriggerFulfillment *GoogleCloudDialogflowCxV3Fulfillment `json:"triggerFulfillment,omitempty"`
3104
3105	// ForceSendFields is a list of field names (e.g. "Condition") to
3106	// unconditionally include in API requests. By default, fields with
3107	// empty values are omitted from API requests. However, any non-pointer,
3108	// non-interface field appearing in ForceSendFields will be sent to the
3109	// server regardless of whether the field is empty or not. This may be
3110	// used to include empty fields in Patch requests.
3111	ForceSendFields []string `json:"-"`
3112
3113	// NullFields is a list of field names (e.g. "Condition") to include in
3114	// API requests with the JSON null value. By default, fields with empty
3115	// values are omitted from API requests. However, any field with an
3116	// empty value appearing in NullFields will be sent to the server as
3117	// null. It is an error if a field in this list has a non-empty value.
3118	// This may be used to include null fields in Patch requests.
3119	NullFields []string `json:"-"`
3120}
3121
3122func (s *GoogleCloudDialogflowCxV3TransitionRoute) MarshalJSON() ([]byte, error) {
3123	type NoMethod GoogleCloudDialogflowCxV3TransitionRoute
3124	raw := NoMethod(*s)
3125	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3126}
3127
3128// GoogleCloudDialogflowCxV3UpdateDocumentOperationMetadata: Metadata
3129// for UpdateDocument operation.
3130type GoogleCloudDialogflowCxV3UpdateDocumentOperationMetadata struct {
3131	// GenericMetadata: The generic information of the operation.
3132	GenericMetadata *GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
3133
3134	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
3135	// unconditionally include in API requests. By default, fields with
3136	// empty values are omitted from API requests. However, any non-pointer,
3137	// non-interface field appearing in ForceSendFields will be sent to the
3138	// server regardless of whether the field is empty or not. This may be
3139	// used to include empty fields in Patch requests.
3140	ForceSendFields []string `json:"-"`
3141
3142	// NullFields is a list of field names (e.g. "GenericMetadata") to
3143	// include in API requests with the JSON null value. By default, fields
3144	// with empty values are omitted from API requests. However, any field
3145	// with an empty value appearing in NullFields will be sent to the
3146	// server as null. It is an error if a field in this list has a
3147	// non-empty value. This may be used to include null fields in Patch
3148	// requests.
3149	NullFields []string `json:"-"`
3150}
3151
3152func (s *GoogleCloudDialogflowCxV3UpdateDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
3153	type NoMethod GoogleCloudDialogflowCxV3UpdateDocumentOperationMetadata
3154	raw := NoMethod(*s)
3155	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3156}
3157
3158// GoogleCloudDialogflowCxV3WebhookRequest: The request message for a
3159// webhook call. The request is sent as a JSON object and the field
3160// names will be presented in camel cases.
3161type GoogleCloudDialogflowCxV3WebhookRequest struct {
3162	// DetectIntentResponseId: Always present. The unique identifier of the
3163	// DetectIntentResponse that will be returned to the API caller.
3164	DetectIntentResponseId string `json:"detectIntentResponseId,omitempty"`
3165
3166	// FulfillmentInfo: Always present. Information about the fulfillment
3167	// that triggered this webhook call.
3168	FulfillmentInfo *GoogleCloudDialogflowCxV3WebhookRequestFulfillmentInfo `json:"fulfillmentInfo,omitempty"`
3169
3170	// IntentInfo: Information about the last matched intent.
3171	IntentInfo *GoogleCloudDialogflowCxV3WebhookRequestIntentInfo `json:"intentInfo,omitempty"`
3172
3173	// Messages: The list of rich message responses to present to the user.
3174	// Webhook can choose to append or replace this list in
3175	// WebhookResponse.fulfillment_response;
3176	Messages []*GoogleCloudDialogflowCxV3ResponseMessage `json:"messages,omitempty"`
3177
3178	// PageInfo: Information about page status.
3179	PageInfo *GoogleCloudDialogflowCxV3PageInfo `json:"pageInfo,omitempty"`
3180
3181	// Payload: Custom data set in QueryParameters.payload.
3182	Payload googleapi.RawMessage `json:"payload,omitempty"`
3183
3184	// SentimentAnalysisResult: The sentiment analysis result of the current
3185	// user request. The field is filled when sentiment analysis is
3186	// configured to be enabled for the request.
3187	SentimentAnalysisResult *GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult `json:"sentimentAnalysisResult,omitempty"`
3188
3189	// SessionInfo: Information about session status.
3190	SessionInfo *GoogleCloudDialogflowCxV3SessionInfo `json:"sessionInfo,omitempty"`
3191
3192	// Text: If natural language text was provided as input, this field will
3193	// contain a copy of the text.
3194	Text string `json:"text,omitempty"`
3195
3196	// Transcript: If natural language speech audio was provided as input,
3197	// this field will contain the transcript for the audio.
3198	Transcript string `json:"transcript,omitempty"`
3199
3200	// TriggerEvent: If an event was provided as input, this field will
3201	// contain the name of the event.
3202	TriggerEvent string `json:"triggerEvent,omitempty"`
3203
3204	// TriggerIntent: If an intent was provided as input, this field will
3205	// contain a copy of the intent identifier. Format:
3206	// `projects//locations//agents//intents/`.
3207	TriggerIntent string `json:"triggerIntent,omitempty"`
3208
3209	// ForceSendFields is a list of field names (e.g.
3210	// "DetectIntentResponseId") to unconditionally include in API requests.
3211	// By default, fields with empty values are omitted from API requests.
3212	// However, any non-pointer, non-interface field appearing in
3213	// ForceSendFields will be sent to the server regardless of whether the
3214	// field is empty or not. This may be used to include empty fields in
3215	// Patch requests.
3216	ForceSendFields []string `json:"-"`
3217
3218	// NullFields is a list of field names (e.g. "DetectIntentResponseId")
3219	// to include in API requests with the JSON null value. By default,
3220	// fields with empty values are omitted from API requests. However, any
3221	// field with an empty value appearing in NullFields will be sent to the
3222	// server as null. It is an error if a field in this list has a
3223	// non-empty value. This may be used to include null fields in Patch
3224	// requests.
3225	NullFields []string `json:"-"`
3226}
3227
3228func (s *GoogleCloudDialogflowCxV3WebhookRequest) MarshalJSON() ([]byte, error) {
3229	type NoMethod GoogleCloudDialogflowCxV3WebhookRequest
3230	raw := NoMethod(*s)
3231	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3232}
3233
3234// GoogleCloudDialogflowCxV3WebhookRequestFulfillmentInfo: Represents
3235// fulfillment information communicated to the webhook.
3236type GoogleCloudDialogflowCxV3WebhookRequestFulfillmentInfo struct {
3237	// Tag: Always present. The tag used to identify which fulfillment is
3238	// being called.
3239	Tag string `json:"tag,omitempty"`
3240
3241	// ForceSendFields is a list of field names (e.g. "Tag") to
3242	// unconditionally include in API requests. By default, fields with
3243	// empty values are omitted from API requests. However, any non-pointer,
3244	// non-interface field appearing in ForceSendFields will be sent to the
3245	// server regardless of whether the field is empty or not. This may be
3246	// used to include empty fields in Patch requests.
3247	ForceSendFields []string `json:"-"`
3248
3249	// NullFields is a list of field names (e.g. "Tag") to include in API
3250	// requests with the JSON null value. By default, fields with empty
3251	// values are omitted from API requests. However, any field with an
3252	// empty value appearing in NullFields will be sent to the server as
3253	// null. It is an error if a field in this list has a non-empty value.
3254	// This may be used to include null fields in Patch requests.
3255	NullFields []string `json:"-"`
3256}
3257
3258func (s *GoogleCloudDialogflowCxV3WebhookRequestFulfillmentInfo) MarshalJSON() ([]byte, error) {
3259	type NoMethod GoogleCloudDialogflowCxV3WebhookRequestFulfillmentInfo
3260	raw := NoMethod(*s)
3261	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3262}
3263
3264// GoogleCloudDialogflowCxV3WebhookRequestIntentInfo: Represents intent
3265// information communicated to the webhook.
3266type GoogleCloudDialogflowCxV3WebhookRequestIntentInfo struct {
3267	// Confidence: The confidence of the matched intent. Values range from
3268	// 0.0 (completely uncertain) to 1.0 (completely certain).
3269	Confidence float64 `json:"confidence,omitempty"`
3270
3271	// DisplayName: Always present. The display name of the last matched
3272	// intent.
3273	DisplayName string `json:"displayName,omitempty"`
3274
3275	// LastMatchedIntent: Always present. The unique identifier of the last
3276	// matched intent. Format: `projects//locations//agents//intents/`.
3277	LastMatchedIntent string `json:"lastMatchedIntent,omitempty"`
3278
3279	// Parameters: Parameters identified as a result of intent matching.
3280	// This is a map of the name of the identified parameter to the value of
3281	// the parameter identified from the user's utterance. All parameters
3282	// defined in the matched intent that are identified will be surfaced
3283	// here.
3284	Parameters map[string]GoogleCloudDialogflowCxV3WebhookRequestIntentInfoIntentParameterValue `json:"parameters,omitempty"`
3285
3286	// ForceSendFields is a list of field names (e.g. "Confidence") to
3287	// unconditionally include in API requests. By default, fields with
3288	// empty values are omitted from API requests. However, any non-pointer,
3289	// non-interface field appearing in ForceSendFields will be sent to the
3290	// server regardless of whether the field is empty or not. This may be
3291	// used to include empty fields in Patch requests.
3292	ForceSendFields []string `json:"-"`
3293
3294	// NullFields is a list of field names (e.g. "Confidence") to include in
3295	// API requests with the JSON null value. By default, fields with empty
3296	// values are omitted from API requests. However, any field with an
3297	// empty value appearing in NullFields will be sent to the server as
3298	// null. It is an error if a field in this list has a non-empty value.
3299	// This may be used to include null fields in Patch requests.
3300	NullFields []string `json:"-"`
3301}
3302
3303func (s *GoogleCloudDialogflowCxV3WebhookRequestIntentInfo) MarshalJSON() ([]byte, error) {
3304	type NoMethod GoogleCloudDialogflowCxV3WebhookRequestIntentInfo
3305	raw := NoMethod(*s)
3306	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3307}
3308
3309func (s *GoogleCloudDialogflowCxV3WebhookRequestIntentInfo) UnmarshalJSON(data []byte) error {
3310	type NoMethod GoogleCloudDialogflowCxV3WebhookRequestIntentInfo
3311	var s1 struct {
3312		Confidence gensupport.JSONFloat64 `json:"confidence"`
3313		*NoMethod
3314	}
3315	s1.NoMethod = (*NoMethod)(s)
3316	if err := json.Unmarshal(data, &s1); err != nil {
3317		return err
3318	}
3319	s.Confidence = float64(s1.Confidence)
3320	return nil
3321}
3322
3323// GoogleCloudDialogflowCxV3WebhookRequestIntentInfoIntentParameterValue:
3324//  Represents a value for an intent parameter.
3325type GoogleCloudDialogflowCxV3WebhookRequestIntentInfoIntentParameterValue struct {
3326	// OriginalValue: Always present. Original text value extracted from
3327	// user utterance.
3328	OriginalValue string `json:"originalValue,omitempty"`
3329
3330	// ResolvedValue: Always present. Structured value for the parameter
3331	// extracted from user utterance.
3332	ResolvedValue interface{} `json:"resolvedValue,omitempty"`
3333
3334	// ForceSendFields is a list of field names (e.g. "OriginalValue") to
3335	// unconditionally include in API requests. By default, fields with
3336	// empty values are omitted from API requests. However, any non-pointer,
3337	// non-interface field appearing in ForceSendFields will be sent to the
3338	// server regardless of whether the field is empty or not. This may be
3339	// used to include empty fields in Patch requests.
3340	ForceSendFields []string `json:"-"`
3341
3342	// NullFields is a list of field names (e.g. "OriginalValue") to include
3343	// in API requests with the JSON null value. By default, fields with
3344	// empty values are omitted from API requests. However, any field with
3345	// an empty value appearing in NullFields will be sent to the server as
3346	// null. It is an error if a field in this list has a non-empty value.
3347	// This may be used to include null fields in Patch requests.
3348	NullFields []string `json:"-"`
3349}
3350
3351func (s *GoogleCloudDialogflowCxV3WebhookRequestIntentInfoIntentParameterValue) MarshalJSON() ([]byte, error) {
3352	type NoMethod GoogleCloudDialogflowCxV3WebhookRequestIntentInfoIntentParameterValue
3353	raw := NoMethod(*s)
3354	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3355}
3356
3357// GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult:
3358// Represents the result of sentiment analysis.
3359type GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult struct {
3360	// Magnitude: A non-negative number in the [0, +inf) range, which
3361	// represents the absolute magnitude of sentiment, regardless of score
3362	// (positive or negative).
3363	Magnitude float64 `json:"magnitude,omitempty"`
3364
3365	// Score: Sentiment score between -1.0 (negative sentiment) and 1.0
3366	// (positive sentiment).
3367	Score float64 `json:"score,omitempty"`
3368
3369	// ForceSendFields is a list of field names (e.g. "Magnitude") to
3370	// unconditionally include in API requests. By default, fields with
3371	// empty values are omitted from API requests. However, any non-pointer,
3372	// non-interface field appearing in ForceSendFields will be sent to the
3373	// server regardless of whether the field is empty or not. This may be
3374	// used to include empty fields in Patch requests.
3375	ForceSendFields []string `json:"-"`
3376
3377	// NullFields is a list of field names (e.g. "Magnitude") to include in
3378	// API requests with the JSON null value. By default, fields with empty
3379	// values are omitted from API requests. However, any field with an
3380	// empty value appearing in NullFields will be sent to the server as
3381	// null. It is an error if a field in this list has a non-empty value.
3382	// This may be used to include null fields in Patch requests.
3383	NullFields []string `json:"-"`
3384}
3385
3386func (s *GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult) MarshalJSON() ([]byte, error) {
3387	type NoMethod GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult
3388	raw := NoMethod(*s)
3389	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3390}
3391
3392func (s *GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult) UnmarshalJSON(data []byte) error {
3393	type NoMethod GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult
3394	var s1 struct {
3395		Magnitude gensupport.JSONFloat64 `json:"magnitude"`
3396		Score     gensupport.JSONFloat64 `json:"score"`
3397		*NoMethod
3398	}
3399	s1.NoMethod = (*NoMethod)(s)
3400	if err := json.Unmarshal(data, &s1); err != nil {
3401		return err
3402	}
3403	s.Magnitude = float64(s1.Magnitude)
3404	s.Score = float64(s1.Score)
3405	return nil
3406}
3407
3408// GoogleCloudDialogflowCxV3WebhookResponse: The response message for a
3409// webhook call.
3410type GoogleCloudDialogflowCxV3WebhookResponse struct {
3411	// FulfillmentResponse: The fulfillment response to send to the user.
3412	// This field can be omitted by the webhook if it does not intend to
3413	// send any response to the user.
3414	FulfillmentResponse *GoogleCloudDialogflowCxV3WebhookResponseFulfillmentResponse `json:"fulfillmentResponse,omitempty"`
3415
3416	// PageInfo: Information about page status. This field can be omitted by
3417	// the webhook if it does not intend to modify page status.
3418	PageInfo *GoogleCloudDialogflowCxV3PageInfo `json:"pageInfo,omitempty"`
3419
3420	// Payload: Value to append directly to QueryResult.webhook_payloads.
3421	Payload googleapi.RawMessage `json:"payload,omitempty"`
3422
3423	// SessionInfo: Information about session status. This field can be
3424	// omitted by the webhook if it does not intend to modify session
3425	// status.
3426	SessionInfo *GoogleCloudDialogflowCxV3SessionInfo `json:"sessionInfo,omitempty"`
3427
3428	// TargetFlow: The target flow to transition to. Format:
3429	// `projects//locations//agents//flows/`.
3430	TargetFlow string `json:"targetFlow,omitempty"`
3431
3432	// TargetPage: The target page to transition to. Format:
3433	// `projects//locations//agents//flows//pages/`.
3434	TargetPage string `json:"targetPage,omitempty"`
3435
3436	// ForceSendFields is a list of field names (e.g. "FulfillmentResponse")
3437	// to unconditionally include in API requests. By default, fields with
3438	// empty values are omitted from API requests. However, any non-pointer,
3439	// non-interface field appearing in ForceSendFields will be sent to the
3440	// server regardless of whether the field is empty or not. This may be
3441	// used to include empty fields in Patch requests.
3442	ForceSendFields []string `json:"-"`
3443
3444	// NullFields is a list of field names (e.g. "FulfillmentResponse") to
3445	// include in API requests with the JSON null value. By default, fields
3446	// with empty values are omitted from API requests. However, any field
3447	// with an empty value appearing in NullFields will be sent to the
3448	// server as null. It is an error if a field in this list has a
3449	// non-empty value. This may be used to include null fields in Patch
3450	// requests.
3451	NullFields []string `json:"-"`
3452}
3453
3454func (s *GoogleCloudDialogflowCxV3WebhookResponse) MarshalJSON() ([]byte, error) {
3455	type NoMethod GoogleCloudDialogflowCxV3WebhookResponse
3456	raw := NoMethod(*s)
3457	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3458}
3459
3460// GoogleCloudDialogflowCxV3WebhookResponseFulfillmentResponse:
3461// Represents a fulfillment response to the user.
3462type GoogleCloudDialogflowCxV3WebhookResponseFulfillmentResponse struct {
3463	// MergeBehavior: Merge behavior for `messages`.
3464	//
3465	// Possible values:
3466	//   "MERGE_BEHAVIOR_UNSPECIFIED" - Not specified. `APPEND` will be
3467	// used.
3468	//   "APPEND" - `messages` will be appended to the list of messages
3469	// waiting to be sent to the user.
3470	//   "REPLACE" - `messages` will replace the list of messages waiting to
3471	// be sent to the user.
3472	MergeBehavior string `json:"mergeBehavior,omitempty"`
3473
3474	// Messages: The list of rich message responses to present to the user.
3475	Messages []*GoogleCloudDialogflowCxV3ResponseMessage `json:"messages,omitempty"`
3476
3477	// ForceSendFields is a list of field names (e.g. "MergeBehavior") to
3478	// unconditionally include in API requests. By default, fields with
3479	// empty values are omitted from API requests. However, any non-pointer,
3480	// non-interface field appearing in ForceSendFields will be sent to the
3481	// server regardless of whether the field is empty or not. This may be
3482	// used to include empty fields in Patch requests.
3483	ForceSendFields []string `json:"-"`
3484
3485	// NullFields is a list of field names (e.g. "MergeBehavior") to include
3486	// in API requests with the JSON null value. By default, fields with
3487	// empty values are omitted from API requests. However, any field with
3488	// an empty value appearing in NullFields will be sent to the server as
3489	// null. It is an error if a field in this list has a non-empty value.
3490	// This may be used to include null fields in Patch requests.
3491	NullFields []string `json:"-"`
3492}
3493
3494func (s *GoogleCloudDialogflowCxV3WebhookResponseFulfillmentResponse) MarshalJSON() ([]byte, error) {
3495	type NoMethod GoogleCloudDialogflowCxV3WebhookResponseFulfillmentResponse
3496	raw := NoMethod(*s)
3497	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3498}
3499
3500// GoogleCloudDialogflowCxV3beta1AudioInput: Represents the natural
3501// speech audio to be processed.
3502type GoogleCloudDialogflowCxV3beta1AudioInput struct {
3503	// Audio: The natural language speech audio to be processed. A single
3504	// request can contain up to 1 minute of speech audio data. The
3505	// transcribed text cannot contain more than 256 bytes. For
3506	// non-streaming audio detect intent, both `config` and `audio` must be
3507	// provided. For streaming audio detect intent, `config` must be
3508	// provided in the first request and `audio` must be provided in all
3509	// following requests.
3510	Audio string `json:"audio,omitempty"`
3511
3512	// Config: Required. Instructs the speech recognizer how to process the
3513	// speech audio.
3514	Config *GoogleCloudDialogflowCxV3beta1InputAudioConfig `json:"config,omitempty"`
3515
3516	// ForceSendFields is a list of field names (e.g. "Audio") to
3517	// unconditionally include in API requests. By default, fields with
3518	// empty values are omitted from API requests. However, any non-pointer,
3519	// non-interface field appearing in ForceSendFields will be sent to the
3520	// server regardless of whether the field is empty or not. This may be
3521	// used to include empty fields in Patch requests.
3522	ForceSendFields []string `json:"-"`
3523
3524	// NullFields is a list of field names (e.g. "Audio") to include in API
3525	// requests with the JSON null value. By default, fields with empty
3526	// values are omitted from API requests. However, any field with an
3527	// empty value appearing in NullFields will be sent to the server as
3528	// null. It is an error if a field in this list has a non-empty value.
3529	// This may be used to include null fields in Patch requests.
3530	NullFields []string `json:"-"`
3531}
3532
3533func (s *GoogleCloudDialogflowCxV3beta1AudioInput) MarshalJSON() ([]byte, error) {
3534	type NoMethod GoogleCloudDialogflowCxV3beta1AudioInput
3535	raw := NoMethod(*s)
3536	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3537}
3538
3539// GoogleCloudDialogflowCxV3beta1BatchRunTestCasesMetadata: Metadata
3540// returned for the TestCases.BatchRunTestCases long running operation.
3541type GoogleCloudDialogflowCxV3beta1BatchRunTestCasesMetadata struct {
3542	// Errors: The test errors.
3543	Errors []*GoogleCloudDialogflowCxV3beta1TestError `json:"errors,omitempty"`
3544
3545	// ForceSendFields is a list of field names (e.g. "Errors") to
3546	// unconditionally include in API requests. By default, fields with
3547	// empty values are omitted from API requests. However, any non-pointer,
3548	// non-interface field appearing in ForceSendFields will be sent to the
3549	// server regardless of whether the field is empty or not. This may be
3550	// used to include empty fields in Patch requests.
3551	ForceSendFields []string `json:"-"`
3552
3553	// NullFields is a list of field names (e.g. "Errors") to include in API
3554	// requests with the JSON null value. By default, fields with empty
3555	// values are omitted from API requests. However, any field with an
3556	// empty value appearing in NullFields will be sent to the server as
3557	// null. It is an error if a field in this list has a non-empty value.
3558	// This may be used to include null fields in Patch requests.
3559	NullFields []string `json:"-"`
3560}
3561
3562func (s *GoogleCloudDialogflowCxV3beta1BatchRunTestCasesMetadata) MarshalJSON() ([]byte, error) {
3563	type NoMethod GoogleCloudDialogflowCxV3beta1BatchRunTestCasesMetadata
3564	raw := NoMethod(*s)
3565	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3566}
3567
3568// GoogleCloudDialogflowCxV3beta1BatchRunTestCasesResponse: The response
3569// message for TestCases.BatchRunTestCases.
3570type GoogleCloudDialogflowCxV3beta1BatchRunTestCasesResponse struct {
3571	// Results: The test case results. The detailed conversation turns are
3572	// empty in this response.
3573	Results []*GoogleCloudDialogflowCxV3beta1TestCaseResult `json:"results,omitempty"`
3574
3575	// ForceSendFields is a list of field names (e.g. "Results") to
3576	// unconditionally include in API requests. By default, fields with
3577	// empty values are omitted from API requests. However, any non-pointer,
3578	// non-interface field appearing in ForceSendFields will be sent to the
3579	// server regardless of whether the field is empty or not. This may be
3580	// used to include empty fields in Patch requests.
3581	ForceSendFields []string `json:"-"`
3582
3583	// NullFields is a list of field names (e.g. "Results") to include in
3584	// API requests with the JSON null value. By default, fields with empty
3585	// values are omitted from API requests. However, any field with an
3586	// empty value appearing in NullFields will be sent to the server as
3587	// null. It is an error if a field in this list has a non-empty value.
3588	// This may be used to include null fields in Patch requests.
3589	NullFields []string `json:"-"`
3590}
3591
3592func (s *GoogleCloudDialogflowCxV3beta1BatchRunTestCasesResponse) MarshalJSON() ([]byte, error) {
3593	type NoMethod GoogleCloudDialogflowCxV3beta1BatchRunTestCasesResponse
3594	raw := NoMethod(*s)
3595	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3596}
3597
3598// GoogleCloudDialogflowCxV3beta1ConversationTurn: One interaction
3599// between a human and virtual agent. The human provides some input and
3600// the virtual agent provides a response.
3601type GoogleCloudDialogflowCxV3beta1ConversationTurn struct {
3602	// UserInput: The user input.
3603	UserInput *GoogleCloudDialogflowCxV3beta1ConversationTurnUserInput `json:"userInput,omitempty"`
3604
3605	// VirtualAgentOutput: The virtual agent output.
3606	VirtualAgentOutput *GoogleCloudDialogflowCxV3beta1ConversationTurnVirtualAgentOutput `json:"virtualAgentOutput,omitempty"`
3607
3608	// ForceSendFields is a list of field names (e.g. "UserInput") to
3609	// unconditionally include in API requests. By default, fields with
3610	// empty values are omitted from API requests. However, any non-pointer,
3611	// non-interface field appearing in ForceSendFields will be sent to the
3612	// server regardless of whether the field is empty or not. This may be
3613	// used to include empty fields in Patch requests.
3614	ForceSendFields []string `json:"-"`
3615
3616	// NullFields is a list of field names (e.g. "UserInput") to include in
3617	// API requests with the JSON null value. By default, fields with empty
3618	// values are omitted from API requests. However, any field with an
3619	// empty value appearing in NullFields will be sent to the server as
3620	// null. It is an error if a field in this list has a non-empty value.
3621	// This may be used to include null fields in Patch requests.
3622	NullFields []string `json:"-"`
3623}
3624
3625func (s *GoogleCloudDialogflowCxV3beta1ConversationTurn) MarshalJSON() ([]byte, error) {
3626	type NoMethod GoogleCloudDialogflowCxV3beta1ConversationTurn
3627	raw := NoMethod(*s)
3628	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3629}
3630
3631// GoogleCloudDialogflowCxV3beta1ConversationTurnUserInput: The input
3632// from the human user.
3633type GoogleCloudDialogflowCxV3beta1ConversationTurnUserInput struct {
3634	// InjectedParameters: Parameters that need to be injected into the
3635	// conversation during intent detection.
3636	InjectedParameters googleapi.RawMessage `json:"injectedParameters,omitempty"`
3637
3638	// Input: Supports text input, event input, dtmf input in the test case.
3639	Input *GoogleCloudDialogflowCxV3beta1QueryInput `json:"input,omitempty"`
3640
3641	// IsWebhookEnabled: If webhooks should be allowed to trigger in
3642	// response to the user utterance. Often if parameters are injected,
3643	// webhooks should not be enabled.
3644	IsWebhookEnabled bool `json:"isWebhookEnabled,omitempty"`
3645
3646	// ForceSendFields is a list of field names (e.g. "InjectedParameters")
3647	// to unconditionally include in API requests. By default, fields with
3648	// empty values are omitted from API requests. However, any non-pointer,
3649	// non-interface field appearing in ForceSendFields will be sent to the
3650	// server regardless of whether the field is empty or not. This may be
3651	// used to include empty fields in Patch requests.
3652	ForceSendFields []string `json:"-"`
3653
3654	// NullFields is a list of field names (e.g. "InjectedParameters") to
3655	// include in API requests with the JSON null value. By default, fields
3656	// with empty values are omitted from API requests. However, any field
3657	// with an empty value appearing in NullFields will be sent to the
3658	// server as null. It is an error if a field in this list has a
3659	// non-empty value. This may be used to include null fields in Patch
3660	// requests.
3661	NullFields []string `json:"-"`
3662}
3663
3664func (s *GoogleCloudDialogflowCxV3beta1ConversationTurnUserInput) MarshalJSON() ([]byte, error) {
3665	type NoMethod GoogleCloudDialogflowCxV3beta1ConversationTurnUserInput
3666	raw := NoMethod(*s)
3667	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3668}
3669
3670// GoogleCloudDialogflowCxV3beta1ConversationTurnVirtualAgentOutput: The
3671// output from the virtual agent.
3672type GoogleCloudDialogflowCxV3beta1ConversationTurnVirtualAgentOutput struct {
3673	// CurrentPage: The Page on which the utterance was spoken. Only name
3674	// and displayName will be set.
3675	CurrentPage *GoogleCloudDialogflowCxV3beta1Page `json:"currentPage,omitempty"`
3676
3677	// DiagnosticInfo: Required. Input only. The diagnostic info output for
3678	// the turn.
3679	DiagnosticInfo googleapi.RawMessage `json:"diagnosticInfo,omitempty"`
3680
3681	// Differences: Output only. If this is part of a result conversation
3682	// turn, the list of differences between the original run and the replay
3683	// for this output, if any.
3684	Differences []*GoogleCloudDialogflowCxV3beta1TestRunDifference `json:"differences,omitempty"`
3685
3686	// SessionParameters: The session parameters available to the bot at
3687	// this point.
3688	SessionParameters googleapi.RawMessage `json:"sessionParameters,omitempty"`
3689
3690	// Status: Response error from the agent in the test result. If set,
3691	// other output is empty.
3692	Status *GoogleRpcStatus `json:"status,omitempty"`
3693
3694	// TextResponses: The text responses from the agent for the turn.
3695	TextResponses []*GoogleCloudDialogflowCxV3beta1ResponseMessageText `json:"textResponses,omitempty"`
3696
3697	// TriggeredIntent: The Intent that triggered the response. Only name
3698	// and displayName will be set.
3699	TriggeredIntent *GoogleCloudDialogflowCxV3beta1Intent `json:"triggeredIntent,omitempty"`
3700
3701	// ForceSendFields is a list of field names (e.g. "CurrentPage") to
3702	// unconditionally include in API requests. By default, fields with
3703	// empty values are omitted from API requests. However, any non-pointer,
3704	// non-interface field appearing in ForceSendFields will be sent to the
3705	// server regardless of whether the field is empty or not. This may be
3706	// used to include empty fields in Patch requests.
3707	ForceSendFields []string `json:"-"`
3708
3709	// NullFields is a list of field names (e.g. "CurrentPage") to include
3710	// in API requests with the JSON null value. By default, fields with
3711	// empty values are omitted from API requests. However, any field with
3712	// an empty value appearing in NullFields will be sent to the server as
3713	// null. It is an error if a field in this list has a non-empty value.
3714	// This may be used to include null fields in Patch requests.
3715	NullFields []string `json:"-"`
3716}
3717
3718func (s *GoogleCloudDialogflowCxV3beta1ConversationTurnVirtualAgentOutput) MarshalJSON() ([]byte, error) {
3719	type NoMethod GoogleCloudDialogflowCxV3beta1ConversationTurnVirtualAgentOutput
3720	raw := NoMethod(*s)
3721	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3722}
3723
3724// GoogleCloudDialogflowCxV3beta1CreateDocumentOperationMetadata:
3725// Metadata for CreateDocument operation.
3726type GoogleCloudDialogflowCxV3beta1CreateDocumentOperationMetadata struct {
3727	// GenericMetadata: The generic information of the operation.
3728	GenericMetadata *GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
3729
3730	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
3731	// unconditionally include in API requests. By default, fields with
3732	// empty values are omitted from API requests. However, any non-pointer,
3733	// non-interface field appearing in ForceSendFields will be sent to the
3734	// server regardless of whether the field is empty or not. This may be
3735	// used to include empty fields in Patch requests.
3736	ForceSendFields []string `json:"-"`
3737
3738	// NullFields is a list of field names (e.g. "GenericMetadata") to
3739	// include in API requests with the JSON null value. By default, fields
3740	// with empty values are omitted from API requests. However, any field
3741	// with an empty value appearing in NullFields will be sent to the
3742	// server as null. It is an error if a field in this list has a
3743	// non-empty value. This may be used to include null fields in Patch
3744	// requests.
3745	NullFields []string `json:"-"`
3746}
3747
3748func (s *GoogleCloudDialogflowCxV3beta1CreateDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
3749	type NoMethod GoogleCloudDialogflowCxV3beta1CreateDocumentOperationMetadata
3750	raw := NoMethod(*s)
3751	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3752}
3753
3754// GoogleCloudDialogflowCxV3beta1CreateVersionOperationMetadata:
3755// Metadata associated with the long running operation for
3756// Versions.CreateVersion.
3757type GoogleCloudDialogflowCxV3beta1CreateVersionOperationMetadata struct {
3758	// Version: Name of the created version. Format:
3759	// `projects//locations//agents//flows//versions/`.
3760	Version string `json:"version,omitempty"`
3761
3762	// ForceSendFields is a list of field names (e.g. "Version") to
3763	// unconditionally include in API requests. By default, fields with
3764	// empty values are omitted from API requests. However, any non-pointer,
3765	// non-interface field appearing in ForceSendFields will be sent to the
3766	// server regardless of whether the field is empty or not. This may be
3767	// used to include empty fields in Patch requests.
3768	ForceSendFields []string `json:"-"`
3769
3770	// NullFields is a list of field names (e.g. "Version") to include in
3771	// API requests with the JSON null value. By default, fields with empty
3772	// values are omitted from API requests. However, any field with an
3773	// empty value appearing in NullFields will be sent to the server as
3774	// null. It is an error if a field in this list has a non-empty value.
3775	// This may be used to include null fields in Patch requests.
3776	NullFields []string `json:"-"`
3777}
3778
3779func (s *GoogleCloudDialogflowCxV3beta1CreateVersionOperationMetadata) MarshalJSON() ([]byte, error) {
3780	type NoMethod GoogleCloudDialogflowCxV3beta1CreateVersionOperationMetadata
3781	raw := NoMethod(*s)
3782	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3783}
3784
3785// GoogleCloudDialogflowCxV3beta1DeleteDocumentOperationMetadata:
3786// Metadata for DeleteDocument operation.
3787type GoogleCloudDialogflowCxV3beta1DeleteDocumentOperationMetadata struct {
3788	// GenericMetadata: The generic information of the operation.
3789	GenericMetadata *GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
3790
3791	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
3792	// unconditionally include in API requests. By default, fields with
3793	// empty values are omitted from API requests. However, any non-pointer,
3794	// non-interface field appearing in ForceSendFields will be sent to the
3795	// server regardless of whether the field is empty or not. This may be
3796	// used to include empty fields in Patch requests.
3797	ForceSendFields []string `json:"-"`
3798
3799	// NullFields is a list of field names (e.g. "GenericMetadata") to
3800	// include in API requests with the JSON null value. By default, fields
3801	// with empty values are omitted from API requests. However, any field
3802	// with an empty value appearing in NullFields will be sent to the
3803	// server as null. It is an error if a field in this list has a
3804	// non-empty value. This may be used to include null fields in Patch
3805	// requests.
3806	NullFields []string `json:"-"`
3807}
3808
3809func (s *GoogleCloudDialogflowCxV3beta1DeleteDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
3810	type NoMethod GoogleCloudDialogflowCxV3beta1DeleteDocumentOperationMetadata
3811	raw := NoMethod(*s)
3812	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3813}
3814
3815// GoogleCloudDialogflowCxV3beta1DtmfInput: Represents the input for
3816// dtmf event.
3817type GoogleCloudDialogflowCxV3beta1DtmfInput struct {
3818	// Digits: The dtmf digits.
3819	Digits string `json:"digits,omitempty"`
3820
3821	// FinishDigit: The finish digit (if any).
3822	FinishDigit string `json:"finishDigit,omitempty"`
3823
3824	// ForceSendFields is a list of field names (e.g. "Digits") to
3825	// unconditionally include in API requests. By default, fields with
3826	// empty values are omitted from API requests. However, any non-pointer,
3827	// non-interface field appearing in ForceSendFields will be sent to the
3828	// server regardless of whether the field is empty or not. This may be
3829	// used to include empty fields in Patch requests.
3830	ForceSendFields []string `json:"-"`
3831
3832	// NullFields is a list of field names (e.g. "Digits") to include in API
3833	// requests with the JSON null value. By default, fields with empty
3834	// values are omitted from API requests. However, any field with an
3835	// empty value appearing in NullFields will be sent to the server as
3836	// null. It is an error if a field in this list has a non-empty value.
3837	// This may be used to include null fields in Patch requests.
3838	NullFields []string `json:"-"`
3839}
3840
3841func (s *GoogleCloudDialogflowCxV3beta1DtmfInput) MarshalJSON() ([]byte, error) {
3842	type NoMethod GoogleCloudDialogflowCxV3beta1DtmfInput
3843	raw := NoMethod(*s)
3844	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3845}
3846
3847// GoogleCloudDialogflowCxV3beta1EventHandler: An event handler
3848// specifies an event that can be handled during a session. When the
3849// specified event happens, the following actions are taken in order: *
3850// If there is a `trigger_fulfillment` associated with the event, it
3851// will be called. * If there is a `target_page` associated with the
3852// event, the session will transition into the specified page. * If
3853// there is a `target_flow` associated with the event, the session will
3854// transition into the specified flow.
3855type GoogleCloudDialogflowCxV3beta1EventHandler struct {
3856	// Event: Required. The name of the event to handle.
3857	Event string `json:"event,omitempty"`
3858
3859	// Name: Output only. The unique identifier of this event handler.
3860	Name string `json:"name,omitempty"`
3861
3862	// TargetFlow: The target flow to transition to. Format:
3863	// `projects//locations//agents//flows/`.
3864	TargetFlow string `json:"targetFlow,omitempty"`
3865
3866	// TargetPage: The target page to transition to. Format:
3867	// `projects//locations//agents//flows//pages/`.
3868	TargetPage string `json:"targetPage,omitempty"`
3869
3870	// TriggerFulfillment: The fulfillment to call when the event occurs.
3871	// Handling webhook errors with a fulfillment enabled with webhook could
3872	// cause infinite loop. It is invalid to specify such fulfillment for a
3873	// handler handling webhooks.
3874	TriggerFulfillment *GoogleCloudDialogflowCxV3beta1Fulfillment `json:"triggerFulfillment,omitempty"`
3875
3876	// ForceSendFields is a list of field names (e.g. "Event") to
3877	// unconditionally include in API requests. By default, fields with
3878	// empty values are omitted from API requests. However, any non-pointer,
3879	// non-interface field appearing in ForceSendFields will be sent to the
3880	// server regardless of whether the field is empty or not. This may be
3881	// used to include empty fields in Patch requests.
3882	ForceSendFields []string `json:"-"`
3883
3884	// NullFields is a list of field names (e.g. "Event") to include in API
3885	// requests with the JSON null value. By default, fields with empty
3886	// values are omitted from API requests. However, any field with an
3887	// empty value appearing in NullFields will be sent to the server as
3888	// null. It is an error if a field in this list has a non-empty value.
3889	// This may be used to include null fields in Patch requests.
3890	NullFields []string `json:"-"`
3891}
3892
3893func (s *GoogleCloudDialogflowCxV3beta1EventHandler) MarshalJSON() ([]byte, error) {
3894	type NoMethod GoogleCloudDialogflowCxV3beta1EventHandler
3895	raw := NoMethod(*s)
3896	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3897}
3898
3899// GoogleCloudDialogflowCxV3beta1EventInput: Represents the event to
3900// trigger.
3901type GoogleCloudDialogflowCxV3beta1EventInput struct {
3902	// Event: Name of the event.
3903	Event string `json:"event,omitempty"`
3904
3905	// ForceSendFields is a list of field names (e.g. "Event") to
3906	// unconditionally include in API requests. By default, fields with
3907	// empty values are omitted from API requests. However, any non-pointer,
3908	// non-interface field appearing in ForceSendFields will be sent to the
3909	// server regardless of whether the field is empty or not. This may be
3910	// used to include empty fields in Patch requests.
3911	ForceSendFields []string `json:"-"`
3912
3913	// NullFields is a list of field names (e.g. "Event") to include in API
3914	// requests with the JSON null value. By default, fields with empty
3915	// values are omitted from API requests. However, any field with an
3916	// empty value appearing in NullFields will be sent to the server as
3917	// null. It is an error if a field in this list has a non-empty value.
3918	// This may be used to include null fields in Patch requests.
3919	NullFields []string `json:"-"`
3920}
3921
3922func (s *GoogleCloudDialogflowCxV3beta1EventInput) MarshalJSON() ([]byte, error) {
3923	type NoMethod GoogleCloudDialogflowCxV3beta1EventInput
3924	raw := NoMethod(*s)
3925	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3926}
3927
3928// GoogleCloudDialogflowCxV3beta1ExportAgentResponse: The response
3929// message for Agents.ExportAgent.
3930type GoogleCloudDialogflowCxV3beta1ExportAgentResponse struct {
3931	// AgentContent: Uncompressed raw byte content for agent.
3932	AgentContent string `json:"agentContent,omitempty"`
3933
3934	// AgentUri: The URI to a file containing the exported agent. This field
3935	// is populated only if `agent_uri` is specified in ExportAgentRequest.
3936	AgentUri string `json:"agentUri,omitempty"`
3937
3938	// ForceSendFields is a list of field names (e.g. "AgentContent") to
3939	// unconditionally include in API requests. By default, fields with
3940	// empty values are omitted from API requests. However, any non-pointer,
3941	// non-interface field appearing in ForceSendFields will be sent to the
3942	// server regardless of whether the field is empty or not. This may be
3943	// used to include empty fields in Patch requests.
3944	ForceSendFields []string `json:"-"`
3945
3946	// NullFields is a list of field names (e.g. "AgentContent") to include
3947	// in API requests with the JSON null value. By default, fields with
3948	// empty values are omitted from API requests. However, any field with
3949	// an empty value appearing in NullFields will be sent to the server as
3950	// null. It is an error if a field in this list has a non-empty value.
3951	// This may be used to include null fields in Patch requests.
3952	NullFields []string `json:"-"`
3953}
3954
3955func (s *GoogleCloudDialogflowCxV3beta1ExportAgentResponse) MarshalJSON() ([]byte, error) {
3956	type NoMethod GoogleCloudDialogflowCxV3beta1ExportAgentResponse
3957	raw := NoMethod(*s)
3958	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3959}
3960
3961// GoogleCloudDialogflowCxV3beta1ExportTestCasesMetadata: Metadata
3962// returned for the TestCases.ExportTestCases long running operation.
3963type GoogleCloudDialogflowCxV3beta1ExportTestCasesMetadata struct {
3964}
3965
3966// GoogleCloudDialogflowCxV3beta1ExportTestCasesResponse: The response
3967// message for TestCases.ExportTestCases.
3968type GoogleCloudDialogflowCxV3beta1ExportTestCasesResponse struct {
3969	// Content: Uncompressed raw byte content for test cases.
3970	Content string `json:"content,omitempty"`
3971
3972	// GcsUri: The URI to a file containing the exported test cases. This
3973	// field is populated only if `gcs_uri` is specified in
3974	// ExportTestCasesRequest.
3975	GcsUri string `json:"gcsUri,omitempty"`
3976
3977	// ForceSendFields is a list of field names (e.g. "Content") to
3978	// unconditionally include in API requests. By default, fields with
3979	// empty values are omitted from API requests. However, any non-pointer,
3980	// non-interface field appearing in ForceSendFields will be sent to the
3981	// server regardless of whether the field is empty or not. This may be
3982	// used to include empty fields in Patch requests.
3983	ForceSendFields []string `json:"-"`
3984
3985	// NullFields is a list of field names (e.g. "Content") to include in
3986	// API requests with the JSON null value. By default, fields with empty
3987	// values are omitted from API requests. However, any field with an
3988	// empty value appearing in NullFields will be sent to the server as
3989	// null. It is an error if a field in this list has a non-empty value.
3990	// This may be used to include null fields in Patch requests.
3991	NullFields []string `json:"-"`
3992}
3993
3994func (s *GoogleCloudDialogflowCxV3beta1ExportTestCasesResponse) MarshalJSON() ([]byte, error) {
3995	type NoMethod GoogleCloudDialogflowCxV3beta1ExportTestCasesResponse
3996	raw := NoMethod(*s)
3997	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3998}
3999
4000// GoogleCloudDialogflowCxV3beta1Form: A form is a data model that
4001// groups related parameters that can be collected from the user. The
4002// process in which the agent prompts the user and collects parameter
4003// values from the user is called form filling. A form can be added to a
4004// page. When form filling is done, the filled parameters will be
4005// written to the session.
4006type GoogleCloudDialogflowCxV3beta1Form struct {
4007	// Parameters: Parameters to collect from the user.
4008	Parameters []*GoogleCloudDialogflowCxV3beta1FormParameter `json:"parameters,omitempty"`
4009
4010	// ForceSendFields is a list of field names (e.g. "Parameters") to
4011	// unconditionally include in API requests. By default, fields with
4012	// empty values are omitted from API requests. However, any non-pointer,
4013	// non-interface field appearing in ForceSendFields will be sent to the
4014	// server regardless of whether the field is empty or not. This may be
4015	// used to include empty fields in Patch requests.
4016	ForceSendFields []string `json:"-"`
4017
4018	// NullFields is a list of field names (e.g. "Parameters") to include in
4019	// API requests with the JSON null value. By default, fields with empty
4020	// values are omitted from API requests. However, any field with an
4021	// empty value appearing in NullFields will be sent to the server as
4022	// null. It is an error if a field in this list has a non-empty value.
4023	// This may be used to include null fields in Patch requests.
4024	NullFields []string `json:"-"`
4025}
4026
4027func (s *GoogleCloudDialogflowCxV3beta1Form) MarshalJSON() ([]byte, error) {
4028	type NoMethod GoogleCloudDialogflowCxV3beta1Form
4029	raw := NoMethod(*s)
4030	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4031}
4032
4033// GoogleCloudDialogflowCxV3beta1FormParameter: Represents a form
4034// parameter.
4035type GoogleCloudDialogflowCxV3beta1FormParameter struct {
4036	// DefaultValue: The default value of an optional parameter. If the
4037	// parameter is required, the default value will be ignored.
4038	DefaultValue interface{} `json:"defaultValue,omitempty"`
4039
4040	// DisplayName: Required. The human-readable name of the parameter,
4041	// unique within the form.
4042	DisplayName string `json:"displayName,omitempty"`
4043
4044	// EntityType: Required. The entity type of the parameter. Format:
4045	// `projects/-/locations/-/agents/-/entityTypes/` for system entity
4046	// types (for example,
4047	// `projects/-/locations/-/agents/-/entityTypes/sys.date`), or
4048	// `projects//locations//agents//entityTypes/` for developer entity
4049	// types.
4050	EntityType string `json:"entityType,omitempty"`
4051
4052	// FillBehavior: Required. Defines fill behavior for the parameter.
4053	FillBehavior *GoogleCloudDialogflowCxV3beta1FormParameterFillBehavior `json:"fillBehavior,omitempty"`
4054
4055	// IsList: Indicates whether the parameter represents a list of values.
4056	IsList bool `json:"isList,omitempty"`
4057
4058	// Redact: Indicates whether the parameter content should be redacted in
4059	// log. If redaction is enabled, the parameter content will be replaced
4060	// by parameter name during logging. Note: the parameter content is
4061	// subject to redaction if either parameter level redaction or entity
4062	// type level redaction is enabled.
4063	Redact bool `json:"redact,omitempty"`
4064
4065	// Required: Indicates whether the parameter is required. Optional
4066	// parameters will not trigger prompts; however, they are filled if the
4067	// user specifies them. Required parameters must be filled before form
4068	// filling concludes.
4069	Required bool `json:"required,omitempty"`
4070
4071	// ForceSendFields is a list of field names (e.g. "DefaultValue") to
4072	// unconditionally include in API requests. By default, fields with
4073	// empty values are omitted from API requests. However, any non-pointer,
4074	// non-interface field appearing in ForceSendFields will be sent to the
4075	// server regardless of whether the field is empty or not. This may be
4076	// used to include empty fields in Patch requests.
4077	ForceSendFields []string `json:"-"`
4078
4079	// NullFields is a list of field names (e.g. "DefaultValue") to include
4080	// in API requests with the JSON null value. By default, fields with
4081	// empty values are omitted from API requests. However, any field with
4082	// an empty value appearing in NullFields will be sent to the server as
4083	// null. It is an error if a field in this list has a non-empty value.
4084	// This may be used to include null fields in Patch requests.
4085	NullFields []string `json:"-"`
4086}
4087
4088func (s *GoogleCloudDialogflowCxV3beta1FormParameter) MarshalJSON() ([]byte, error) {
4089	type NoMethod GoogleCloudDialogflowCxV3beta1FormParameter
4090	raw := NoMethod(*s)
4091	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4092}
4093
4094// GoogleCloudDialogflowCxV3beta1FormParameterFillBehavior:
4095// Configuration for how the filling of a parameter should be handled.
4096type GoogleCloudDialogflowCxV3beta1FormParameterFillBehavior struct {
4097	// InitialPromptFulfillment: Required. The fulfillment to provide the
4098	// initial prompt that the agent can present to the user in order to
4099	// fill the parameter.
4100	InitialPromptFulfillment *GoogleCloudDialogflowCxV3beta1Fulfillment `json:"initialPromptFulfillment,omitempty"`
4101
4102	// RepromptEventHandlers: The handlers for parameter-level events, used
4103	// to provide reprompt for the parameter or transition to a different
4104	// page/flow. The supported events are: * `sys.no-match-`, where N can
4105	// be from 1 to 6 * `sys.no-match-default` * `sys.no-input-`, where N
4106	// can be from 1 to 6 * `sys.no-input-default` * `sys.invalid-parameter`
4107	// `initial_prompt_fulfillment` provides the first prompt for the
4108	// parameter. If the user's response does not fill the parameter, a
4109	// no-match/no-input event will be triggered, and the fulfillment
4110	// associated with the `sys.no-match-1`/`sys.no-input-1` handler (if
4111	// defined) will be called to provide a prompt. The
4112	// `sys.no-match-2`/`sys.no-input-2` handler (if defined) will respond
4113	// to the next no-match/no-input event, and so on. A
4114	// `sys.no-match-default` or `sys.no-input-default` handler will be used
4115	// to handle all following no-match/no-input events after all numbered
4116	// no-match/no-input handlers for the parameter are consumed. A
4117	// `sys.invalid-parameter` handler can be defined to handle the case
4118	// where the parameter values have been `invalidated` by webhook. For
4119	// example, if the user's response fill the parameter, however the
4120	// parameter was invalidated by webhook, the fulfillment associated with
4121	// the `sys.invalid-parameter` handler (if defined) will be called to
4122	// provide a prompt. If the event handler for the corresponding event
4123	// can't be found on the parameter, `initial_prompt_fulfillment` will be
4124	// re-prompted.
4125	RepromptEventHandlers []*GoogleCloudDialogflowCxV3beta1EventHandler `json:"repromptEventHandlers,omitempty"`
4126
4127	// ForceSendFields is a list of field names (e.g.
4128	// "InitialPromptFulfillment") to unconditionally include in API
4129	// requests. By default, fields with empty values are omitted from API
4130	// requests. However, any non-pointer, non-interface field appearing in
4131	// ForceSendFields will be sent to the server regardless of whether the
4132	// field is empty or not. This may be used to include empty fields in
4133	// Patch requests.
4134	ForceSendFields []string `json:"-"`
4135
4136	// NullFields is a list of field names (e.g. "InitialPromptFulfillment")
4137	// to include in API requests with the JSON null value. By default,
4138	// fields with empty values are omitted from API requests. However, any
4139	// field with an empty value appearing in NullFields will be sent to the
4140	// server as null. It is an error if a field in this list has a
4141	// non-empty value. This may be used to include null fields in Patch
4142	// requests.
4143	NullFields []string `json:"-"`
4144}
4145
4146func (s *GoogleCloudDialogflowCxV3beta1FormParameterFillBehavior) MarshalJSON() ([]byte, error) {
4147	type NoMethod GoogleCloudDialogflowCxV3beta1FormParameterFillBehavior
4148	raw := NoMethod(*s)
4149	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4150}
4151
4152// GoogleCloudDialogflowCxV3beta1Fulfillment: A fulfillment can do one
4153// or more of the following actions at the same time: * Generate rich
4154// message responses. * Set parameter values. * Call the webhook.
4155// Fulfillments can be called at various stages in the Page or Form
4156// lifecycle. For example, when a DetectIntentRequest drives a session
4157// to enter a new page, the page's entry fulfillment can add a static
4158// response to the QueryResult in the returning DetectIntentResponse,
4159// call the webhook (for example, to load user data from a database), or
4160// both.
4161type GoogleCloudDialogflowCxV3beta1Fulfillment struct {
4162	// ConditionalCases: Conditional cases for this fulfillment.
4163	ConditionalCases []*GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCases `json:"conditionalCases,omitempty"`
4164
4165	// Messages: The list of rich message responses to present to the user.
4166	Messages []*GoogleCloudDialogflowCxV3beta1ResponseMessage `json:"messages,omitempty"`
4167
4168	// SetParameterActions: Set parameter values before executing the
4169	// webhook.
4170	SetParameterActions []*GoogleCloudDialogflowCxV3beta1FulfillmentSetParameterAction `json:"setParameterActions,omitempty"`
4171
4172	// Tag: The tag used by the webhook to identify which fulfillment is
4173	// being called. This field is required if `webhook` is specified.
4174	Tag string `json:"tag,omitempty"`
4175
4176	// Webhook: The webhook to call. Format:
4177	// `projects//locations//agents//webhooks/`.
4178	Webhook string `json:"webhook,omitempty"`
4179
4180	// ForceSendFields is a list of field names (e.g. "ConditionalCases") to
4181	// unconditionally include in API requests. By default, fields with
4182	// empty values are omitted from API requests. However, any non-pointer,
4183	// non-interface field appearing in ForceSendFields will be sent to the
4184	// server regardless of whether the field is empty or not. This may be
4185	// used to include empty fields in Patch requests.
4186	ForceSendFields []string `json:"-"`
4187
4188	// NullFields is a list of field names (e.g. "ConditionalCases") to
4189	// include in API requests with the JSON null value. By default, fields
4190	// with empty values are omitted from API requests. However, any field
4191	// with an empty value appearing in NullFields will be sent to the
4192	// server as null. It is an error if a field in this list has a
4193	// non-empty value. This may be used to include null fields in Patch
4194	// requests.
4195	NullFields []string `json:"-"`
4196}
4197
4198func (s *GoogleCloudDialogflowCxV3beta1Fulfillment) MarshalJSON() ([]byte, error) {
4199	type NoMethod GoogleCloudDialogflowCxV3beta1Fulfillment
4200	raw := NoMethod(*s)
4201	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4202}
4203
4204// GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCases: A list of
4205// cascading if-else conditions. Cases are mutually exclusive. The first
4206// one with a matching condition is selected, all the rest ignored.
4207type GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCases struct {
4208	// Cases: A list of cascading if-else conditions.
4209	Cases []*GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCase `json:"cases,omitempty"`
4210
4211	// ForceSendFields is a list of field names (e.g. "Cases") to
4212	// unconditionally include in API requests. By default, fields with
4213	// empty values are omitted from API requests. However, any non-pointer,
4214	// non-interface field appearing in ForceSendFields will be sent to the
4215	// server regardless of whether the field is empty or not. This may be
4216	// used to include empty fields in Patch requests.
4217	ForceSendFields []string `json:"-"`
4218
4219	// NullFields is a list of field names (e.g. "Cases") to include in API
4220	// requests with the JSON null value. By default, fields with empty
4221	// values are omitted from API requests. However, any field with an
4222	// empty value appearing in NullFields will be sent to the server as
4223	// null. It is an error if a field in this list has a non-empty value.
4224	// This may be used to include null fields in Patch requests.
4225	NullFields []string `json:"-"`
4226}
4227
4228func (s *GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCases) MarshalJSON() ([]byte, error) {
4229	type NoMethod GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCases
4230	raw := NoMethod(*s)
4231	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4232}
4233
4234// GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCase: Each
4235// case has a Boolean condition. When it is evaluated to be True, the
4236// corresponding messages will be selected and evaluated recursively.
4237type GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCase struct {
4238	// CaseContent: A list of case content.
4239	CaseContent []*GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCaseCaseContent `json:"caseContent,omitempty"`
4240
4241	// Condition: The condition to activate and select this case. Empty
4242	// means the condition is always true. The condition is evaluated
4243	// against form parameters or session parameters. See the conditions
4244	// reference
4245	// (https://cloud.google.com/dialogflow/cx/docs/reference/condition).
4246	Condition string `json:"condition,omitempty"`
4247
4248	// ForceSendFields is a list of field names (e.g. "CaseContent") to
4249	// unconditionally include in API requests. By default, fields with
4250	// empty values are omitted from API requests. However, any non-pointer,
4251	// non-interface field appearing in ForceSendFields will be sent to the
4252	// server regardless of whether the field is empty or not. This may be
4253	// used to include empty fields in Patch requests.
4254	ForceSendFields []string `json:"-"`
4255
4256	// NullFields is a list of field names (e.g. "CaseContent") to include
4257	// in API requests with the JSON null value. By default, fields with
4258	// empty values are omitted from API requests. However, any field with
4259	// an empty value appearing in NullFields will be sent to the server as
4260	// null. It is an error if a field in this list has a non-empty value.
4261	// This may be used to include null fields in Patch requests.
4262	NullFields []string `json:"-"`
4263}
4264
4265func (s *GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCase) MarshalJSON() ([]byte, error) {
4266	type NoMethod GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCase
4267	raw := NoMethod(*s)
4268	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4269}
4270
4271// GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCaseCaseConte
4272// nt: The list of messages or conditional cases to activate for this
4273// case.
4274type GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCaseCaseContent struct {
4275	// AdditionalCases: Additional cases to be evaluated.
4276	AdditionalCases *GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCases `json:"additionalCases,omitempty"`
4277
4278	// Message: Returned message.
4279	Message *GoogleCloudDialogflowCxV3beta1ResponseMessage `json:"message,omitempty"`
4280
4281	// ForceSendFields is a list of field names (e.g. "AdditionalCases") to
4282	// unconditionally include in API requests. By default, fields with
4283	// empty values are omitted from API requests. However, any non-pointer,
4284	// non-interface field appearing in ForceSendFields will be sent to the
4285	// server regardless of whether the field is empty or not. This may be
4286	// used to include empty fields in Patch requests.
4287	ForceSendFields []string `json:"-"`
4288
4289	// NullFields is a list of field names (e.g. "AdditionalCases") to
4290	// include in API requests with the JSON null value. By default, fields
4291	// with empty values are omitted from API requests. However, any field
4292	// with an empty value appearing in NullFields will be sent to the
4293	// server as null. It is an error if a field in this list has a
4294	// non-empty value. This may be used to include null fields in Patch
4295	// requests.
4296	NullFields []string `json:"-"`
4297}
4298
4299func (s *GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCaseCaseContent) MarshalJSON() ([]byte, error) {
4300	type NoMethod GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCaseCaseContent
4301	raw := NoMethod(*s)
4302	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4303}
4304
4305// GoogleCloudDialogflowCxV3beta1FulfillmentSetParameterAction: Setting
4306// a parameter value.
4307type GoogleCloudDialogflowCxV3beta1FulfillmentSetParameterAction struct {
4308	// Parameter: Display name of the parameter.
4309	Parameter string `json:"parameter,omitempty"`
4310
4311	// Value: The new value of the parameter. A null value clears the
4312	// parameter.
4313	Value interface{} `json:"value,omitempty"`
4314
4315	// ForceSendFields is a list of field names (e.g. "Parameter") to
4316	// unconditionally include in API requests. By default, fields with
4317	// empty values are omitted from API requests. However, any non-pointer,
4318	// non-interface field appearing in ForceSendFields will be sent to the
4319	// server regardless of whether the field is empty or not. This may be
4320	// used to include empty fields in Patch requests.
4321	ForceSendFields []string `json:"-"`
4322
4323	// NullFields is a list of field names (e.g. "Parameter") to include in
4324	// API requests with the JSON null value. By default, fields with empty
4325	// values are omitted from API requests. However, any field with an
4326	// empty value appearing in NullFields will be sent to the server as
4327	// null. It is an error if a field in this list has a non-empty value.
4328	// This may be used to include null fields in Patch requests.
4329	NullFields []string `json:"-"`
4330}
4331
4332func (s *GoogleCloudDialogflowCxV3beta1FulfillmentSetParameterAction) MarshalJSON() ([]byte, error) {
4333	type NoMethod GoogleCloudDialogflowCxV3beta1FulfillmentSetParameterAction
4334	raw := NoMethod(*s)
4335	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4336}
4337
4338// GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata:
4339// Metadata in google::longrunning::Operation for Knowledge operations.
4340type GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata struct {
4341	// State: Required. Output only. The current state of this operation.
4342	//
4343	// Possible values:
4344	//   "STATE_UNSPECIFIED" - State unspecified.
4345	//   "PENDING" - The operation has been created.
4346	//   "RUNNING" - The operation is currently running.
4347	//   "DONE" - The operation is done, either cancelled or completed.
4348	State string `json:"state,omitempty"`
4349
4350	// ForceSendFields is a list of field names (e.g. "State") to
4351	// unconditionally include in API requests. By default, fields with
4352	// empty values are omitted from API requests. However, any non-pointer,
4353	// non-interface field appearing in ForceSendFields will be sent to the
4354	// server regardless of whether the field is empty or not. This may be
4355	// used to include empty fields in Patch requests.
4356	ForceSendFields []string `json:"-"`
4357
4358	// NullFields is a list of field names (e.g. "State") to include in API
4359	// requests with the JSON null value. By default, fields with empty
4360	// values are omitted from API requests. However, any field with an
4361	// empty value appearing in NullFields will be sent to the server as
4362	// null. It is an error if a field in this list has a non-empty value.
4363	// This may be used to include null fields in Patch requests.
4364	NullFields []string `json:"-"`
4365}
4366
4367func (s *GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata) MarshalJSON() ([]byte, error) {
4368	type NoMethod GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata
4369	raw := NoMethod(*s)
4370	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4371}
4372
4373// GoogleCloudDialogflowCxV3beta1ImportDocumentsOperationMetadata:
4374// Metadata for ImportDocuments operation.
4375type GoogleCloudDialogflowCxV3beta1ImportDocumentsOperationMetadata struct {
4376	// GenericMetadata: The generic information of the operation.
4377	GenericMetadata *GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
4378
4379	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
4380	// unconditionally include in API requests. By default, fields with
4381	// empty values are omitted from API requests. However, any non-pointer,
4382	// non-interface field appearing in ForceSendFields will be sent to the
4383	// server regardless of whether the field is empty or not. This may be
4384	// used to include empty fields in Patch requests.
4385	ForceSendFields []string `json:"-"`
4386
4387	// NullFields is a list of field names (e.g. "GenericMetadata") to
4388	// include in API requests with the JSON null value. By default, fields
4389	// with empty values are omitted from API requests. However, any field
4390	// with an empty value appearing in NullFields will be sent to the
4391	// server as null. It is an error if a field in this list has a
4392	// non-empty value. This may be used to include null fields in Patch
4393	// requests.
4394	NullFields []string `json:"-"`
4395}
4396
4397func (s *GoogleCloudDialogflowCxV3beta1ImportDocumentsOperationMetadata) MarshalJSON() ([]byte, error) {
4398	type NoMethod GoogleCloudDialogflowCxV3beta1ImportDocumentsOperationMetadata
4399	raw := NoMethod(*s)
4400	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4401}
4402
4403// GoogleCloudDialogflowCxV3beta1ImportDocumentsResponse: Response
4404// message for Documents.ImportDocuments.
4405type GoogleCloudDialogflowCxV3beta1ImportDocumentsResponse struct {
4406	// Warnings: Includes details about skipped documents or any other
4407	// warnings.
4408	Warnings []*GoogleRpcStatus `json:"warnings,omitempty"`
4409
4410	// ForceSendFields is a list of field names (e.g. "Warnings") to
4411	// unconditionally include in API requests. By default, fields with
4412	// empty values are omitted from API requests. However, any non-pointer,
4413	// non-interface field appearing in ForceSendFields will be sent to the
4414	// server regardless of whether the field is empty or not. This may be
4415	// used to include empty fields in Patch requests.
4416	ForceSendFields []string `json:"-"`
4417
4418	// NullFields is a list of field names (e.g. "Warnings") to include in
4419	// API requests with the JSON null value. By default, fields with empty
4420	// values are omitted from API requests. However, any field with an
4421	// empty value appearing in NullFields will be sent to the server as
4422	// null. It is an error if a field in this list has a non-empty value.
4423	// This may be used to include null fields in Patch requests.
4424	NullFields []string `json:"-"`
4425}
4426
4427func (s *GoogleCloudDialogflowCxV3beta1ImportDocumentsResponse) MarshalJSON() ([]byte, error) {
4428	type NoMethod GoogleCloudDialogflowCxV3beta1ImportDocumentsResponse
4429	raw := NoMethod(*s)
4430	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4431}
4432
4433// GoogleCloudDialogflowCxV3beta1ImportTestCasesMetadata: Metadata
4434// returned for the TestCases.ImportTestCases long running operation.
4435type GoogleCloudDialogflowCxV3beta1ImportTestCasesMetadata struct {
4436	// Errors: Errors for failed test cases.
4437	Errors []*GoogleCloudDialogflowCxV3beta1TestCaseError `json:"errors,omitempty"`
4438
4439	// ForceSendFields is a list of field names (e.g. "Errors") to
4440	// unconditionally include in API requests. By default, fields with
4441	// empty values are omitted from API requests. However, any non-pointer,
4442	// non-interface field appearing in ForceSendFields will be sent to the
4443	// server regardless of whether the field is empty or not. This may be
4444	// used to include empty fields in Patch requests.
4445	ForceSendFields []string `json:"-"`
4446
4447	// NullFields is a list of field names (e.g. "Errors") to include in API
4448	// requests with the JSON null value. By default, fields with empty
4449	// values are omitted from API requests. However, any field with an
4450	// empty value appearing in NullFields will be sent to the server as
4451	// null. It is an error if a field in this list has a non-empty value.
4452	// This may be used to include null fields in Patch requests.
4453	NullFields []string `json:"-"`
4454}
4455
4456func (s *GoogleCloudDialogflowCxV3beta1ImportTestCasesMetadata) MarshalJSON() ([]byte, error) {
4457	type NoMethod GoogleCloudDialogflowCxV3beta1ImportTestCasesMetadata
4458	raw := NoMethod(*s)
4459	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4460}
4461
4462// GoogleCloudDialogflowCxV3beta1ImportTestCasesResponse: The response
4463// message for TestCases.ImportTestCases.
4464type GoogleCloudDialogflowCxV3beta1ImportTestCasesResponse struct {
4465	// Names: The unique identifiers of the new test cases. Format:
4466	// `projects//locations//agents//testCases/`.
4467	Names []string `json:"names,omitempty"`
4468
4469	// ForceSendFields is a list of field names (e.g. "Names") to
4470	// unconditionally include in API requests. By default, fields with
4471	// empty values are omitted from API requests. However, any non-pointer,
4472	// non-interface field appearing in ForceSendFields will be sent to the
4473	// server regardless of whether the field is empty or not. This may be
4474	// used to include empty fields in Patch requests.
4475	ForceSendFields []string `json:"-"`
4476
4477	// NullFields is a list of field names (e.g. "Names") to include in API
4478	// requests with the JSON null value. By default, fields with empty
4479	// values are omitted from API requests. However, any field with an
4480	// empty value appearing in NullFields will be sent to the server as
4481	// null. It is an error if a field in this list has a non-empty value.
4482	// This may be used to include null fields in Patch requests.
4483	NullFields []string `json:"-"`
4484}
4485
4486func (s *GoogleCloudDialogflowCxV3beta1ImportTestCasesResponse) MarshalJSON() ([]byte, error) {
4487	type NoMethod GoogleCloudDialogflowCxV3beta1ImportTestCasesResponse
4488	raw := NoMethod(*s)
4489	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4490}
4491
4492// GoogleCloudDialogflowCxV3beta1InputAudioConfig: Instructs the speech
4493// recognizer on how to process the audio content.
4494type GoogleCloudDialogflowCxV3beta1InputAudioConfig struct {
4495	// AudioEncoding: Required. Audio encoding of the audio content to
4496	// process.
4497	//
4498	// Possible values:
4499	//   "AUDIO_ENCODING_UNSPECIFIED" - Not specified.
4500	//   "AUDIO_ENCODING_LINEAR_16" - Uncompressed 16-bit signed
4501	// little-endian samples (Linear PCM).
4502	//   "AUDIO_ENCODING_FLAC" -
4503	// [`FLAC`](https://xiph.org/flac/documentation.html) (Free Lossless
4504	// Audio Codec) is the recommended encoding because it is lossless
4505	// (therefore recognition is not compromised) and requires only about
4506	// half the bandwidth of `LINEAR16`. `FLAC` stream encoding supports
4507	// 16-bit and 24-bit samples, however, not all fields in `STREAMINFO`
4508	// are supported.
4509	//   "AUDIO_ENCODING_MULAW" - 8-bit samples that compand 14-bit audio
4510	// samples using G.711 PCMU/mu-law.
4511	//   "AUDIO_ENCODING_AMR" - Adaptive Multi-Rate Narrowband codec.
4512	// `sample_rate_hertz` must be 8000.
4513	//   "AUDIO_ENCODING_AMR_WB" - Adaptive Multi-Rate Wideband codec.
4514	// `sample_rate_hertz` must be 16000.
4515	//   "AUDIO_ENCODING_OGG_OPUS" - Opus encoded audio frames in Ogg
4516	// container ([OggOpus](https://wiki.xiph.org/OggOpus)).
4517	// `sample_rate_hertz` must be 16000.
4518	//   "AUDIO_ENCODING_SPEEX_WITH_HEADER_BYTE" - Although the use of lossy
4519	// encodings is not recommended, if a very low bitrate encoding is
4520	// required, `OGG_OPUS` is highly preferred over Speex encoding. The
4521	// [Speex](https://speex.org/) encoding supported by Dialogflow API has
4522	// a header byte in each block, as in MIME type
4523	// `audio/x-speex-with-header-byte`. It is a variant of the RTP Speex
4524	// encoding defined in [RFC 5574](https://tools.ietf.org/html/rfc5574).
4525	// The stream is a sequence of blocks, one block per RTP packet. Each
4526	// block starts with a byte containing the length of the block, in
4527	// bytes, followed by one or more frames of Speex data, padded to an
4528	// integral number of bytes (octets) as specified in RFC 5574. In other
4529	// words, each RTP header is replaced with a single byte containing the
4530	// block length. Only Speex wideband is supported. `sample_rate_hertz`
4531	// must be 16000.
4532	AudioEncoding string `json:"audioEncoding,omitempty"`
4533
4534	// EnableWordInfo: Optional. If `true`, Dialogflow returns
4535	// SpeechWordInfo in StreamingRecognitionResult with information about
4536	// the recognized speech words, e.g. start and end time offsets. If
4537	// false or unspecified, Speech doesn't return any word-level
4538	// information.
4539	EnableWordInfo bool `json:"enableWordInfo,omitempty"`
4540
4541	// Model: Optional. Which Speech model to select for the given request.
4542	// Select the model best suited to your domain to get best results. If a
4543	// model is not explicitly specified, then we auto-select a model based
4544	// on the parameters in the InputAudioConfig. If enhanced speech model
4545	// is enabled for the agent and an enhanced version of the specified
4546	// model for the language does not exist, then the speech is recognized
4547	// using the standard version of the specified model. Refer to Cloud
4548	// Speech API documentation
4549	// (https://cloud.google.com/speech-to-text/docs/basics#select-model)
4550	// for more details.
4551	Model string `json:"model,omitempty"`
4552
4553	// ModelVariant: Optional. Which variant of the Speech model to use.
4554	//
4555	// Possible values:
4556	//   "SPEECH_MODEL_VARIANT_UNSPECIFIED" - No model variant specified. In
4557	// this case Dialogflow defaults to USE_BEST_AVAILABLE.
4558	//   "USE_BEST_AVAILABLE" - Use the best available variant of the Speech
4559	// model that the caller is eligible for. Please see the [Dialogflow
4560	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
4561	// to make your project eligible for enhanced models.
4562	//   "USE_STANDARD" - Use standard model variant even if an enhanced
4563	// model is available. See the [Cloud Speech
4564	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
4565	// odels) for details about enhanced models.
4566	//   "USE_ENHANCED" - Use an enhanced model variant: * If an enhanced
4567	// variant does not exist for the given model and request language,
4568	// Dialogflow falls back to the standard variant. The [Cloud Speech
4569	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
4570	// odels) describes which models have enhanced variants. * If the API
4571	// caller isn't eligible for enhanced models, Dialogflow returns an
4572	// error. Please see the [Dialogflow
4573	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
4574	// to make your project eligible.
4575	ModelVariant string `json:"modelVariant,omitempty"`
4576
4577	// PhraseHints: Optional. A list of strings containing words and phrases
4578	// that the speech recognizer should recognize with higher likelihood.
4579	// See the Cloud Speech documentation
4580	// (https://cloud.google.com/speech-to-text/docs/basics#phrase-hints)
4581	// for more details.
4582	PhraseHints []string `json:"phraseHints,omitempty"`
4583
4584	// SampleRateHertz: Sample rate (in Hertz) of the audio content sent in
4585	// the query. Refer to Cloud Speech API documentation
4586	// (https://cloud.google.com/speech-to-text/docs/basics) for more
4587	// details.
4588	SampleRateHertz int64 `json:"sampleRateHertz,omitempty"`
4589
4590	// SingleUtterance: Optional. If `false` (default), recognition does not
4591	// cease until the client closes the stream. If `true`, the recognizer
4592	// will detect a single spoken utterance in input audio. Recognition
4593	// ceases when it detects the audio's voice has stopped or paused. In
4594	// this case, once a detected intent is received, the client should
4595	// close the stream and start a new request with a new stream as needed.
4596	// Note: This setting is relevant only for streaming methods.
4597	SingleUtterance bool `json:"singleUtterance,omitempty"`
4598
4599	// ForceSendFields is a list of field names (e.g. "AudioEncoding") to
4600	// unconditionally include in API requests. By default, fields with
4601	// empty values are omitted from API requests. However, any non-pointer,
4602	// non-interface field appearing in ForceSendFields will be sent to the
4603	// server regardless of whether the field is empty or not. This may be
4604	// used to include empty fields in Patch requests.
4605	ForceSendFields []string `json:"-"`
4606
4607	// NullFields is a list of field names (e.g. "AudioEncoding") to include
4608	// in API requests with the JSON null value. By default, fields with
4609	// empty values are omitted from API requests. However, any field with
4610	// an empty value appearing in NullFields will be sent to the server as
4611	// null. It is an error if a field in this list has a non-empty value.
4612	// This may be used to include null fields in Patch requests.
4613	NullFields []string `json:"-"`
4614}
4615
4616func (s *GoogleCloudDialogflowCxV3beta1InputAudioConfig) MarshalJSON() ([]byte, error) {
4617	type NoMethod GoogleCloudDialogflowCxV3beta1InputAudioConfig
4618	raw := NoMethod(*s)
4619	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4620}
4621
4622// GoogleCloudDialogflowCxV3beta1Intent: An intent represents a user's
4623// intent to interact with a conversational agent. You can provide
4624// information for the Dialogflow API to use to match user input to an
4625// intent by adding training phrases (i.e., examples of user input) to
4626// your intent.
4627type GoogleCloudDialogflowCxV3beta1Intent struct {
4628	// Description: Optional. Human readable description for better
4629	// understanding an intent like its scope, content, result etc. Maximum
4630	// character limit: 140 characters.
4631	Description string `json:"description,omitempty"`
4632
4633	// DisplayName: Required. The human-readable name of the intent, unique
4634	// within the agent.
4635	DisplayName string `json:"displayName,omitempty"`
4636
4637	// IsFallback: Indicates whether this is a fallback intent. Currently
4638	// only default fallback intent is allowed in the agent, which is added
4639	// upon agent creation. Adding training phrases to fallback intent is
4640	// useful in the case of requests that are mistakenly matched, since
4641	// training phrases assigned to fallback intents act as negative
4642	// examples that triggers no-match event.
4643	IsFallback bool `json:"isFallback,omitempty"`
4644
4645	// Labels: Optional. The key/value metadata to label an intent. Labels
4646	// can contain lowercase letters, digits and the symbols '-' and '_'.
4647	// International characters are allowed, including letters from unicase
4648	// alphabets. Keys must start with a letter. Keys and values can be no
4649	// longer than 63 characters and no more than 128 bytes. Prefix "sys-"
4650	// is reserved for Dialogflow defined labels. Currently allowed
4651	// Dialogflow defined labels include: * sys-head * sys-contextual The
4652	// above labels do not require value. "sys-head" means the intent is a
4653	// head intent. "sys-contextual" means the intent is a contextual
4654	// intent.
4655	Labels map[string]string `json:"labels,omitempty"`
4656
4657	// Name: The unique identifier of the intent. Required for the
4658	// Intents.UpdateIntent method. Intents.CreateIntent populates the name
4659	// automatically. Format: `projects//locations//agents//intents/`.
4660	Name string `json:"name,omitempty"`
4661
4662	// Parameters: The collection of parameters associated with the intent.
4663	Parameters []*GoogleCloudDialogflowCxV3beta1IntentParameter `json:"parameters,omitempty"`
4664
4665	// Priority: The priority of this intent. Higher numbers represent
4666	// higher priorities. - If the supplied value is unspecified or 0, the
4667	// service translates the value to 500,000, which corresponds to the
4668	// `Normal` priority in the console. - If the supplied value is
4669	// negative, the intent is ignored in runtime detect intent requests.
4670	Priority int64 `json:"priority,omitempty"`
4671
4672	// TrainingPhrases: The collection of training phrases the agent is
4673	// trained on to identify the intent.
4674	TrainingPhrases []*GoogleCloudDialogflowCxV3beta1IntentTrainingPhrase `json:"trainingPhrases,omitempty"`
4675
4676	// ForceSendFields is a list of field names (e.g. "Description") to
4677	// unconditionally include in API requests. By default, fields with
4678	// empty values are omitted from API requests. However, any non-pointer,
4679	// non-interface field appearing in ForceSendFields will be sent to the
4680	// server regardless of whether the field is empty or not. This may be
4681	// used to include empty fields in Patch requests.
4682	ForceSendFields []string `json:"-"`
4683
4684	// NullFields is a list of field names (e.g. "Description") to include
4685	// in API requests with the JSON null value. By default, fields with
4686	// empty values are omitted from API requests. However, any field with
4687	// an empty value appearing in NullFields will be sent to the server as
4688	// null. It is an error if a field in this list has a non-empty value.
4689	// This may be used to include null fields in Patch requests.
4690	NullFields []string `json:"-"`
4691}
4692
4693func (s *GoogleCloudDialogflowCxV3beta1Intent) MarshalJSON() ([]byte, error) {
4694	type NoMethod GoogleCloudDialogflowCxV3beta1Intent
4695	raw := NoMethod(*s)
4696	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4697}
4698
4699// GoogleCloudDialogflowCxV3beta1IntentInput: Represents the intent to
4700// trigger programmatically rather than as a result of natural language
4701// processing.
4702type GoogleCloudDialogflowCxV3beta1IntentInput struct {
4703	// Intent: Required. The unique identifier of the intent. Format:
4704	// `projects//locations//agents//intents/`.
4705	Intent string `json:"intent,omitempty"`
4706
4707	// ForceSendFields is a list of field names (e.g. "Intent") to
4708	// unconditionally include in API requests. By default, fields with
4709	// empty values are omitted from API requests. However, any non-pointer,
4710	// non-interface field appearing in ForceSendFields will be sent to the
4711	// server regardless of whether the field is empty or not. This may be
4712	// used to include empty fields in Patch requests.
4713	ForceSendFields []string `json:"-"`
4714
4715	// NullFields is a list of field names (e.g. "Intent") to include in API
4716	// requests with the JSON null value. By default, fields with empty
4717	// values are omitted from API requests. However, any field with an
4718	// empty value appearing in NullFields will be sent to the server as
4719	// null. It is an error if a field in this list has a non-empty value.
4720	// This may be used to include null fields in Patch requests.
4721	NullFields []string `json:"-"`
4722}
4723
4724func (s *GoogleCloudDialogflowCxV3beta1IntentInput) MarshalJSON() ([]byte, error) {
4725	type NoMethod GoogleCloudDialogflowCxV3beta1IntentInput
4726	raw := NoMethod(*s)
4727	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4728}
4729
4730// GoogleCloudDialogflowCxV3beta1IntentParameter: Represents an intent
4731// parameter.
4732type GoogleCloudDialogflowCxV3beta1IntentParameter struct {
4733	// EntityType: Required. The entity type of the parameter. Format:
4734	// `projects/-/locations/-/agents/-/entityTypes/` for system entity
4735	// types (for example,
4736	// `projects/-/locations/-/agents/-/entityTypes/sys.date`), or
4737	// `projects//locations//agents//entityTypes/` for developer entity
4738	// types.
4739	EntityType string `json:"entityType,omitempty"`
4740
4741	// Id: Required. The unique identifier of the parameter. This field is
4742	// used by training phrases to annotate their parts.
4743	Id string `json:"id,omitempty"`
4744
4745	// IsList: Indicates whether the parameter represents a list of values.
4746	IsList bool `json:"isList,omitempty"`
4747
4748	// Redact: Indicates whether the parameter content should be redacted in
4749	// log. If redaction is enabled, the parameter content will be replaced
4750	// by parameter name during logging. Note: the parameter content is
4751	// subject to redaction if either parameter level redaction or entity
4752	// type level redaction is enabled.
4753	Redact bool `json:"redact,omitempty"`
4754
4755	// ForceSendFields is a list of field names (e.g. "EntityType") to
4756	// unconditionally include in API requests. By default, fields with
4757	// empty values are omitted from API requests. However, any non-pointer,
4758	// non-interface field appearing in ForceSendFields will be sent to the
4759	// server regardless of whether the field is empty or not. This may be
4760	// used to include empty fields in Patch requests.
4761	ForceSendFields []string `json:"-"`
4762
4763	// NullFields is a list of field names (e.g. "EntityType") to include in
4764	// API requests with the JSON null value. By default, fields with empty
4765	// values are omitted from API requests. However, any field with an
4766	// empty value appearing in NullFields will be sent to the server as
4767	// null. It is an error if a field in this list has a non-empty value.
4768	// This may be used to include null fields in Patch requests.
4769	NullFields []string `json:"-"`
4770}
4771
4772func (s *GoogleCloudDialogflowCxV3beta1IntentParameter) MarshalJSON() ([]byte, error) {
4773	type NoMethod GoogleCloudDialogflowCxV3beta1IntentParameter
4774	raw := NoMethod(*s)
4775	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4776}
4777
4778// GoogleCloudDialogflowCxV3beta1IntentTrainingPhrase: Represents an
4779// example that the agent is trained on to identify the intent.
4780type GoogleCloudDialogflowCxV3beta1IntentTrainingPhrase struct {
4781	// Id: Output only. The unique identifier of the training phrase.
4782	Id string `json:"id,omitempty"`
4783
4784	// Parts: Required. The ordered list of training phrase parts. The parts
4785	// are concatenated in order to form the training phrase. Note: The API
4786	// does not automatically annotate training phrases like the Dialogflow
4787	// Console does. Note: Do not forget to include whitespace at part
4788	// boundaries, so the training phrase is well formatted when the parts
4789	// are concatenated. If the training phrase does not need to be
4790	// annotated with parameters, you just need a single part with only the
4791	// Part.text field set. If you want to annotate the training phrase, you
4792	// must create multiple parts, where the fields of each part are
4793	// populated in one of two ways: - `Part.text` is set to a part of the
4794	// phrase that has no parameters. - `Part.text` is set to a part of the
4795	// phrase that you want to annotate, and the `parameter_id` field is
4796	// set.
4797	Parts []*GoogleCloudDialogflowCxV3beta1IntentTrainingPhrasePart `json:"parts,omitempty"`
4798
4799	// RepeatCount: Indicates how many times this example was added to the
4800	// intent.
4801	RepeatCount int64 `json:"repeatCount,omitempty"`
4802
4803	// ForceSendFields is a list of field names (e.g. "Id") to
4804	// unconditionally include in API requests. By default, fields with
4805	// empty values are omitted from API requests. However, any non-pointer,
4806	// non-interface field appearing in ForceSendFields will be sent to the
4807	// server regardless of whether the field is empty or not. This may be
4808	// used to include empty fields in Patch requests.
4809	ForceSendFields []string `json:"-"`
4810
4811	// NullFields is a list of field names (e.g. "Id") to include in API
4812	// requests with the JSON null value. By default, fields with empty
4813	// values are omitted from API requests. However, any field with an
4814	// empty value appearing in NullFields will be sent to the server as
4815	// null. It is an error if a field in this list has a non-empty value.
4816	// This may be used to include null fields in Patch requests.
4817	NullFields []string `json:"-"`
4818}
4819
4820func (s *GoogleCloudDialogflowCxV3beta1IntentTrainingPhrase) MarshalJSON() ([]byte, error) {
4821	type NoMethod GoogleCloudDialogflowCxV3beta1IntentTrainingPhrase
4822	raw := NoMethod(*s)
4823	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4824}
4825
4826// GoogleCloudDialogflowCxV3beta1IntentTrainingPhrasePart: Represents a
4827// part of a training phrase.
4828type GoogleCloudDialogflowCxV3beta1IntentTrainingPhrasePart struct {
4829	// ParameterId: The parameter used to annotate this part of the training
4830	// phrase. This field is required for annotated parts of the training
4831	// phrase.
4832	ParameterId string `json:"parameterId,omitempty"`
4833
4834	// Text: Required. The text for this part.
4835	Text string `json:"text,omitempty"`
4836
4837	// ForceSendFields is a list of field names (e.g. "ParameterId") to
4838	// unconditionally include in API requests. By default, fields with
4839	// empty values are omitted from API requests. However, any non-pointer,
4840	// non-interface field appearing in ForceSendFields will be sent to the
4841	// server regardless of whether the field is empty or not. This may be
4842	// used to include empty fields in Patch requests.
4843	ForceSendFields []string `json:"-"`
4844
4845	// NullFields is a list of field names (e.g. "ParameterId") to include
4846	// in API requests with the JSON null value. By default, fields with
4847	// empty values are omitted from API requests. However, any field with
4848	// an empty value appearing in NullFields will be sent to the server as
4849	// null. It is an error if a field in this list has a non-empty value.
4850	// This may be used to include null fields in Patch requests.
4851	NullFields []string `json:"-"`
4852}
4853
4854func (s *GoogleCloudDialogflowCxV3beta1IntentTrainingPhrasePart) MarshalJSON() ([]byte, error) {
4855	type NoMethod GoogleCloudDialogflowCxV3beta1IntentTrainingPhrasePart
4856	raw := NoMethod(*s)
4857	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4858}
4859
4860// GoogleCloudDialogflowCxV3beta1Page: A Dialogflow CX conversation
4861// (session) can be described and visualized as a state machine. The
4862// states of a CX session are represented by pages. For each flow, you
4863// define many pages, where your combined pages can handle a complete
4864// conversation on the topics the flow is designed for. At any given
4865// moment, exactly one page is the current page, the current page is
4866// considered active, and the flow associated with that page is
4867// considered active. Every flow has a special start page. When a flow
4868// initially becomes active, the start page page becomes the current
4869// page. For each conversational turn, the current page will either stay
4870// the same or transition to another page. You configure each page to
4871// collect information from the end-user that is relevant for the
4872// conversational state represented by the page. For more information,
4873// see the Page guide
4874// (https://cloud.google.com/dialogflow/cx/docs/concept/page).
4875type GoogleCloudDialogflowCxV3beta1Page struct {
4876	// DisplayName: Required. The human-readable name of the page, unique
4877	// within the agent.
4878	DisplayName string `json:"displayName,omitempty"`
4879
4880	// EntryFulfillment: The fulfillment to call when the session is
4881	// entering the page.
4882	EntryFulfillment *GoogleCloudDialogflowCxV3beta1Fulfillment `json:"entryFulfillment,omitempty"`
4883
4884	// EventHandlers: Handlers associated with the page to handle events
4885	// such as webhook errors, no match or no input.
4886	EventHandlers []*GoogleCloudDialogflowCxV3beta1EventHandler `json:"eventHandlers,omitempty"`
4887
4888	// Form: The form associated with the page, used for collecting
4889	// parameters relevant to the page.
4890	Form *GoogleCloudDialogflowCxV3beta1Form `json:"form,omitempty"`
4891
4892	// Name: The unique identifier of the page. Required for the
4893	// Pages.UpdatePage method. Pages.CreatePage populates the name
4894	// automatically. Format: `projects//locations//agents//flows//pages/`.
4895	Name string `json:"name,omitempty"`
4896
4897	// TransitionRouteGroups: Ordered list of `TransitionRouteGroups`
4898	// associated with the page. Transition route groups must be unique
4899	// within a page. * If multiple transition routes within a page scope
4900	// refer to the same intent, then the precedence order is: page's
4901	// transition route -> page's transition route group -> flow's
4902	// transition routes. * If multiple transition route groups within a
4903	// page contain the same intent, then the first group in the ordered
4904	// list takes precedence.
4905	// Format:`projects//locations//agents//flows//transitionRouteGroups/`.
4906	TransitionRouteGroups []string `json:"transitionRouteGroups,omitempty"`
4907
4908	// TransitionRoutes: A list of transitions for the transition rules of
4909	// this page. They route the conversation to another page in the same
4910	// flow, or another flow. When we are in a certain page, the
4911	// TransitionRoutes are evalauted in the following order: *
4912	// TransitionRoutes defined in the page with intent specified. *
4913	// TransitionRoutes defined in the transition route groups with intent
4914	// specified. * TransitionRoutes defined in flow with intent specified.
4915	// * TransitionRoutes defined in the transition route groups with intent
4916	// specified. * TransitionRoutes defined in the page with only condition
4917	// specified. * TransitionRoutes defined in the transition route groups
4918	// with only condition specified.
4919	TransitionRoutes []*GoogleCloudDialogflowCxV3beta1TransitionRoute `json:"transitionRoutes,omitempty"`
4920
4921	// ForceSendFields is a list of field names (e.g. "DisplayName") to
4922	// unconditionally include in API requests. By default, fields with
4923	// empty values are omitted from API requests. However, any non-pointer,
4924	// non-interface field appearing in ForceSendFields will be sent to the
4925	// server regardless of whether the field is empty or not. This may be
4926	// used to include empty fields in Patch requests.
4927	ForceSendFields []string `json:"-"`
4928
4929	// NullFields is a list of field names (e.g. "DisplayName") to include
4930	// in API requests with the JSON null value. By default, fields with
4931	// empty values are omitted from API requests. However, any field with
4932	// an empty value appearing in NullFields will be sent to the server as
4933	// null. It is an error if a field in this list has a non-empty value.
4934	// This may be used to include null fields in Patch requests.
4935	NullFields []string `json:"-"`
4936}
4937
4938func (s *GoogleCloudDialogflowCxV3beta1Page) MarshalJSON() ([]byte, error) {
4939	type NoMethod GoogleCloudDialogflowCxV3beta1Page
4940	raw := NoMethod(*s)
4941	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4942}
4943
4944// GoogleCloudDialogflowCxV3beta1PageInfo: Represents page information
4945// communicated to and from the webhook.
4946type GoogleCloudDialogflowCxV3beta1PageInfo struct {
4947	// CurrentPage: Always present for WebhookRequest. Ignored for
4948	// WebhookResponse. The unique identifier of the current page. Format:
4949	// `projects//locations//agents//flows//pages/`.
4950	CurrentPage string `json:"currentPage,omitempty"`
4951
4952	// FormInfo: Optional for both WebhookRequest and WebhookResponse.
4953	// Information about the form.
4954	FormInfo *GoogleCloudDialogflowCxV3beta1PageInfoFormInfo `json:"formInfo,omitempty"`
4955
4956	// ForceSendFields is a list of field names (e.g. "CurrentPage") to
4957	// unconditionally include in API requests. By default, fields with
4958	// empty values are omitted from API requests. However, any non-pointer,
4959	// non-interface field appearing in ForceSendFields will be sent to the
4960	// server regardless of whether the field is empty or not. This may be
4961	// used to include empty fields in Patch requests.
4962	ForceSendFields []string `json:"-"`
4963
4964	// NullFields is a list of field names (e.g. "CurrentPage") to include
4965	// in API requests with the JSON null value. By default, fields with
4966	// empty values are omitted from API requests. However, any field with
4967	// an empty value appearing in NullFields will be sent to the server as
4968	// null. It is an error if a field in this list has a non-empty value.
4969	// This may be used to include null fields in Patch requests.
4970	NullFields []string `json:"-"`
4971}
4972
4973func (s *GoogleCloudDialogflowCxV3beta1PageInfo) MarshalJSON() ([]byte, error) {
4974	type NoMethod GoogleCloudDialogflowCxV3beta1PageInfo
4975	raw := NoMethod(*s)
4976	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4977}
4978
4979// GoogleCloudDialogflowCxV3beta1PageInfoFormInfo: Represents form
4980// information.
4981type GoogleCloudDialogflowCxV3beta1PageInfoFormInfo struct {
4982	// ParameterInfo: Optional for both WebhookRequest and WebhookResponse.
4983	// The parameters contained in the form. Note that the webhook cannot
4984	// add or remove any form parameter.
4985	ParameterInfo []*GoogleCloudDialogflowCxV3beta1PageInfoFormInfoParameterInfo `json:"parameterInfo,omitempty"`
4986
4987	// ForceSendFields is a list of field names (e.g. "ParameterInfo") to
4988	// unconditionally include in API requests. By default, fields with
4989	// empty values are omitted from API requests. However, any non-pointer,
4990	// non-interface field appearing in ForceSendFields will be sent to the
4991	// server regardless of whether the field is empty or not. This may be
4992	// used to include empty fields in Patch requests.
4993	ForceSendFields []string `json:"-"`
4994
4995	// NullFields is a list of field names (e.g. "ParameterInfo") to include
4996	// in API requests with the JSON null value. By default, fields with
4997	// empty values are omitted from API requests. However, any field with
4998	// an empty value appearing in NullFields will be sent to the server as
4999	// null. It is an error if a field in this list has a non-empty value.
5000	// This may be used to include null fields in Patch requests.
5001	NullFields []string `json:"-"`
5002}
5003
5004func (s *GoogleCloudDialogflowCxV3beta1PageInfoFormInfo) MarshalJSON() ([]byte, error) {
5005	type NoMethod GoogleCloudDialogflowCxV3beta1PageInfoFormInfo
5006	raw := NoMethod(*s)
5007	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5008}
5009
5010// GoogleCloudDialogflowCxV3beta1PageInfoFormInfoParameterInfo:
5011// Represents parameter information.
5012type GoogleCloudDialogflowCxV3beta1PageInfoFormInfoParameterInfo struct {
5013	// DisplayName: Always present for WebhookRequest. Required for
5014	// WebhookResponse. The human-readable name of the parameter, unique
5015	// within the form. This field cannot be modified by the webhook.
5016	DisplayName string `json:"displayName,omitempty"`
5017
5018	// JustCollected: Optional for WebhookRequest. Ignored for
5019	// WebhookResponse. Indicates if the parameter value was just collected
5020	// on the last conversation turn.
5021	JustCollected bool `json:"justCollected,omitempty"`
5022
5023	// Required: Optional for both WebhookRequest and WebhookResponse.
5024	// Indicates whether the parameter is required. Optional parameters will
5025	// not trigger prompts; however, they are filled if the user specifies
5026	// them. Required parameters must be filled before form filling
5027	// concludes.
5028	Required bool `json:"required,omitempty"`
5029
5030	// State: Always present for WebhookRequest. Required for
5031	// WebhookResponse. The state of the parameter. This field can be set to
5032	// INVALID by the webhook to invalidate the parameter; other values set
5033	// by the webhook will be ignored.
5034	//
5035	// Possible values:
5036	//   "PARAMETER_STATE_UNSPECIFIED" - Not specified. This value should be
5037	// never used.
5038	//   "EMPTY" - Indicates that the parameter does not have a value.
5039	//   "INVALID" - Indicates that the parameter value is invalid. This
5040	// field can be used by the webhook to invalidate the parameter and ask
5041	// the server to collect it from the user again.
5042	//   "FILLED" - Indicates that the parameter has a value.
5043	State string `json:"state,omitempty"`
5044
5045	// Value: Optional for both WebhookRequest and WebhookResponse. The
5046	// value of the parameter. This field can be set by the webhook to
5047	// change the parameter value.
5048	Value interface{} `json:"value,omitempty"`
5049
5050	// ForceSendFields is a list of field names (e.g. "DisplayName") to
5051	// unconditionally include in API requests. By default, fields with
5052	// empty values are omitted from API requests. However, any non-pointer,
5053	// non-interface field appearing in ForceSendFields will be sent to the
5054	// server regardless of whether the field is empty or not. This may be
5055	// used to include empty fields in Patch requests.
5056	ForceSendFields []string `json:"-"`
5057
5058	// NullFields is a list of field names (e.g. "DisplayName") to include
5059	// in API requests with the JSON null value. By default, fields with
5060	// empty values are omitted from API requests. However, any field with
5061	// an empty value appearing in NullFields will be sent to the server as
5062	// null. It is an error if a field in this list has a non-empty value.
5063	// This may be used to include null fields in Patch requests.
5064	NullFields []string `json:"-"`
5065}
5066
5067func (s *GoogleCloudDialogflowCxV3beta1PageInfoFormInfoParameterInfo) MarshalJSON() ([]byte, error) {
5068	type NoMethod GoogleCloudDialogflowCxV3beta1PageInfoFormInfoParameterInfo
5069	raw := NoMethod(*s)
5070	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5071}
5072
5073// GoogleCloudDialogflowCxV3beta1QueryInput: Represents the query input.
5074// It can contain one of: 1. A conversational query in the form of text.
5075// 2. An intent query that specifies which intent to trigger. 3. Natural
5076// language speech audio to be processed. 4. An event to be triggered.
5077type GoogleCloudDialogflowCxV3beta1QueryInput struct {
5078	// Audio: The natural language speech audio to be processed.
5079	Audio *GoogleCloudDialogflowCxV3beta1AudioInput `json:"audio,omitempty"`
5080
5081	// Dtmf: The DTMF event to be handled.
5082	Dtmf *GoogleCloudDialogflowCxV3beta1DtmfInput `json:"dtmf,omitempty"`
5083
5084	// Event: The event to be triggered.
5085	Event *GoogleCloudDialogflowCxV3beta1EventInput `json:"event,omitempty"`
5086
5087	// Intent: The intent to be triggered.
5088	Intent *GoogleCloudDialogflowCxV3beta1IntentInput `json:"intent,omitempty"`
5089
5090	// LanguageCode: Required. The language of the input. See Language
5091	// Support
5092	// (https://cloud.google.com/dialogflow/cx/docs/reference/language) for
5093	// a list of the currently supported language codes. Note that queries
5094	// in the same session do not necessarily need to specify the same
5095	// language.
5096	LanguageCode string `json:"languageCode,omitempty"`
5097
5098	// Text: The natural language text to be processed.
5099	Text *GoogleCloudDialogflowCxV3beta1TextInput `json:"text,omitempty"`
5100
5101	// ForceSendFields is a list of field names (e.g. "Audio") to
5102	// unconditionally include in API requests. By default, fields with
5103	// empty values are omitted from API requests. However, any non-pointer,
5104	// non-interface field appearing in ForceSendFields will be sent to the
5105	// server regardless of whether the field is empty or not. This may be
5106	// used to include empty fields in Patch requests.
5107	ForceSendFields []string `json:"-"`
5108
5109	// NullFields is a list of field names (e.g. "Audio") to include in API
5110	// requests with the JSON null value. By default, fields with empty
5111	// values are omitted from API requests. However, any field with an
5112	// empty value appearing in NullFields will be sent to the server as
5113	// null. It is an error if a field in this list has a non-empty value.
5114	// This may be used to include null fields in Patch requests.
5115	NullFields []string `json:"-"`
5116}
5117
5118func (s *GoogleCloudDialogflowCxV3beta1QueryInput) MarshalJSON() ([]byte, error) {
5119	type NoMethod GoogleCloudDialogflowCxV3beta1QueryInput
5120	raw := NoMethod(*s)
5121	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5122}
5123
5124// GoogleCloudDialogflowCxV3beta1ReloadDocumentOperationMetadata:
5125// Metadata for ReloadDocument operation.
5126type GoogleCloudDialogflowCxV3beta1ReloadDocumentOperationMetadata struct {
5127	// GenericMetadata: The generic information of the operation.
5128	GenericMetadata *GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
5129
5130	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
5131	// unconditionally include in API requests. By default, fields with
5132	// empty values are omitted from API requests. However, any non-pointer,
5133	// non-interface field appearing in ForceSendFields will be sent to the
5134	// server regardless of whether the field is empty or not. This may be
5135	// used to include empty fields in Patch requests.
5136	ForceSendFields []string `json:"-"`
5137
5138	// NullFields is a list of field names (e.g. "GenericMetadata") to
5139	// include in API requests with the JSON null value. By default, fields
5140	// with empty values are omitted from API requests. However, any field
5141	// with an empty value appearing in NullFields will be sent to the
5142	// server as null. It is an error if a field in this list has a
5143	// non-empty value. This may be used to include null fields in Patch
5144	// requests.
5145	NullFields []string `json:"-"`
5146}
5147
5148func (s *GoogleCloudDialogflowCxV3beta1ReloadDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
5149	type NoMethod GoogleCloudDialogflowCxV3beta1ReloadDocumentOperationMetadata
5150	raw := NoMethod(*s)
5151	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5152}
5153
5154// GoogleCloudDialogflowCxV3beta1ResponseMessage: Represents a response
5155// message that can be returned by a conversational agent. Response
5156// messages are also used for output audio synthesis. The approach is as
5157// follows: * If at least one OutputAudioText response is present, then
5158// all OutputAudioText responses are linearly concatenated, and the
5159// result is used for output audio synthesis. * If the OutputAudioText
5160// responses are a mixture of text and SSML, then the concatenated
5161// result is treated as SSML; otherwise, the result is treated as either
5162// text or SSML as appropriate. The agent designer should ideally use
5163// either text or SSML consistently throughout the bot design. *
5164// Otherwise, all Text responses are linearly concatenated, and the
5165// result is used for output audio synthesis. This approach allows for
5166// more sophisticated user experience scenarios, where the text
5167// displayed to the user may differ from what is heard.
5168type GoogleCloudDialogflowCxV3beta1ResponseMessage struct {
5169	// ConversationSuccess: Indicates that the conversation succeeded.
5170	ConversationSuccess *GoogleCloudDialogflowCxV3beta1ResponseMessageConversationSuccess `json:"conversationSuccess,omitempty"`
5171
5172	// EndInteraction: Output only. A signal that indicates the interaction
5173	// with the Dialogflow agent has ended. This message is generated by
5174	// Dialogflow only when the conversation reaches `END_SESSION` page. It
5175	// is not supposed to be defined by the user. It's guaranteed that there
5176	// is at most one such message in each response.
5177	EndInteraction *GoogleCloudDialogflowCxV3beta1ResponseMessageEndInteraction `json:"endInteraction,omitempty"`
5178
5179	// LiveAgentHandoff: Hands off conversation to a human agent.
5180	LiveAgentHandoff *GoogleCloudDialogflowCxV3beta1ResponseMessageLiveAgentHandoff `json:"liveAgentHandoff,omitempty"`
5181
5182	// MixedAudio: Output only. An audio response message composed of both
5183	// the synthesized Dialogflow agent responses and responses defined via
5184	// play_audio. This message is generated by Dialogflow only and not
5185	// supposed to be defined by the user.
5186	MixedAudio *GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudio `json:"mixedAudio,omitempty"`
5187
5188	// OutputAudioText: A text or ssml response that is preferentially used
5189	// for TTS output audio synthesis, as described in the comment on the
5190	// ResponseMessage message.
5191	OutputAudioText *GoogleCloudDialogflowCxV3beta1ResponseMessageOutputAudioText `json:"outputAudioText,omitempty"`
5192
5193	// Payload: Returns a response containing a custom, platform-specific
5194	// payload.
5195	Payload googleapi.RawMessage `json:"payload,omitempty"`
5196
5197	// PlayAudio: Signal that the client should play an audio clip hosted at
5198	// a client-specific URI. Dialogflow uses this to construct mixed_audio.
5199	// However, Dialogflow itself does not try to read or process the URI in
5200	// any way.
5201	PlayAudio *GoogleCloudDialogflowCxV3beta1ResponseMessagePlayAudio `json:"playAudio,omitempty"`
5202
5203	// Text: Returns a text response.
5204	Text *GoogleCloudDialogflowCxV3beta1ResponseMessageText `json:"text,omitempty"`
5205
5206	// ForceSendFields is a list of field names (e.g. "ConversationSuccess")
5207	// to unconditionally include in API requests. By default, fields with
5208	// empty values are omitted from API requests. However, any non-pointer,
5209	// non-interface field appearing in ForceSendFields will be sent to the
5210	// server regardless of whether the field is empty or not. This may be
5211	// used to include empty fields in Patch requests.
5212	ForceSendFields []string `json:"-"`
5213
5214	// NullFields is a list of field names (e.g. "ConversationSuccess") to
5215	// include in API requests with the JSON null value. By default, fields
5216	// with empty values are omitted from API requests. However, any field
5217	// with an empty value appearing in NullFields will be sent to the
5218	// server as null. It is an error if a field in this list has a
5219	// non-empty value. This may be used to include null fields in Patch
5220	// requests.
5221	NullFields []string `json:"-"`
5222}
5223
5224func (s *GoogleCloudDialogflowCxV3beta1ResponseMessage) MarshalJSON() ([]byte, error) {
5225	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessage
5226	raw := NoMethod(*s)
5227	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5228}
5229
5230// GoogleCloudDialogflowCxV3beta1ResponseMessageConversationSuccess:
5231// Indicates that the conversation succeeded, i.e., the bot handled the
5232// issue that the customer talked to it about. Dialogflow only uses this
5233// to determine which conversations should be counted as successful and
5234// doesn't process the metadata in this message in any way. Note that
5235// Dialogflow also considers conversations that get to the conversation
5236// end page as successful even if they don't return ConversationSuccess.
5237// You may set this, for example: * In the entry_fulfillment of a Page
5238// if entering the page indicates that the conversation succeeded. * In
5239// a webhook response when you determine that you handled the customer
5240// issue.
5241type GoogleCloudDialogflowCxV3beta1ResponseMessageConversationSuccess struct {
5242	// Metadata: Custom metadata. Dialogflow doesn't impose any structure on
5243	// this.
5244	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
5245
5246	// ForceSendFields is a list of field names (e.g. "Metadata") to
5247	// unconditionally include in API requests. By default, fields with
5248	// empty values are omitted from API requests. However, any non-pointer,
5249	// non-interface field appearing in ForceSendFields will be sent to the
5250	// server regardless of whether the field is empty or not. This may be
5251	// used to include empty fields in Patch requests.
5252	ForceSendFields []string `json:"-"`
5253
5254	// NullFields is a list of field names (e.g. "Metadata") to include in
5255	// API requests with the JSON null value. By default, fields with empty
5256	// values are omitted from API requests. However, any field with an
5257	// empty value appearing in NullFields will be sent to the server as
5258	// null. It is an error if a field in this list has a non-empty value.
5259	// This may be used to include null fields in Patch requests.
5260	NullFields []string `json:"-"`
5261}
5262
5263func (s *GoogleCloudDialogflowCxV3beta1ResponseMessageConversationSuccess) MarshalJSON() ([]byte, error) {
5264	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessageConversationSuccess
5265	raw := NoMethod(*s)
5266	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5267}
5268
5269// GoogleCloudDialogflowCxV3beta1ResponseMessageEndInteraction:
5270// Indicates that interaction with the Dialogflow agent has ended. This
5271// message is generated by Dialogflow only and not supposed to be
5272// defined by the user.
5273type GoogleCloudDialogflowCxV3beta1ResponseMessageEndInteraction struct {
5274}
5275
5276// GoogleCloudDialogflowCxV3beta1ResponseMessageLiveAgentHandoff:
5277// Indicates that the conversation should be handed off to a live agent.
5278// Dialogflow only uses this to determine which conversations were
5279// handed off to a human agent for measurement purposes. What else to do
5280// with this signal is up to you and your handoff procedures. You may
5281// set this, for example: * In the entry_fulfillment of a Page if
5282// entering the page indicates something went extremely wrong in the
5283// conversation. * In a webhook response when you determine that the
5284// customer issue can only be handled by a human.
5285type GoogleCloudDialogflowCxV3beta1ResponseMessageLiveAgentHandoff struct {
5286	// Metadata: Custom metadata for your handoff procedure. Dialogflow
5287	// doesn't impose any structure on this.
5288	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
5289
5290	// ForceSendFields is a list of field names (e.g. "Metadata") to
5291	// unconditionally include in API requests. By default, fields with
5292	// empty values are omitted from API requests. However, any non-pointer,
5293	// non-interface field appearing in ForceSendFields will be sent to the
5294	// server regardless of whether the field is empty or not. This may be
5295	// used to include empty fields in Patch requests.
5296	ForceSendFields []string `json:"-"`
5297
5298	// NullFields is a list of field names (e.g. "Metadata") to include in
5299	// API requests with the JSON null value. By default, fields with empty
5300	// values are omitted from API requests. However, any field with an
5301	// empty value appearing in NullFields will be sent to the server as
5302	// null. It is an error if a field in this list has a non-empty value.
5303	// This may be used to include null fields in Patch requests.
5304	NullFields []string `json:"-"`
5305}
5306
5307func (s *GoogleCloudDialogflowCxV3beta1ResponseMessageLiveAgentHandoff) MarshalJSON() ([]byte, error) {
5308	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessageLiveAgentHandoff
5309	raw := NoMethod(*s)
5310	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5311}
5312
5313// GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudio: Represents
5314// an audio message that is composed of both segments synthesized from
5315// the Dialogflow agent prompts and ones hosted externally at the
5316// specified URIs. The external URIs are specified via play_audio. This
5317// message is generated by Dialogflow only and not supposed to be
5318// defined by the user.
5319type GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudio struct {
5320	// Segments: Segments this audio response is composed of.
5321	Segments []*GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudioSegment `json:"segments,omitempty"`
5322
5323	// ForceSendFields is a list of field names (e.g. "Segments") to
5324	// unconditionally include in API requests. By default, fields with
5325	// empty values are omitted from API requests. However, any non-pointer,
5326	// non-interface field appearing in ForceSendFields will be sent to the
5327	// server regardless of whether the field is empty or not. This may be
5328	// used to include empty fields in Patch requests.
5329	ForceSendFields []string `json:"-"`
5330
5331	// NullFields is a list of field names (e.g. "Segments") to include in
5332	// API requests with the JSON null value. By default, fields with empty
5333	// values are omitted from API requests. However, any field with an
5334	// empty value appearing in NullFields will be sent to the server as
5335	// null. It is an error if a field in this list has a non-empty value.
5336	// This may be used to include null fields in Patch requests.
5337	NullFields []string `json:"-"`
5338}
5339
5340func (s *GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudio) MarshalJSON() ([]byte, error) {
5341	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudio
5342	raw := NoMethod(*s)
5343	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5344}
5345
5346// GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudioSegment:
5347// Represents one segment of audio.
5348type GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudioSegment struct {
5349	// AllowPlaybackInterruption: Output only. Whether the playback of this
5350	// segment can be interrupted by the end user's speech and the client
5351	// should then start the next Dialogflow request.
5352	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
5353
5354	// Audio: Raw audio synthesized from the Dialogflow agent's response
5355	// using the output config specified in the request.
5356	Audio string `json:"audio,omitempty"`
5357
5358	// Uri: Client-specific URI that points to an audio clip accessible to
5359	// the client. Dialogflow does not impose any validation on it.
5360	Uri string `json:"uri,omitempty"`
5361
5362	// ForceSendFields is a list of field names (e.g.
5363	// "AllowPlaybackInterruption") to unconditionally include in API
5364	// requests. By default, fields with empty values are omitted from API
5365	// requests. However, any non-pointer, non-interface field appearing in
5366	// ForceSendFields will be sent to the server regardless of whether the
5367	// field is empty or not. This may be used to include empty fields in
5368	// Patch requests.
5369	ForceSendFields []string `json:"-"`
5370
5371	// NullFields is a list of field names (e.g.
5372	// "AllowPlaybackInterruption") to include in API requests with the JSON
5373	// null value. By default, fields with empty values are omitted from API
5374	// requests. However, any field with an empty value appearing in
5375	// NullFields will be sent to the server as null. It is an error if a
5376	// field in this list has a non-empty value. This may be used to include
5377	// null fields in Patch requests.
5378	NullFields []string `json:"-"`
5379}
5380
5381func (s *GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudioSegment) MarshalJSON() ([]byte, error) {
5382	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudioSegment
5383	raw := NoMethod(*s)
5384	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5385}
5386
5387// GoogleCloudDialogflowCxV3beta1ResponseMessageOutputAudioText: A text
5388// or ssml response that is preferentially used for TTS output audio
5389// synthesis, as described in the comment on the ResponseMessage
5390// message.
5391type GoogleCloudDialogflowCxV3beta1ResponseMessageOutputAudioText struct {
5392	// AllowPlaybackInterruption: Output only. Whether the playback of this
5393	// message can be interrupted by the end user's speech and the client
5394	// can then starts the next Dialogflow request.
5395	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
5396
5397	// Ssml: The SSML text to be synthesized. For more information, see SSML
5398	// (/speech/text-to-speech/docs/ssml).
5399	Ssml string `json:"ssml,omitempty"`
5400
5401	// Text: The raw text to be synthesized.
5402	Text string `json:"text,omitempty"`
5403
5404	// ForceSendFields is a list of field names (e.g.
5405	// "AllowPlaybackInterruption") to unconditionally include in API
5406	// requests. By default, fields with empty values are omitted from API
5407	// requests. However, any non-pointer, non-interface field appearing in
5408	// ForceSendFields will be sent to the server regardless of whether the
5409	// field is empty or not. This may be used to include empty fields in
5410	// Patch requests.
5411	ForceSendFields []string `json:"-"`
5412
5413	// NullFields is a list of field names (e.g.
5414	// "AllowPlaybackInterruption") to include in API requests with the JSON
5415	// null value. By default, fields with empty values are omitted from API
5416	// requests. However, any field with an empty value appearing in
5417	// NullFields will be sent to the server as null. It is an error if a
5418	// field in this list has a non-empty value. This may be used to include
5419	// null fields in Patch requests.
5420	NullFields []string `json:"-"`
5421}
5422
5423func (s *GoogleCloudDialogflowCxV3beta1ResponseMessageOutputAudioText) MarshalJSON() ([]byte, error) {
5424	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessageOutputAudioText
5425	raw := NoMethod(*s)
5426	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5427}
5428
5429// GoogleCloudDialogflowCxV3beta1ResponseMessagePlayAudio: Specifies an
5430// audio clip to be played by the client as part of the response.
5431type GoogleCloudDialogflowCxV3beta1ResponseMessagePlayAudio struct {
5432	// AllowPlaybackInterruption: Output only. Whether the playback of this
5433	// message can be interrupted by the end user's speech and the client
5434	// can then starts the next Dialogflow request.
5435	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
5436
5437	// AudioUri: Required. URI of the audio clip. Dialogflow does not impose
5438	// any validation on this value. It is specific to the client that reads
5439	// it.
5440	AudioUri string `json:"audioUri,omitempty"`
5441
5442	// ForceSendFields is a list of field names (e.g.
5443	// "AllowPlaybackInterruption") to unconditionally include in API
5444	// requests. By default, fields with empty values are omitted from API
5445	// requests. However, any non-pointer, non-interface field appearing in
5446	// ForceSendFields will be sent to the server regardless of whether the
5447	// field is empty or not. This may be used to include empty fields in
5448	// Patch requests.
5449	ForceSendFields []string `json:"-"`
5450
5451	// NullFields is a list of field names (e.g.
5452	// "AllowPlaybackInterruption") to include in API requests with the JSON
5453	// null value. By default, fields with empty values are omitted from API
5454	// requests. However, any field with an empty value appearing in
5455	// NullFields will be sent to the server as null. It is an error if a
5456	// field in this list has a non-empty value. This may be used to include
5457	// null fields in Patch requests.
5458	NullFields []string `json:"-"`
5459}
5460
5461func (s *GoogleCloudDialogflowCxV3beta1ResponseMessagePlayAudio) MarshalJSON() ([]byte, error) {
5462	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessagePlayAudio
5463	raw := NoMethod(*s)
5464	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5465}
5466
5467// GoogleCloudDialogflowCxV3beta1ResponseMessageText: The text response
5468// message.
5469type GoogleCloudDialogflowCxV3beta1ResponseMessageText struct {
5470	// AllowPlaybackInterruption: Output only. Whether the playback of this
5471	// message can be interrupted by the end user's speech and the client
5472	// can then starts the next Dialogflow request.
5473	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
5474
5475	// Text: Required. A collection of text responses.
5476	Text []string `json:"text,omitempty"`
5477
5478	// ForceSendFields is a list of field names (e.g.
5479	// "AllowPlaybackInterruption") to unconditionally include in API
5480	// requests. By default, fields with empty values are omitted from API
5481	// requests. However, any non-pointer, non-interface field appearing in
5482	// ForceSendFields will be sent to the server regardless of whether the
5483	// field is empty or not. This may be used to include empty fields in
5484	// Patch requests.
5485	ForceSendFields []string `json:"-"`
5486
5487	// NullFields is a list of field names (e.g.
5488	// "AllowPlaybackInterruption") to include in API requests with the JSON
5489	// null value. By default, fields with empty values are omitted from API
5490	// requests. However, any field with an empty value appearing in
5491	// NullFields will be sent to the server as null. It is an error if a
5492	// field in this list has a non-empty value. This may be used to include
5493	// null fields in Patch requests.
5494	NullFields []string `json:"-"`
5495}
5496
5497func (s *GoogleCloudDialogflowCxV3beta1ResponseMessageText) MarshalJSON() ([]byte, error) {
5498	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessageText
5499	raw := NoMethod(*s)
5500	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5501}
5502
5503// GoogleCloudDialogflowCxV3beta1RunTestCaseMetadata: Metadata returned
5504// for the TestCases.RunTestCase long running operation.
5505type GoogleCloudDialogflowCxV3beta1RunTestCaseMetadata struct {
5506}
5507
5508// GoogleCloudDialogflowCxV3beta1RunTestCaseResponse: The response
5509// message for TestCases.RunTestCase.
5510type GoogleCloudDialogflowCxV3beta1RunTestCaseResponse struct {
5511	// Result: The result.
5512	Result *GoogleCloudDialogflowCxV3beta1TestCaseResult `json:"result,omitempty"`
5513
5514	// ForceSendFields is a list of field names (e.g. "Result") to
5515	// unconditionally include in API requests. By default, fields with
5516	// empty values are omitted from API requests. However, any non-pointer,
5517	// non-interface field appearing in ForceSendFields will be sent to the
5518	// server regardless of whether the field is empty or not. This may be
5519	// used to include empty fields in Patch requests.
5520	ForceSendFields []string `json:"-"`
5521
5522	// NullFields is a list of field names (e.g. "Result") to include in API
5523	// requests with the JSON null value. By default, fields with empty
5524	// values are omitted from API requests. However, any field with an
5525	// empty value appearing in NullFields will be sent to the server as
5526	// null. It is an error if a field in this list has a non-empty value.
5527	// This may be used to include null fields in Patch requests.
5528	NullFields []string `json:"-"`
5529}
5530
5531func (s *GoogleCloudDialogflowCxV3beta1RunTestCaseResponse) MarshalJSON() ([]byte, error) {
5532	type NoMethod GoogleCloudDialogflowCxV3beta1RunTestCaseResponse
5533	raw := NoMethod(*s)
5534	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5535}
5536
5537// GoogleCloudDialogflowCxV3beta1SessionInfo: Represents session
5538// information communicated to and from the webhook.
5539type GoogleCloudDialogflowCxV3beta1SessionInfo struct {
5540	// Parameters: Optional for WebhookRequest. Optional for
5541	// WebhookResponse. All parameters collected from forms and intents
5542	// during the session. Parameters can be created, updated, or removed by
5543	// the webhook. To remove a parameter from the session, the webhook
5544	// should explicitly set the parameter value to null in WebhookResponse.
5545	// The map is keyed by parameters' display names.
5546	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
5547
5548	// Session: Always present for WebhookRequest. Ignored for
5549	// WebhookResponse. The unique identifier of the session. This field can
5550	// be used by the webhook to identify a session. Format:
5551	// `projects//locations//agents//sessions/` or
5552	// `projects//locations//agents//environments//sessions/` if environment
5553	// is specified.
5554	Session string `json:"session,omitempty"`
5555
5556	// ForceSendFields is a list of field names (e.g. "Parameters") to
5557	// unconditionally include in API requests. By default, fields with
5558	// empty values are omitted from API requests. However, any non-pointer,
5559	// non-interface field appearing in ForceSendFields will be sent to the
5560	// server regardless of whether the field is empty or not. This may be
5561	// used to include empty fields in Patch requests.
5562	ForceSendFields []string `json:"-"`
5563
5564	// NullFields is a list of field names (e.g. "Parameters") to include in
5565	// API requests with the JSON null value. By default, fields with empty
5566	// values are omitted from API requests. However, any field with an
5567	// empty value appearing in NullFields will be sent to the server as
5568	// null. It is an error if a field in this list has a non-empty value.
5569	// This may be used to include null fields in Patch requests.
5570	NullFields []string `json:"-"`
5571}
5572
5573func (s *GoogleCloudDialogflowCxV3beta1SessionInfo) MarshalJSON() ([]byte, error) {
5574	type NoMethod GoogleCloudDialogflowCxV3beta1SessionInfo
5575	raw := NoMethod(*s)
5576	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5577}
5578
5579// GoogleCloudDialogflowCxV3beta1TestCase: Represents a test case.
5580type GoogleCloudDialogflowCxV3beta1TestCase struct {
5581	// CreationTime: Output only. When the test was created.
5582	CreationTime string `json:"creationTime,omitempty"`
5583
5584	// DisplayName: Required. The human-readable name of the test case,
5585	// unique within the agent. Limit of 200 characters.
5586	DisplayName string `json:"displayName,omitempty"`
5587
5588	// LastTestResult: The latest test result.
5589	LastTestResult *GoogleCloudDialogflowCxV3beta1TestCaseResult `json:"lastTestResult,omitempty"`
5590
5591	// Name: The unique identifier of the test case.
5592	// TestCases.CreateTestCase will populate the name automatically.
5593	// Otherwise use format: `projects//locations//agents/ /testCases/`.
5594	Name string `json:"name,omitempty"`
5595
5596	// Notes: Additional freeform notes about the test case. Limit of 400
5597	// characters.
5598	Notes string `json:"notes,omitempty"`
5599
5600	// Tags: Tags are short descriptions that users may apply to test cases
5601	// for organizational and filtering purposes. Each tag should start with
5602	// "#" and has a limit of 30 characters.
5603	Tags []string `json:"tags,omitempty"`
5604
5605	// TestCaseConversationTurns: The conversation turns uttered when the
5606	// test case was created, in chronological order. These include the
5607	// canonical set of agent utterances that should occur when the agent is
5608	// working properly.
5609	TestCaseConversationTurns []*GoogleCloudDialogflowCxV3beta1ConversationTurn `json:"testCaseConversationTurns,omitempty"`
5610
5611	// TestConfig: Config for the test case.
5612	TestConfig *GoogleCloudDialogflowCxV3beta1TestConfig `json:"testConfig,omitempty"`
5613
5614	// ForceSendFields is a list of field names (e.g. "CreationTime") to
5615	// unconditionally include in API requests. By default, fields with
5616	// empty values are omitted from API requests. However, any non-pointer,
5617	// non-interface field appearing in ForceSendFields will be sent to the
5618	// server regardless of whether the field is empty or not. This may be
5619	// used to include empty fields in Patch requests.
5620	ForceSendFields []string `json:"-"`
5621
5622	// NullFields is a list of field names (e.g. "CreationTime") to include
5623	// in API requests with the JSON null value. By default, fields with
5624	// empty values are omitted from API requests. However, any field with
5625	// an empty value appearing in NullFields will be sent to the server as
5626	// null. It is an error if a field in this list has a non-empty value.
5627	// This may be used to include null fields in Patch requests.
5628	NullFields []string `json:"-"`
5629}
5630
5631func (s *GoogleCloudDialogflowCxV3beta1TestCase) MarshalJSON() ([]byte, error) {
5632	type NoMethod GoogleCloudDialogflowCxV3beta1TestCase
5633	raw := NoMethod(*s)
5634	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5635}
5636
5637// GoogleCloudDialogflowCxV3beta1TestCaseError: Error info for importing
5638// a test.
5639type GoogleCloudDialogflowCxV3beta1TestCaseError struct {
5640	// Status: The status associated with the test case.
5641	Status *GoogleRpcStatus `json:"status,omitempty"`
5642
5643	// TestCase: The test case.
5644	TestCase *GoogleCloudDialogflowCxV3beta1TestCase `json:"testCase,omitempty"`
5645
5646	// ForceSendFields is a list of field names (e.g. "Status") to
5647	// unconditionally include in API requests. By default, fields with
5648	// empty values are omitted from API requests. However, any non-pointer,
5649	// non-interface field appearing in ForceSendFields will be sent to the
5650	// server regardless of whether the field is empty or not. This may be
5651	// used to include empty fields in Patch requests.
5652	ForceSendFields []string `json:"-"`
5653
5654	// NullFields is a list of field names (e.g. "Status") to include in API
5655	// requests with the JSON null value. By default, fields with empty
5656	// values are omitted from API requests. However, any field with an
5657	// empty value appearing in NullFields will be sent to the server as
5658	// null. It is an error if a field in this list has a non-empty value.
5659	// This may be used to include null fields in Patch requests.
5660	NullFields []string `json:"-"`
5661}
5662
5663func (s *GoogleCloudDialogflowCxV3beta1TestCaseError) MarshalJSON() ([]byte, error) {
5664	type NoMethod GoogleCloudDialogflowCxV3beta1TestCaseError
5665	raw := NoMethod(*s)
5666	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5667}
5668
5669// GoogleCloudDialogflowCxV3beta1TestCaseResult: Represents a result
5670// from running a test case in an agent environment.
5671type GoogleCloudDialogflowCxV3beta1TestCaseResult struct {
5672	// ConversationTurns: The conversation turns uttered during the test
5673	// case replay in chronological order.
5674	ConversationTurns []*GoogleCloudDialogflowCxV3beta1ConversationTurn `json:"conversationTurns,omitempty"`
5675
5676	// Environment: Environment where the test was run. If not set, it
5677	// indicates the draft environment.
5678	Environment string `json:"environment,omitempty"`
5679
5680	// Name: The resource name for the test case result. Format:
5681	// `projects//locations//agents//testCases/ /results/`.
5682	Name string `json:"name,omitempty"`
5683
5684	// TestResult: Whether the test case passed in the agent environment.
5685	//
5686	// Possible values:
5687	//   "TEST_RESULT_UNSPECIFIED" - Not specified. Should never be used.
5688	//   "PASSED" - The test passed.
5689	//   "FAILED" - The test did not pass.
5690	TestResult string `json:"testResult,omitempty"`
5691
5692	// TestTime: The time that the test was run.
5693	TestTime string `json:"testTime,omitempty"`
5694
5695	// ForceSendFields is a list of field names (e.g. "ConversationTurns")
5696	// to unconditionally include in API requests. By default, fields with
5697	// empty values are omitted from API requests. However, any non-pointer,
5698	// non-interface field appearing in ForceSendFields will be sent to the
5699	// server regardless of whether the field is empty or not. This may be
5700	// used to include empty fields in Patch requests.
5701	ForceSendFields []string `json:"-"`
5702
5703	// NullFields is a list of field names (e.g. "ConversationTurns") to
5704	// include in API requests with the JSON null value. By default, fields
5705	// with empty values are omitted from API requests. However, any field
5706	// with an empty value appearing in NullFields will be sent to the
5707	// server as null. It is an error if a field in this list has a
5708	// non-empty value. This may be used to include null fields in Patch
5709	// requests.
5710	NullFields []string `json:"-"`
5711}
5712
5713func (s *GoogleCloudDialogflowCxV3beta1TestCaseResult) MarshalJSON() ([]byte, error) {
5714	type NoMethod GoogleCloudDialogflowCxV3beta1TestCaseResult
5715	raw := NoMethod(*s)
5716	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5717}
5718
5719// GoogleCloudDialogflowCxV3beta1TestConfig: Represents configurations
5720// for a test case.
5721type GoogleCloudDialogflowCxV3beta1TestConfig struct {
5722	// Flow: Flow name. If not set, default start flow is assumed. Format:
5723	// `projects//locations//agents//flows/`.
5724	Flow string `json:"flow,omitempty"`
5725
5726	// TrackingParameters: Session parameters to be compared when
5727	// calculating differences.
5728	TrackingParameters []string `json:"trackingParameters,omitempty"`
5729
5730	// ForceSendFields is a list of field names (e.g. "Flow") to
5731	// unconditionally include in API requests. By default, fields with
5732	// empty values are omitted from API requests. However, any non-pointer,
5733	// non-interface field appearing in ForceSendFields will be sent to the
5734	// server regardless of whether the field is empty or not. This may be
5735	// used to include empty fields in Patch requests.
5736	ForceSendFields []string `json:"-"`
5737
5738	// NullFields is a list of field names (e.g. "Flow") to include in API
5739	// requests with the JSON null value. By default, fields with empty
5740	// values are omitted from API requests. However, any field with an
5741	// empty value appearing in NullFields will be sent to the server as
5742	// null. It is an error if a field in this list has a non-empty value.
5743	// This may be used to include null fields in Patch requests.
5744	NullFields []string `json:"-"`
5745}
5746
5747func (s *GoogleCloudDialogflowCxV3beta1TestConfig) MarshalJSON() ([]byte, error) {
5748	type NoMethod GoogleCloudDialogflowCxV3beta1TestConfig
5749	raw := NoMethod(*s)
5750	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5751}
5752
5753// GoogleCloudDialogflowCxV3beta1TestError: Error info for running a
5754// test.
5755type GoogleCloudDialogflowCxV3beta1TestError struct {
5756	// Status: The status associated with the test.
5757	Status *GoogleRpcStatus `json:"status,omitempty"`
5758
5759	// TestCase: The test case resource name.
5760	TestCase string `json:"testCase,omitempty"`
5761
5762	// TestTime: The timestamp when the test was completed.
5763	TestTime string `json:"testTime,omitempty"`
5764
5765	// ForceSendFields is a list of field names (e.g. "Status") to
5766	// unconditionally include in API requests. By default, fields with
5767	// empty values are omitted from API requests. However, any non-pointer,
5768	// non-interface field appearing in ForceSendFields will be sent to the
5769	// server regardless of whether the field is empty or not. This may be
5770	// used to include empty fields in Patch requests.
5771	ForceSendFields []string `json:"-"`
5772
5773	// NullFields is a list of field names (e.g. "Status") to include in API
5774	// requests with the JSON null value. By default, fields with empty
5775	// values are omitted from API requests. However, any field with an
5776	// empty value appearing in NullFields will be sent to the server as
5777	// null. It is an error if a field in this list has a non-empty value.
5778	// This may be used to include null fields in Patch requests.
5779	NullFields []string `json:"-"`
5780}
5781
5782func (s *GoogleCloudDialogflowCxV3beta1TestError) MarshalJSON() ([]byte, error) {
5783	type NoMethod GoogleCloudDialogflowCxV3beta1TestError
5784	raw := NoMethod(*s)
5785	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5786}
5787
5788// GoogleCloudDialogflowCxV3beta1TestRunDifference: The description of
5789// differences between original and replayed agent output.
5790type GoogleCloudDialogflowCxV3beta1TestRunDifference struct {
5791	// Description: A description of the diff, showing the actual output vs
5792	// expected output.
5793	Description string `json:"description,omitempty"`
5794
5795	// Type: The type of diff.
5796	//
5797	// Possible values:
5798	//   "DIFF_TYPE_UNSPECIFIED" - Should never be used.
5799	//   "INTENT" - The intent.
5800	//   "PAGE" - The page.
5801	//   "PARAMETERS" - The parameters.
5802	//   "UTTERANCE" - The message utterance.
5803	Type string `json:"type,omitempty"`
5804
5805	// ForceSendFields is a list of field names (e.g. "Description") to
5806	// unconditionally include in API requests. By default, fields with
5807	// empty values are omitted from API requests. However, any non-pointer,
5808	// non-interface field appearing in ForceSendFields will be sent to the
5809	// server regardless of whether the field is empty or not. This may be
5810	// used to include empty fields in Patch requests.
5811	ForceSendFields []string `json:"-"`
5812
5813	// NullFields is a list of field names (e.g. "Description") to include
5814	// in API requests with the JSON null value. By default, fields with
5815	// empty values are omitted from API requests. However, any field with
5816	// an empty value appearing in NullFields will be sent to the server as
5817	// null. It is an error if a field in this list has a non-empty value.
5818	// This may be used to include null fields in Patch requests.
5819	NullFields []string `json:"-"`
5820}
5821
5822func (s *GoogleCloudDialogflowCxV3beta1TestRunDifference) MarshalJSON() ([]byte, error) {
5823	type NoMethod GoogleCloudDialogflowCxV3beta1TestRunDifference
5824	raw := NoMethod(*s)
5825	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5826}
5827
5828// GoogleCloudDialogflowCxV3beta1TextInput: Represents the natural
5829// language text to be processed.
5830type GoogleCloudDialogflowCxV3beta1TextInput struct {
5831	// Text: Required. The UTF-8 encoded natural language text to be
5832	// processed. Text length must not exceed 256 characters.
5833	Text string `json:"text,omitempty"`
5834
5835	// ForceSendFields is a list of field names (e.g. "Text") to
5836	// unconditionally include in API requests. By default, fields with
5837	// empty values are omitted from API requests. However, any non-pointer,
5838	// non-interface field appearing in ForceSendFields will be sent to the
5839	// server regardless of whether the field is empty or not. This may be
5840	// used to include empty fields in Patch requests.
5841	ForceSendFields []string `json:"-"`
5842
5843	// NullFields is a list of field names (e.g. "Text") to include in API
5844	// requests with the JSON null value. By default, fields with empty
5845	// values are omitted from API requests. However, any field with an
5846	// empty value appearing in NullFields will be sent to the server as
5847	// null. It is an error if a field in this list has a non-empty value.
5848	// This may be used to include null fields in Patch requests.
5849	NullFields []string `json:"-"`
5850}
5851
5852func (s *GoogleCloudDialogflowCxV3beta1TextInput) MarshalJSON() ([]byte, error) {
5853	type NoMethod GoogleCloudDialogflowCxV3beta1TextInput
5854	raw := NoMethod(*s)
5855	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5856}
5857
5858// GoogleCloudDialogflowCxV3beta1TransitionRoute: A transition route
5859// specifies a intent that can be matched and/or a data condition that
5860// can be evaluated during a session. When a specified transition is
5861// matched, the following actions are taken in order: * If there is a
5862// `trigger_fulfillment` associated with the transition, it will be
5863// called. * If there is a `target_page` associated with the transition,
5864// the session will transition into the specified page. * If there is a
5865// `target_flow` associated with the transition, the session will
5866// transition into the specified flow.
5867type GoogleCloudDialogflowCxV3beta1TransitionRoute struct {
5868	// Condition: The condition to evaluate against form parameters or
5869	// session parameters. See the conditions reference
5870	// (https://cloud.google.com/dialogflow/cx/docs/reference/condition). At
5871	// least one of `intent` or `condition` must be specified. When both
5872	// `intent` and `condition` are specified, the transition can only
5873	// happen when both are fulfilled.
5874	Condition string `json:"condition,omitempty"`
5875
5876	// Intent: The unique identifier of an Intent. Format:
5877	// `projects//locations//agents//intents/`. Indicates that the
5878	// transition can only happen when the given intent is matched. At least
5879	// one of `intent` or `condition` must be specified. When both `intent`
5880	// and `condition` are specified, the transition can only happen when
5881	// both are fulfilled.
5882	Intent string `json:"intent,omitempty"`
5883
5884	// Name: Output only. The unique identifier of this transition route.
5885	Name string `json:"name,omitempty"`
5886
5887	// TargetFlow: The target flow to transition to. Format:
5888	// `projects//locations//agents//flows/`.
5889	TargetFlow string `json:"targetFlow,omitempty"`
5890
5891	// TargetPage: The target page to transition to. Format:
5892	// `projects//locations//agents//flows//pages/`.
5893	TargetPage string `json:"targetPage,omitempty"`
5894
5895	// TriggerFulfillment: The fulfillment to call when the condition is
5896	// satisfied. At least one of `trigger_fulfillment` and `target` must be
5897	// specified. When both are defined, `trigger_fulfillment` is executed
5898	// first.
5899	TriggerFulfillment *GoogleCloudDialogflowCxV3beta1Fulfillment `json:"triggerFulfillment,omitempty"`
5900
5901	// ForceSendFields is a list of field names (e.g. "Condition") to
5902	// unconditionally include in API requests. By default, fields with
5903	// empty values are omitted from API requests. However, any non-pointer,
5904	// non-interface field appearing in ForceSendFields will be sent to the
5905	// server regardless of whether the field is empty or not. This may be
5906	// used to include empty fields in Patch requests.
5907	ForceSendFields []string `json:"-"`
5908
5909	// NullFields is a list of field names (e.g. "Condition") to include in
5910	// API requests with the JSON null value. By default, fields with empty
5911	// values are omitted from API requests. However, any field with an
5912	// empty value appearing in NullFields will be sent to the server as
5913	// null. It is an error if a field in this list has a non-empty value.
5914	// This may be used to include null fields in Patch requests.
5915	NullFields []string `json:"-"`
5916}
5917
5918func (s *GoogleCloudDialogflowCxV3beta1TransitionRoute) MarshalJSON() ([]byte, error) {
5919	type NoMethod GoogleCloudDialogflowCxV3beta1TransitionRoute
5920	raw := NoMethod(*s)
5921	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5922}
5923
5924// GoogleCloudDialogflowCxV3beta1UpdateDocumentOperationMetadata:
5925// Metadata for UpdateDocument operation.
5926type GoogleCloudDialogflowCxV3beta1UpdateDocumentOperationMetadata struct {
5927	// GenericMetadata: The generic information of the operation.
5928	GenericMetadata *GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
5929
5930	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
5931	// unconditionally include in API requests. By default, fields with
5932	// empty values are omitted from API requests. However, any non-pointer,
5933	// non-interface field appearing in ForceSendFields will be sent to the
5934	// server regardless of whether the field is empty or not. This may be
5935	// used to include empty fields in Patch requests.
5936	ForceSendFields []string `json:"-"`
5937
5938	// NullFields is a list of field names (e.g. "GenericMetadata") to
5939	// include in API requests with the JSON null value. By default, fields
5940	// with empty values are omitted from API requests. However, any field
5941	// with an empty value appearing in NullFields will be sent to the
5942	// server as null. It is an error if a field in this list has a
5943	// non-empty value. This may be used to include null fields in Patch
5944	// requests.
5945	NullFields []string `json:"-"`
5946}
5947
5948func (s *GoogleCloudDialogflowCxV3beta1UpdateDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
5949	type NoMethod GoogleCloudDialogflowCxV3beta1UpdateDocumentOperationMetadata
5950	raw := NoMethod(*s)
5951	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5952}
5953
5954// GoogleCloudDialogflowCxV3beta1WebhookRequest: The request message for
5955// a webhook call. The request is sent as a JSON object and the field
5956// names will be presented in camel cases.
5957type GoogleCloudDialogflowCxV3beta1WebhookRequest struct {
5958	// DetectIntentResponseId: Always present. The unique identifier of the
5959	// DetectIntentResponse that will be returned to the API caller.
5960	DetectIntentResponseId string `json:"detectIntentResponseId,omitempty"`
5961
5962	// FulfillmentInfo: Always present. Information about the fulfillment
5963	// that triggered this webhook call.
5964	FulfillmentInfo *GoogleCloudDialogflowCxV3beta1WebhookRequestFulfillmentInfo `json:"fulfillmentInfo,omitempty"`
5965
5966	// IntentInfo: Information about the last matched intent.
5967	IntentInfo *GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo `json:"intentInfo,omitempty"`
5968
5969	// Messages: The list of rich message responses to present to the user.
5970	// Webhook can choose to append or replace this list in
5971	// WebhookResponse.fulfillment_response;
5972	Messages []*GoogleCloudDialogflowCxV3beta1ResponseMessage `json:"messages,omitempty"`
5973
5974	// PageInfo: Information about page status.
5975	PageInfo *GoogleCloudDialogflowCxV3beta1PageInfo `json:"pageInfo,omitempty"`
5976
5977	// Payload: Custom data set in QueryParameters.payload.
5978	Payload googleapi.RawMessage `json:"payload,omitempty"`
5979
5980	// SentimentAnalysisResult: The sentiment analysis result of the current
5981	// user request. The field is filled when sentiment analysis is
5982	// configured to be enabled for the request.
5983	SentimentAnalysisResult *GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult `json:"sentimentAnalysisResult,omitempty"`
5984
5985	// SessionInfo: Information about session status.
5986	SessionInfo *GoogleCloudDialogflowCxV3beta1SessionInfo `json:"sessionInfo,omitempty"`
5987
5988	// Text: If natural language text was provided as input, this field will
5989	// contain a copy of the text.
5990	Text string `json:"text,omitempty"`
5991
5992	// Transcript: If natural language speech audio was provided as input,
5993	// this field will contain the transcript for the audio.
5994	Transcript string `json:"transcript,omitempty"`
5995
5996	// TriggerEvent: If an event was provided as input, this field will
5997	// contain the name of the event.
5998	TriggerEvent string `json:"triggerEvent,omitempty"`
5999
6000	// TriggerIntent: If an intent was provided as input, this field will
6001	// contain a copy of the intent identifier. Format:
6002	// `projects//locations//agents//intents/`.
6003	TriggerIntent string `json:"triggerIntent,omitempty"`
6004
6005	// ForceSendFields is a list of field names (e.g.
6006	// "DetectIntentResponseId") to unconditionally include in API requests.
6007	// By default, fields with empty values are omitted from API requests.
6008	// However, any non-pointer, non-interface field appearing in
6009	// ForceSendFields will be sent to the server regardless of whether the
6010	// field is empty or not. This may be used to include empty fields in
6011	// Patch requests.
6012	ForceSendFields []string `json:"-"`
6013
6014	// NullFields is a list of field names (e.g. "DetectIntentResponseId")
6015	// to include in API requests with the JSON null value. By default,
6016	// fields with empty values are omitted from API requests. However, any
6017	// field with an empty value appearing in NullFields will be sent to the
6018	// server as null. It is an error if a field in this list has a
6019	// non-empty value. This may be used to include null fields in Patch
6020	// requests.
6021	NullFields []string `json:"-"`
6022}
6023
6024func (s *GoogleCloudDialogflowCxV3beta1WebhookRequest) MarshalJSON() ([]byte, error) {
6025	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequest
6026	raw := NoMethod(*s)
6027	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6028}
6029
6030// GoogleCloudDialogflowCxV3beta1WebhookRequestFulfillmentInfo:
6031// Represents fulfillment information communicated to the webhook.
6032type GoogleCloudDialogflowCxV3beta1WebhookRequestFulfillmentInfo struct {
6033	// Tag: Always present. The tag used to identify which fulfillment is
6034	// being called.
6035	Tag string `json:"tag,omitempty"`
6036
6037	// ForceSendFields is a list of field names (e.g. "Tag") to
6038	// unconditionally include in API requests. By default, fields with
6039	// empty values are omitted from API requests. However, any non-pointer,
6040	// non-interface field appearing in ForceSendFields will be sent to the
6041	// server regardless of whether the field is empty or not. This may be
6042	// used to include empty fields in Patch requests.
6043	ForceSendFields []string `json:"-"`
6044
6045	// NullFields is a list of field names (e.g. "Tag") to include in API
6046	// requests with the JSON null value. By default, fields with empty
6047	// values are omitted from API requests. However, any field with an
6048	// empty value appearing in NullFields will be sent to the server as
6049	// null. It is an error if a field in this list has a non-empty value.
6050	// This may be used to include null fields in Patch requests.
6051	NullFields []string `json:"-"`
6052}
6053
6054func (s *GoogleCloudDialogflowCxV3beta1WebhookRequestFulfillmentInfo) MarshalJSON() ([]byte, error) {
6055	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequestFulfillmentInfo
6056	raw := NoMethod(*s)
6057	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6058}
6059
6060// GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo: Represents
6061// intent information communicated to the webhook.
6062type GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo struct {
6063	// Confidence: The confidence of the matched intent. Values range from
6064	// 0.0 (completely uncertain) to 1.0 (completely certain).
6065	Confidence float64 `json:"confidence,omitempty"`
6066
6067	// DisplayName: Always present. The display name of the last matched
6068	// intent.
6069	DisplayName string `json:"displayName,omitempty"`
6070
6071	// LastMatchedIntent: Always present. The unique identifier of the last
6072	// matched intent. Format: `projects//locations//agents//intents/`.
6073	LastMatchedIntent string `json:"lastMatchedIntent,omitempty"`
6074
6075	// Parameters: Parameters identified as a result of intent matching.
6076	// This is a map of the name of the identified parameter to the value of
6077	// the parameter identified from the user's utterance. All parameters
6078	// defined in the matched intent that are identified will be surfaced
6079	// here.
6080	Parameters map[string]GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfoIntentParameterValue `json:"parameters,omitempty"`
6081
6082	// ForceSendFields is a list of field names (e.g. "Confidence") to
6083	// unconditionally include in API requests. By default, fields with
6084	// empty values are omitted from API requests. However, any non-pointer,
6085	// non-interface field appearing in ForceSendFields will be sent to the
6086	// server regardless of whether the field is empty or not. This may be
6087	// used to include empty fields in Patch requests.
6088	ForceSendFields []string `json:"-"`
6089
6090	// NullFields is a list of field names (e.g. "Confidence") to include in
6091	// API requests with the JSON null value. By default, fields with empty
6092	// values are omitted from API requests. However, any field with an
6093	// empty value appearing in NullFields will be sent to the server as
6094	// null. It is an error if a field in this list has a non-empty value.
6095	// This may be used to include null fields in Patch requests.
6096	NullFields []string `json:"-"`
6097}
6098
6099func (s *GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo) MarshalJSON() ([]byte, error) {
6100	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo
6101	raw := NoMethod(*s)
6102	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6103}
6104
6105func (s *GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo) UnmarshalJSON(data []byte) error {
6106	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo
6107	var s1 struct {
6108		Confidence gensupport.JSONFloat64 `json:"confidence"`
6109		*NoMethod
6110	}
6111	s1.NoMethod = (*NoMethod)(s)
6112	if err := json.Unmarshal(data, &s1); err != nil {
6113		return err
6114	}
6115	s.Confidence = float64(s1.Confidence)
6116	return nil
6117}
6118
6119// GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfoIntentParameterV
6120// alue: Represents a value for an intent parameter.
6121type GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfoIntentParameterValue struct {
6122	// OriginalValue: Always present. Original text value extracted from
6123	// user utterance.
6124	OriginalValue string `json:"originalValue,omitempty"`
6125
6126	// ResolvedValue: Always present. Structured value for the parameter
6127	// extracted from user utterance.
6128	ResolvedValue interface{} `json:"resolvedValue,omitempty"`
6129
6130	// ForceSendFields is a list of field names (e.g. "OriginalValue") to
6131	// unconditionally include in API requests. By default, fields with
6132	// empty values are omitted from API requests. However, any non-pointer,
6133	// non-interface field appearing in ForceSendFields will be sent to the
6134	// server regardless of whether the field is empty or not. This may be
6135	// used to include empty fields in Patch requests.
6136	ForceSendFields []string `json:"-"`
6137
6138	// NullFields is a list of field names (e.g. "OriginalValue") to include
6139	// in API requests with the JSON null value. By default, fields with
6140	// empty values are omitted from API requests. However, any field with
6141	// an empty value appearing in NullFields will be sent to the server as
6142	// null. It is an error if a field in this list has a non-empty value.
6143	// This may be used to include null fields in Patch requests.
6144	NullFields []string `json:"-"`
6145}
6146
6147func (s *GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfoIntentParameterValue) MarshalJSON() ([]byte, error) {
6148	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfoIntentParameterValue
6149	raw := NoMethod(*s)
6150	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6151}
6152
6153// GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult:
6154// Represents the result of sentiment analysis.
6155type GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult struct {
6156	// Magnitude: A non-negative number in the [0, +inf) range, which
6157	// represents the absolute magnitude of sentiment, regardless of score
6158	// (positive or negative).
6159	Magnitude float64 `json:"magnitude,omitempty"`
6160
6161	// Score: Sentiment score between -1.0 (negative sentiment) and 1.0
6162	// (positive sentiment).
6163	Score float64 `json:"score,omitempty"`
6164
6165	// ForceSendFields is a list of field names (e.g. "Magnitude") to
6166	// unconditionally include in API requests. By default, fields with
6167	// empty values are omitted from API requests. However, any non-pointer,
6168	// non-interface field appearing in ForceSendFields will be sent to the
6169	// server regardless of whether the field is empty or not. This may be
6170	// used to include empty fields in Patch requests.
6171	ForceSendFields []string `json:"-"`
6172
6173	// NullFields is a list of field names (e.g. "Magnitude") to include in
6174	// API requests with the JSON null value. By default, fields with empty
6175	// values are omitted from API requests. However, any field with an
6176	// empty value appearing in NullFields will be sent to the server as
6177	// null. It is an error if a field in this list has a non-empty value.
6178	// This may be used to include null fields in Patch requests.
6179	NullFields []string `json:"-"`
6180}
6181
6182func (s *GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult) MarshalJSON() ([]byte, error) {
6183	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult
6184	raw := NoMethod(*s)
6185	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6186}
6187
6188func (s *GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult) UnmarshalJSON(data []byte) error {
6189	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult
6190	var s1 struct {
6191		Magnitude gensupport.JSONFloat64 `json:"magnitude"`
6192		Score     gensupport.JSONFloat64 `json:"score"`
6193		*NoMethod
6194	}
6195	s1.NoMethod = (*NoMethod)(s)
6196	if err := json.Unmarshal(data, &s1); err != nil {
6197		return err
6198	}
6199	s.Magnitude = float64(s1.Magnitude)
6200	s.Score = float64(s1.Score)
6201	return nil
6202}
6203
6204// GoogleCloudDialogflowCxV3beta1WebhookResponse: The response message
6205// for a webhook call.
6206type GoogleCloudDialogflowCxV3beta1WebhookResponse struct {
6207	// FulfillmentResponse: The fulfillment response to send to the user.
6208	// This field can be omitted by the webhook if it does not intend to
6209	// send any response to the user.
6210	FulfillmentResponse *GoogleCloudDialogflowCxV3beta1WebhookResponseFulfillmentResponse `json:"fulfillmentResponse,omitempty"`
6211
6212	// PageInfo: Information about page status. This field can be omitted by
6213	// the webhook if it does not intend to modify page status.
6214	PageInfo *GoogleCloudDialogflowCxV3beta1PageInfo `json:"pageInfo,omitempty"`
6215
6216	// Payload: Value to append directly to QueryResult.webhook_payloads.
6217	Payload googleapi.RawMessage `json:"payload,omitempty"`
6218
6219	// SessionInfo: Information about session status. This field can be
6220	// omitted by the webhook if it does not intend to modify session
6221	// status.
6222	SessionInfo *GoogleCloudDialogflowCxV3beta1SessionInfo `json:"sessionInfo,omitempty"`
6223
6224	// TargetFlow: The target flow to transition to. Format:
6225	// `projects//locations//agents//flows/`.
6226	TargetFlow string `json:"targetFlow,omitempty"`
6227
6228	// TargetPage: The target page to transition to. Format:
6229	// `projects//locations//agents//flows//pages/`.
6230	TargetPage string `json:"targetPage,omitempty"`
6231
6232	// ForceSendFields is a list of field names (e.g. "FulfillmentResponse")
6233	// to unconditionally include in API requests. By default, fields with
6234	// empty values are omitted from API requests. However, any non-pointer,
6235	// non-interface field appearing in ForceSendFields will be sent to the
6236	// server regardless of whether the field is empty or not. This may be
6237	// used to include empty fields in Patch requests.
6238	ForceSendFields []string `json:"-"`
6239
6240	// NullFields is a list of field names (e.g. "FulfillmentResponse") to
6241	// include in API requests with the JSON null value. By default, fields
6242	// with empty values are omitted from API requests. However, any field
6243	// with an empty value appearing in NullFields will be sent to the
6244	// server as null. It is an error if a field in this list has a
6245	// non-empty value. This may be used to include null fields in Patch
6246	// requests.
6247	NullFields []string `json:"-"`
6248}
6249
6250func (s *GoogleCloudDialogflowCxV3beta1WebhookResponse) MarshalJSON() ([]byte, error) {
6251	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookResponse
6252	raw := NoMethod(*s)
6253	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6254}
6255
6256// GoogleCloudDialogflowCxV3beta1WebhookResponseFulfillmentResponse:
6257// Represents a fulfillment response to the user.
6258type GoogleCloudDialogflowCxV3beta1WebhookResponseFulfillmentResponse struct {
6259	// MergeBehavior: Merge behavior for `messages`.
6260	//
6261	// Possible values:
6262	//   "MERGE_BEHAVIOR_UNSPECIFIED" - Not specified. `APPEND` will be
6263	// used.
6264	//   "APPEND" - `messages` will be appended to the list of messages
6265	// waiting to be sent to the user.
6266	//   "REPLACE" - `messages` will replace the list of messages waiting to
6267	// be sent to the user.
6268	MergeBehavior string `json:"mergeBehavior,omitempty"`
6269
6270	// Messages: The list of rich message responses to present to the user.
6271	Messages []*GoogleCloudDialogflowCxV3beta1ResponseMessage `json:"messages,omitempty"`
6272
6273	// ForceSendFields is a list of field names (e.g. "MergeBehavior") to
6274	// unconditionally include in API requests. By default, fields with
6275	// empty values are omitted from API requests. However, any non-pointer,
6276	// non-interface field appearing in ForceSendFields will be sent to the
6277	// server regardless of whether the field is empty or not. This may be
6278	// used to include empty fields in Patch requests.
6279	ForceSendFields []string `json:"-"`
6280
6281	// NullFields is a list of field names (e.g. "MergeBehavior") to include
6282	// in API requests with the JSON null value. By default, fields with
6283	// empty values are omitted from API requests. However, any field with
6284	// an empty value appearing in NullFields will be sent to the server as
6285	// null. It is an error if a field in this list has a non-empty value.
6286	// This may be used to include null fields in Patch requests.
6287	NullFields []string `json:"-"`
6288}
6289
6290func (s *GoogleCloudDialogflowCxV3beta1WebhookResponseFulfillmentResponse) MarshalJSON() ([]byte, error) {
6291	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookResponseFulfillmentResponse
6292	raw := NoMethod(*s)
6293	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6294}
6295
6296// GoogleCloudDialogflowV2Agent: A Dialogflow agent is a virtual agent
6297// that handles conversations with your end-users. It is a natural
6298// language understanding module that understands the nuances of human
6299// language. Dialogflow translates end-user text or audio during a
6300// conversation to structured data that your apps and services can
6301// understand. You design and build a Dialogflow agent to handle the
6302// types of conversations required for your system. For more information
6303// about agents, see the Agent guide
6304// (https://cloud.google.com/dialogflow/docs/agents-overview).
6305type GoogleCloudDialogflowV2Agent struct {
6306	// ApiVersion: Optional. API version displayed in Dialogflow console. If
6307	// not specified, V2 API is assumed. Clients are free to query different
6308	// service endpoints for different API versions. However, bots
6309	// connectors and webhook calls will follow the specified API version.
6310	//
6311	// Possible values:
6312	//   "API_VERSION_UNSPECIFIED" - Not specified.
6313	//   "API_VERSION_V1" - Legacy V1 API.
6314	//   "API_VERSION_V2" - V2 API.
6315	//   "API_VERSION_V2_BETA_1" - V2beta1 API.
6316	ApiVersion string `json:"apiVersion,omitempty"`
6317
6318	// AvatarUri: Optional. The URI of the agent's avatar. Avatars are used
6319	// throughout the Dialogflow console and in the self-hosted Web Demo
6320	// (https://cloud.google.com/dialogflow/docs/integrations/web-demo)
6321	// integration.
6322	AvatarUri string `json:"avatarUri,omitempty"`
6323
6324	// ClassificationThreshold: Optional. To filter out false positive
6325	// results and still get variety in matched natural language inputs for
6326	// your agent, you can tune the machine learning classification
6327	// threshold. If the returned score value is less than the threshold
6328	// value, then a fallback intent will be triggered or, if there are no
6329	// fallback intents defined, no intent will be triggered. The score
6330	// values range from 0.0 (completely uncertain) to 1.0 (completely
6331	// certain). If set to 0.0, the default of 0.3 is used.
6332	ClassificationThreshold float64 `json:"classificationThreshold,omitempty"`
6333
6334	// DefaultLanguageCode: Required. The default language of the agent as a
6335	// language tag. See Language Support
6336	// (https://cloud.google.com/dialogflow/docs/reference/language) for a
6337	// list of the currently supported language codes. This field cannot be
6338	// set by the `Update` method.
6339	DefaultLanguageCode string `json:"defaultLanguageCode,omitempty"`
6340
6341	// Description: Optional. The description of this agent. The maximum
6342	// length is 500 characters. If exceeded, the request is rejected.
6343	Description string `json:"description,omitempty"`
6344
6345	// DisplayName: Required. The name of this agent.
6346	DisplayName string `json:"displayName,omitempty"`
6347
6348	// EnableLogging: Optional. Determines whether this agent should log
6349	// conversation queries.
6350	EnableLogging bool `json:"enableLogging,omitempty"`
6351
6352	// MatchMode: Optional. Determines how intents are detected from user
6353	// queries.
6354	//
6355	// Possible values:
6356	//   "MATCH_MODE_UNSPECIFIED" - Not specified.
6357	//   "MATCH_MODE_HYBRID" - Best for agents with a small number of
6358	// examples in intents and/or wide use of templates syntax and composite
6359	// entities.
6360	//   "MATCH_MODE_ML_ONLY" - Can be used for agents with a large number
6361	// of examples in intents, especially the ones using @sys.any or very
6362	// large custom entities.
6363	MatchMode string `json:"matchMode,omitempty"`
6364
6365	// Parent: Required. The project of this agent. Format: `projects/`.
6366	Parent string `json:"parent,omitempty"`
6367
6368	// SupportedLanguageCodes: Optional. The list of all languages supported
6369	// by this agent (except for the `default_language_code`).
6370	SupportedLanguageCodes []string `json:"supportedLanguageCodes,omitempty"`
6371
6372	// Tier: Optional. The agent tier. If not specified, TIER_STANDARD is
6373	// assumed.
6374	//
6375	// Possible values:
6376	//   "TIER_UNSPECIFIED" - Not specified. This value should never be
6377	// used.
6378	//   "TIER_STANDARD" - Standard tier.
6379	//   "TIER_ENTERPRISE" - Enterprise tier (Essentials).
6380	//   "TIER_ENTERPRISE_PLUS" - Enterprise tier (Plus).
6381	Tier string `json:"tier,omitempty"`
6382
6383	// TimeZone: Required. The time zone of this agent from the time zone
6384	// database (https://www.iana.org/time-zones), e.g., America/New_York,
6385	// Europe/Paris.
6386	TimeZone string `json:"timeZone,omitempty"`
6387
6388	// ServerResponse contains the HTTP response code and headers from the
6389	// server.
6390	googleapi.ServerResponse `json:"-"`
6391
6392	// ForceSendFields is a list of field names (e.g. "ApiVersion") to
6393	// unconditionally include in API requests. By default, fields with
6394	// empty values are omitted from API requests. However, any non-pointer,
6395	// non-interface field appearing in ForceSendFields will be sent to the
6396	// server regardless of whether the field is empty or not. This may be
6397	// used to include empty fields in Patch requests.
6398	ForceSendFields []string `json:"-"`
6399
6400	// NullFields is a list of field names (e.g. "ApiVersion") to include in
6401	// API requests with the JSON null value. By default, fields with empty
6402	// values are omitted from API requests. However, any field with an
6403	// empty value appearing in NullFields will be sent to the server as
6404	// null. It is an error if a field in this list has a non-empty value.
6405	// This may be used to include null fields in Patch requests.
6406	NullFields []string `json:"-"`
6407}
6408
6409func (s *GoogleCloudDialogflowV2Agent) MarshalJSON() ([]byte, error) {
6410	type NoMethod GoogleCloudDialogflowV2Agent
6411	raw := NoMethod(*s)
6412	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6413}
6414
6415func (s *GoogleCloudDialogflowV2Agent) UnmarshalJSON(data []byte) error {
6416	type NoMethod GoogleCloudDialogflowV2Agent
6417	var s1 struct {
6418		ClassificationThreshold gensupport.JSONFloat64 `json:"classificationThreshold"`
6419		*NoMethod
6420	}
6421	s1.NoMethod = (*NoMethod)(s)
6422	if err := json.Unmarshal(data, &s1); err != nil {
6423		return err
6424	}
6425	s.ClassificationThreshold = float64(s1.ClassificationThreshold)
6426	return nil
6427}
6428
6429// GoogleCloudDialogflowV2AgentAssistantFeedback: Detail feedback of
6430// Agent Assist result.
6431type GoogleCloudDialogflowV2AgentAssistantFeedback struct {
6432	// AnswerRelevance: Optional. Whether or not the suggested answer is
6433	// relevant. For example: * Query: "Can I change my mailing address?" *
6434	// Suggested document says: "Items must be returned/exchanged within 60
6435	// days of the purchase date." * answer_relevance:
6436	// AnswerRelevance.IRRELEVANT
6437	//
6438	// Possible values:
6439	//   "ANSWER_RELEVANCE_UNSPECIFIED" - Answer relevance unspecified.
6440	//   "IRRELEVANT" - Answer is irrelevant to query.
6441	//   "RELEVANT" - Answer is relevant to query.
6442	AnswerRelevance string `json:"answerRelevance,omitempty"`
6443
6444	// DocumentCorrectness: Optional. Whether or not the information in the
6445	// document is correct. For example: * Query: "Can I return the package
6446	// in 2 days once received?" * Suggested document says: "Items must be
6447	// returned/exchanged within 60 days of the purchase date." * Ground
6448	// truth: "No return or exchange is allowed." * [document_correctness]:
6449	// INCORRECT
6450	//
6451	// Possible values:
6452	//   "DOCUMENT_CORRECTNESS_UNSPECIFIED" - Document correctness
6453	// unspecified.
6454	//   "INCORRECT" - Information in document is incorrect.
6455	//   "CORRECT" - Information in document is correct.
6456	DocumentCorrectness string `json:"documentCorrectness,omitempty"`
6457
6458	// DocumentEfficiency: Optional. Whether or not the suggested document
6459	// is efficient. For example, if the document is poorly written, hard to
6460	// understand, hard to use or too long to find useful information,
6461	// document_efficiency is DocumentEfficiency.INEFFICIENT.
6462	//
6463	// Possible values:
6464	//   "DOCUMENT_EFFICIENCY_UNSPECIFIED" - Document efficiency
6465	// unspecified.
6466	//   "INEFFICIENT" - Document is inefficient.
6467	//   "EFFICIENT" - Document is efficient.
6468	DocumentEfficiency string `json:"documentEfficiency,omitempty"`
6469
6470	// ForceSendFields is a list of field names (e.g. "AnswerRelevance") to
6471	// unconditionally include in API requests. By default, fields with
6472	// empty values are omitted from API requests. However, any non-pointer,
6473	// non-interface field appearing in ForceSendFields will be sent to the
6474	// server regardless of whether the field is empty or not. This may be
6475	// used to include empty fields in Patch requests.
6476	ForceSendFields []string `json:"-"`
6477
6478	// NullFields is a list of field names (e.g. "AnswerRelevance") to
6479	// include in API requests with the JSON null value. By default, fields
6480	// with empty values are omitted from API requests. However, any field
6481	// with an empty value appearing in NullFields will be sent to the
6482	// server as null. It is an error if a field in this list has a
6483	// non-empty value. This may be used to include null fields in Patch
6484	// requests.
6485	NullFields []string `json:"-"`
6486}
6487
6488func (s *GoogleCloudDialogflowV2AgentAssistantFeedback) MarshalJSON() ([]byte, error) {
6489	type NoMethod GoogleCloudDialogflowV2AgentAssistantFeedback
6490	raw := NoMethod(*s)
6491	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6492}
6493
6494// GoogleCloudDialogflowV2AgentAssistantRecord: Represents a record of a
6495// human agent assist answer.
6496type GoogleCloudDialogflowV2AgentAssistantRecord struct {
6497	// ArticleSuggestionAnswer: Output only. The article suggestion answer.
6498	ArticleSuggestionAnswer *GoogleCloudDialogflowV2ArticleAnswer `json:"articleSuggestionAnswer,omitempty"`
6499
6500	// FaqAnswer: Output only. The FAQ answer.
6501	FaqAnswer *GoogleCloudDialogflowV2FaqAnswer `json:"faqAnswer,omitempty"`
6502
6503	// ForceSendFields is a list of field names (e.g.
6504	// "ArticleSuggestionAnswer") to unconditionally include in API
6505	// requests. By default, fields with empty values are omitted from API
6506	// requests. However, any non-pointer, non-interface field appearing in
6507	// ForceSendFields will be sent to the server regardless of whether the
6508	// field is empty or not. This may be used to include empty fields in
6509	// Patch requests.
6510	ForceSendFields []string `json:"-"`
6511
6512	// NullFields is a list of field names (e.g. "ArticleSuggestionAnswer")
6513	// to include in API requests with the JSON null value. By default,
6514	// fields with empty values are omitted from API requests. However, any
6515	// field with an empty value appearing in NullFields will be sent to the
6516	// server as null. It is an error if a field in this list has a
6517	// non-empty value. This may be used to include null fields in Patch
6518	// requests.
6519	NullFields []string `json:"-"`
6520}
6521
6522func (s *GoogleCloudDialogflowV2AgentAssistantRecord) MarshalJSON() ([]byte, error) {
6523	type NoMethod GoogleCloudDialogflowV2AgentAssistantRecord
6524	raw := NoMethod(*s)
6525	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6526}
6527
6528// GoogleCloudDialogflowV2AnalyzeContentRequest: The request message for
6529// Participants.AnalyzeContent.
6530type GoogleCloudDialogflowV2AnalyzeContentRequest struct {
6531	// EventInput: An input event to send to Dialogflow.
6532	EventInput *GoogleCloudDialogflowV2EventInput `json:"eventInput,omitempty"`
6533
6534	// QueryParams: Parameters for a Dialogflow virtual-agent query.
6535	QueryParams *GoogleCloudDialogflowV2QueryParameters `json:"queryParams,omitempty"`
6536
6537	// ReplyAudioConfig: Speech synthesis configuration. The speech
6538	// synthesis settings for a virtual agent that may be configured for the
6539	// associated conversation profile are not used when calling
6540	// AnalyzeContent. If this configuration is not supplied, speech
6541	// synthesis is disabled.
6542	ReplyAudioConfig *GoogleCloudDialogflowV2OutputAudioConfig `json:"replyAudioConfig,omitempty"`
6543
6544	// RequestId: A unique identifier for this request. Restricted to 36
6545	// ASCII characters. A random UUID is recommended. This request is only
6546	// idempotent if a `request_id` is provided.
6547	RequestId string `json:"requestId,omitempty"`
6548
6549	// TextInput: The natural language text to be processed.
6550	TextInput *GoogleCloudDialogflowV2TextInput `json:"textInput,omitempty"`
6551
6552	// ForceSendFields is a list of field names (e.g. "EventInput") to
6553	// unconditionally include in API requests. By default, fields with
6554	// empty values are omitted from API requests. However, any non-pointer,
6555	// non-interface field appearing in ForceSendFields will be sent to the
6556	// server regardless of whether the field is empty or not. This may be
6557	// used to include empty fields in Patch requests.
6558	ForceSendFields []string `json:"-"`
6559
6560	// NullFields is a list of field names (e.g. "EventInput") to include in
6561	// API requests with the JSON null value. By default, fields with empty
6562	// values are omitted from API requests. However, any field with an
6563	// empty value appearing in NullFields will be sent to the server as
6564	// null. It is an error if a field in this list has a non-empty value.
6565	// This may be used to include null fields in Patch requests.
6566	NullFields []string `json:"-"`
6567}
6568
6569func (s *GoogleCloudDialogflowV2AnalyzeContentRequest) MarshalJSON() ([]byte, error) {
6570	type NoMethod GoogleCloudDialogflowV2AnalyzeContentRequest
6571	raw := NoMethod(*s)
6572	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6573}
6574
6575// GoogleCloudDialogflowV2AnalyzeContentResponse: The response message
6576// for Participants.AnalyzeContent.
6577type GoogleCloudDialogflowV2AnalyzeContentResponse struct {
6578	// AutomatedAgentReply: Only set if a Dialogflow automated agent has
6579	// responded. Note that:
6580	// AutomatedAgentReply.detect_intent_response.output_audio and
6581	// AutomatedAgentReply.detect_intent_response.output_audio_config are
6582	// always empty, use reply_audio instead.
6583	AutomatedAgentReply *GoogleCloudDialogflowV2AutomatedAgentReply `json:"automatedAgentReply,omitempty"`
6584
6585	// DtmfParameters: Indicates the parameters of DTMF.
6586	DtmfParameters *GoogleCloudDialogflowV2DtmfParameters `json:"dtmfParameters,omitempty"`
6587
6588	// EndUserSuggestionResults: The suggestions for end user. The order is
6589	// the same as
6590	// HumanAgentAssistantConfig.SuggestionConfig.feature_configs of
6591	// HumanAgentAssistantConfig.end_user_suggestion_config.
6592	EndUserSuggestionResults []*GoogleCloudDialogflowV2SuggestionResult `json:"endUserSuggestionResults,omitempty"`
6593
6594	// HumanAgentSuggestionResults: The suggestions for most recent human
6595	// agent. The order is the same as
6596	// HumanAgentAssistantConfig.SuggestionConfig.feature_configs of
6597	// HumanAgentAssistantConfig.human_agent_suggestion_config.
6598	HumanAgentSuggestionResults []*GoogleCloudDialogflowV2SuggestionResult `json:"humanAgentSuggestionResults,omitempty"`
6599
6600	// Message: Message analyzed by CCAI.
6601	Message *GoogleCloudDialogflowV2Message `json:"message,omitempty"`
6602
6603	// ReplyAudio: The audio data bytes encoded as specified in the request.
6604	// This field is set if: - `reply_audio_config` was specified in the
6605	// request, or - The automated agent responded with audio to play to the
6606	// user. In such case, `reply_audio.config` contains settings used to
6607	// synthesize the speech. In some scenarios, multiple output audio
6608	// fields may be present in the response structure. In these cases, only
6609	// the top-most-level audio output has content.
6610	ReplyAudio *GoogleCloudDialogflowV2OutputAudio `json:"replyAudio,omitempty"`
6611
6612	// ReplyText: The output text content. This field is set if the
6613	// automated agent responded with text to show to the user.
6614	ReplyText string `json:"replyText,omitempty"`
6615
6616	// ServerResponse contains the HTTP response code and headers from the
6617	// server.
6618	googleapi.ServerResponse `json:"-"`
6619
6620	// ForceSendFields is a list of field names (e.g. "AutomatedAgentReply")
6621	// to unconditionally include in API requests. By default, fields with
6622	// empty values are omitted from API requests. However, any non-pointer,
6623	// non-interface field appearing in ForceSendFields will be sent to the
6624	// server regardless of whether the field is empty or not. This may be
6625	// used to include empty fields in Patch requests.
6626	ForceSendFields []string `json:"-"`
6627
6628	// NullFields is a list of field names (e.g. "AutomatedAgentReply") to
6629	// include in API requests with the JSON null value. By default, fields
6630	// with empty values are omitted from API requests. However, any field
6631	// with an empty value appearing in NullFields will be sent to the
6632	// server as null. It is an error if a field in this list has a
6633	// non-empty value. This may be used to include null fields in Patch
6634	// requests.
6635	NullFields []string `json:"-"`
6636}
6637
6638func (s *GoogleCloudDialogflowV2AnalyzeContentResponse) MarshalJSON() ([]byte, error) {
6639	type NoMethod GoogleCloudDialogflowV2AnalyzeContentResponse
6640	raw := NoMethod(*s)
6641	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6642}
6643
6644// GoogleCloudDialogflowV2AnnotatedMessagePart: Represents a part of a
6645// message possibly annotated with an entity. The part can be an entity
6646// or purely a part of the message between two entities or message
6647// start/end.
6648type GoogleCloudDialogflowV2AnnotatedMessagePart struct {
6649	// EntityType: The Dialogflow system entity type
6650	// (https://cloud.google.com/dialogflow/docs/reference/system-entities)
6651	// of this message part. If this is empty, Dialogflow could not annotate
6652	// the phrase part with a system entity.
6653	EntityType string `json:"entityType,omitempty"`
6654
6655	// FormattedValue: The Dialogflow system entity formatted value
6656	// (https://cloud.google.com/dialogflow/docs/reference/system-entities)
6657	// of this message part. For example for a system entity of type
6658	// `@sys.unit-currency`, this may contain: { "amount": 5, "currency":
6659	// "USD" }
6660	FormattedValue interface{} `json:"formattedValue,omitempty"`
6661
6662	// Text: A part of a message possibly annotated with an entity.
6663	Text string `json:"text,omitempty"`
6664
6665	// ForceSendFields is a list of field names (e.g. "EntityType") to
6666	// unconditionally include in API requests. By default, fields with
6667	// empty values are omitted from API requests. However, any non-pointer,
6668	// non-interface field appearing in ForceSendFields will be sent to the
6669	// server regardless of whether the field is empty or not. This may be
6670	// used to include empty fields in Patch requests.
6671	ForceSendFields []string `json:"-"`
6672
6673	// NullFields is a list of field names (e.g. "EntityType") to include in
6674	// API requests with the JSON null value. By default, fields with empty
6675	// values are omitted from API requests. However, any field with an
6676	// empty value appearing in NullFields will be sent to the server as
6677	// null. It is an error if a field in this list has a non-empty value.
6678	// This may be used to include null fields in Patch requests.
6679	NullFields []string `json:"-"`
6680}
6681
6682func (s *GoogleCloudDialogflowV2AnnotatedMessagePart) MarshalJSON() ([]byte, error) {
6683	type NoMethod GoogleCloudDialogflowV2AnnotatedMessagePart
6684	raw := NoMethod(*s)
6685	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6686}
6687
6688// GoogleCloudDialogflowV2AnswerFeedback: Represents feedback the
6689// customer has about the quality & correctness of a certain answer in a
6690// conversation.
6691type GoogleCloudDialogflowV2AnswerFeedback struct {
6692	// AgentAssistantDetailFeedback: Detail feedback of agent assist
6693	// suggestions.
6694	AgentAssistantDetailFeedback *GoogleCloudDialogflowV2AgentAssistantFeedback `json:"agentAssistantDetailFeedback,omitempty"`
6695
6696	// ClickTime: Time when the answer/item was clicked.
6697	ClickTime string `json:"clickTime,omitempty"`
6698
6699	// Clicked: Indicates whether the answer/item was clicked by the human
6700	// agent or not. Default to false.
6701	Clicked bool `json:"clicked,omitempty"`
6702
6703	// CorrectnessLevel: The correctness level of the specific answer.
6704	//
6705	// Possible values:
6706	//   "CORRECTNESS_LEVEL_UNSPECIFIED" - Correctness level unspecified.
6707	//   "NOT_CORRECT" - Answer is totally wrong.
6708	//   "PARTIALLY_CORRECT" - Answer is partially correct.
6709	//   "FULLY_CORRECT" - Answer is fully correct.
6710	CorrectnessLevel string `json:"correctnessLevel,omitempty"`
6711
6712	// DisplayTime: Time when the answer/item was displayed.
6713	DisplayTime string `json:"displayTime,omitempty"`
6714
6715	// Displayed: Indicates whether the answer/item was displayed to the
6716	// human agent in the agent desktop UI. Default to false.
6717	Displayed bool `json:"displayed,omitempty"`
6718
6719	// ForceSendFields is a list of field names (e.g.
6720	// "AgentAssistantDetailFeedback") to unconditionally include in API
6721	// requests. By default, fields with empty values are omitted from API
6722	// requests. However, any non-pointer, non-interface field appearing in
6723	// ForceSendFields will be sent to the server regardless of whether the
6724	// field is empty or not. This may be used to include empty fields in
6725	// Patch requests.
6726	ForceSendFields []string `json:"-"`
6727
6728	// NullFields is a list of field names (e.g.
6729	// "AgentAssistantDetailFeedback") to include in API requests with the
6730	// JSON null value. By default, fields with empty values are omitted
6731	// from API requests. However, any field with an empty value appearing
6732	// in NullFields will be sent to the server as null. It is an error if a
6733	// field in this list has a non-empty value. This may be used to include
6734	// null fields in Patch requests.
6735	NullFields []string `json:"-"`
6736}
6737
6738func (s *GoogleCloudDialogflowV2AnswerFeedback) MarshalJSON() ([]byte, error) {
6739	type NoMethod GoogleCloudDialogflowV2AnswerFeedback
6740	raw := NoMethod(*s)
6741	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6742}
6743
6744// GoogleCloudDialogflowV2AnswerRecord: Answer records are records to
6745// manage answer history and feedbacks for Dialogflow. Currently, answer
6746// record includes: - human agent assistant article suggestion - human
6747// agent assistant faq article It doesn't include: - `DetectIntent`
6748// intent matching - `DetectIntent` knowledge Answer records are not
6749// related to the conversation history in the Dialogflow Console. A
6750// Record is generated even when the end-user disables conversation
6751// history in the console. Records are created when there's a human
6752// agent assistant suggestion generated. A typical workflow for
6753// customers provide feedback to an answer is: 1. For human agent
6754// assistant, customers get suggestion via ListSuggestions API. Together
6755// with the answers, AnswerRecord.name are returned to the customers. 2.
6756// The customer uses the AnswerRecord.name to call the
6757// UpdateAnswerRecord method to send feedback about a specific answer
6758// that they believe is wrong.
6759type GoogleCloudDialogflowV2AnswerRecord struct {
6760	// AgentAssistantRecord: Output only. The record for human agent
6761	// assistant.
6762	AgentAssistantRecord *GoogleCloudDialogflowV2AgentAssistantRecord `json:"agentAssistantRecord,omitempty"`
6763
6764	// AnswerFeedback: Required. The AnswerFeedback for this record. You can
6765	// set this with AnswerRecords.UpdateAnswerRecord in order to give us
6766	// feedback about this answer.
6767	AnswerFeedback *GoogleCloudDialogflowV2AnswerFeedback `json:"answerFeedback,omitempty"`
6768
6769	// Name: The unique identifier of this answer record. Format:
6770	// `projects//locations//answerRecords/`.
6771	Name string `json:"name,omitempty"`
6772
6773	// ServerResponse contains the HTTP response code and headers from the
6774	// server.
6775	googleapi.ServerResponse `json:"-"`
6776
6777	// ForceSendFields is a list of field names (e.g.
6778	// "AgentAssistantRecord") to unconditionally include in API requests.
6779	// By default, fields with empty values are omitted from API requests.
6780	// However, any non-pointer, non-interface field appearing in
6781	// ForceSendFields will be sent to the server regardless of whether the
6782	// field is empty or not. This may be used to include empty fields in
6783	// Patch requests.
6784	ForceSendFields []string `json:"-"`
6785
6786	// NullFields is a list of field names (e.g. "AgentAssistantRecord") to
6787	// include in API requests with the JSON null value. By default, fields
6788	// with empty values are omitted from API requests. However, any field
6789	// with an empty value appearing in NullFields will be sent to the
6790	// server as null. It is an error if a field in this list has a
6791	// non-empty value. This may be used to include null fields in Patch
6792	// requests.
6793	NullFields []string `json:"-"`
6794}
6795
6796func (s *GoogleCloudDialogflowV2AnswerRecord) MarshalJSON() ([]byte, error) {
6797	type NoMethod GoogleCloudDialogflowV2AnswerRecord
6798	raw := NoMethod(*s)
6799	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6800}
6801
6802// GoogleCloudDialogflowV2ArticleAnswer: Represents article answer.
6803type GoogleCloudDialogflowV2ArticleAnswer struct {
6804	// AnswerRecord: The name of answer record, in the format of
6805	// "projects//locations//answerRecords/"
6806	AnswerRecord string `json:"answerRecord,omitempty"`
6807
6808	// Confidence: Article match confidence. The system's confidence score
6809	// that this article is a good match for this conversation, as a value
6810	// from 0.0 (completely uncertain) to 1.0 (completely certain).
6811	Confidence float64 `json:"confidence,omitempty"`
6812
6813	// Metadata: A map that contains metadata about the answer and the
6814	// document from which it originates.
6815	Metadata map[string]string `json:"metadata,omitempty"`
6816
6817	// Snippets: Article snippets.
6818	Snippets []string `json:"snippets,omitempty"`
6819
6820	// Title: The article title.
6821	Title string `json:"title,omitempty"`
6822
6823	// Uri: The article URI.
6824	Uri string `json:"uri,omitempty"`
6825
6826	// ForceSendFields is a list of field names (e.g. "AnswerRecord") to
6827	// unconditionally include in API requests. By default, fields with
6828	// empty values are omitted from API requests. However, any non-pointer,
6829	// non-interface field appearing in ForceSendFields will be sent to the
6830	// server regardless of whether the field is empty or not. This may be
6831	// used to include empty fields in Patch requests.
6832	ForceSendFields []string `json:"-"`
6833
6834	// NullFields is a list of field names (e.g. "AnswerRecord") to include
6835	// in API requests with the JSON null value. By default, fields with
6836	// empty values are omitted from API requests. However, any field with
6837	// an empty value appearing in NullFields will be sent to the server as
6838	// null. It is an error if a field in this list has a non-empty value.
6839	// This may be used to include null fields in Patch requests.
6840	NullFields []string `json:"-"`
6841}
6842
6843func (s *GoogleCloudDialogflowV2ArticleAnswer) MarshalJSON() ([]byte, error) {
6844	type NoMethod GoogleCloudDialogflowV2ArticleAnswer
6845	raw := NoMethod(*s)
6846	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6847}
6848
6849func (s *GoogleCloudDialogflowV2ArticleAnswer) UnmarshalJSON(data []byte) error {
6850	type NoMethod GoogleCloudDialogflowV2ArticleAnswer
6851	var s1 struct {
6852		Confidence gensupport.JSONFloat64 `json:"confidence"`
6853		*NoMethod
6854	}
6855	s1.NoMethod = (*NoMethod)(s)
6856	if err := json.Unmarshal(data, &s1); err != nil {
6857		return err
6858	}
6859	s.Confidence = float64(s1.Confidence)
6860	return nil
6861}
6862
6863// GoogleCloudDialogflowV2AutomatedAgentConfig: Defines the Automated
6864// Agent to connect to a conversation.
6865type GoogleCloudDialogflowV2AutomatedAgentConfig struct {
6866	// Agent: Required. ID of the Dialogflow agent environment to use. This
6867	// project needs to either be the same project as the conversation or
6868	// you need to grant
6869	// `service-@gcp-sa-dialogflow.iam.gserviceaccount.com` the `Dialogflow
6870	// API Service Agent` role in this project. Format:
6871	// `projects//locations//agent/environments/`. If environment is not
6872	// specified, the default `draft` environment is used. Refer to
6873	// DetectIntentRequest
6874	// (/dialogflow/docs/reference/rpc/google.cloud.dialogflow.v2#google.clou
6875	// d.dialogflow.v2.DetectIntentRequest) for more details.
6876	Agent string `json:"agent,omitempty"`
6877
6878	// ForceSendFields is a list of field names (e.g. "Agent") to
6879	// unconditionally include in API requests. By default, fields with
6880	// empty values are omitted from API requests. However, any non-pointer,
6881	// non-interface field appearing in ForceSendFields will be sent to the
6882	// server regardless of whether the field is empty or not. This may be
6883	// used to include empty fields in Patch requests.
6884	ForceSendFields []string `json:"-"`
6885
6886	// NullFields is a list of field names (e.g. "Agent") to include in API
6887	// requests with the JSON null value. By default, fields with empty
6888	// values are omitted from API requests. However, any field with an
6889	// empty value appearing in NullFields will be sent to the server as
6890	// null. It is an error if a field in this list has a non-empty value.
6891	// This may be used to include null fields in Patch requests.
6892	NullFields []string `json:"-"`
6893}
6894
6895func (s *GoogleCloudDialogflowV2AutomatedAgentConfig) MarshalJSON() ([]byte, error) {
6896	type NoMethod GoogleCloudDialogflowV2AutomatedAgentConfig
6897	raw := NoMethod(*s)
6898	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6899}
6900
6901// GoogleCloudDialogflowV2AutomatedAgentReply: Represents a response
6902// from an automated agent.
6903type GoogleCloudDialogflowV2AutomatedAgentReply struct {
6904	// DetectIntentResponse: Response of the Dialogflow
6905	// Sessions.DetectIntent call.
6906	DetectIntentResponse *GoogleCloudDialogflowV2DetectIntentResponse `json:"detectIntentResponse,omitempty"`
6907
6908	// ForceSendFields is a list of field names (e.g.
6909	// "DetectIntentResponse") to unconditionally include in API requests.
6910	// By default, fields with empty values are omitted from API requests.
6911	// However, any non-pointer, non-interface field appearing in
6912	// ForceSendFields will be sent to the server regardless of whether the
6913	// field is empty or not. This may be used to include empty fields in
6914	// Patch requests.
6915	ForceSendFields []string `json:"-"`
6916
6917	// NullFields is a list of field names (e.g. "DetectIntentResponse") to
6918	// include in API requests with the JSON null value. By default, fields
6919	// with empty values are omitted from API requests. However, any field
6920	// with an empty value appearing in NullFields will be sent to the
6921	// server as null. It is an error if a field in this list has a
6922	// non-empty value. This may be used to include null fields in Patch
6923	// requests.
6924	NullFields []string `json:"-"`
6925}
6926
6927func (s *GoogleCloudDialogflowV2AutomatedAgentReply) MarshalJSON() ([]byte, error) {
6928	type NoMethod GoogleCloudDialogflowV2AutomatedAgentReply
6929	raw := NoMethod(*s)
6930	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6931}
6932
6933// GoogleCloudDialogflowV2BatchCreateEntitiesRequest: The request
6934// message for EntityTypes.BatchCreateEntities.
6935type GoogleCloudDialogflowV2BatchCreateEntitiesRequest struct {
6936	// Entities: Required. The entities to create.
6937	Entities []*GoogleCloudDialogflowV2EntityTypeEntity `json:"entities,omitempty"`
6938
6939	// LanguageCode: Optional. The language used to access language-specific
6940	// data. If not specified, the agent's default language is used. For
6941	// more information, see Multilingual intent and entity data
6942	// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
6943	LanguageCode string `json:"languageCode,omitempty"`
6944
6945	// ForceSendFields is a list of field names (e.g. "Entities") to
6946	// unconditionally include in API requests. By default, fields with
6947	// empty values are omitted from API requests. However, any non-pointer,
6948	// non-interface field appearing in ForceSendFields will be sent to the
6949	// server regardless of whether the field is empty or not. This may be
6950	// used to include empty fields in Patch requests.
6951	ForceSendFields []string `json:"-"`
6952
6953	// NullFields is a list of field names (e.g. "Entities") to include in
6954	// API requests with the JSON null value. By default, fields with empty
6955	// values are omitted from API requests. However, any field with an
6956	// empty value appearing in NullFields will be sent to the server as
6957	// null. It is an error if a field in this list has a non-empty value.
6958	// This may be used to include null fields in Patch requests.
6959	NullFields []string `json:"-"`
6960}
6961
6962func (s *GoogleCloudDialogflowV2BatchCreateEntitiesRequest) MarshalJSON() ([]byte, error) {
6963	type NoMethod GoogleCloudDialogflowV2BatchCreateEntitiesRequest
6964	raw := NoMethod(*s)
6965	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6966}
6967
6968// GoogleCloudDialogflowV2BatchDeleteEntitiesRequest: The request
6969// message for EntityTypes.BatchDeleteEntities.
6970type GoogleCloudDialogflowV2BatchDeleteEntitiesRequest struct {
6971	// EntityValues: Required. The reference `values` of the entities to
6972	// delete. Note that these are not fully-qualified names, i.e. they
6973	// don't start with `projects/`.
6974	EntityValues []string `json:"entityValues,omitempty"`
6975
6976	// LanguageCode: Optional. The language used to access language-specific
6977	// data. If not specified, the agent's default language is used. For
6978	// more information, see Multilingual intent and entity data
6979	// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
6980	LanguageCode string `json:"languageCode,omitempty"`
6981
6982	// ForceSendFields is a list of field names (e.g. "EntityValues") to
6983	// unconditionally include in API requests. By default, fields with
6984	// empty values are omitted from API requests. However, any non-pointer,
6985	// non-interface field appearing in ForceSendFields will be sent to the
6986	// server regardless of whether the field is empty or not. This may be
6987	// used to include empty fields in Patch requests.
6988	ForceSendFields []string `json:"-"`
6989
6990	// NullFields is a list of field names (e.g. "EntityValues") to include
6991	// in API requests with the JSON null value. By default, fields with
6992	// empty values are omitted from API requests. However, any field with
6993	// an empty value appearing in NullFields will be sent to the server as
6994	// null. It is an error if a field in this list has a non-empty value.
6995	// This may be used to include null fields in Patch requests.
6996	NullFields []string `json:"-"`
6997}
6998
6999func (s *GoogleCloudDialogflowV2BatchDeleteEntitiesRequest) MarshalJSON() ([]byte, error) {
7000	type NoMethod GoogleCloudDialogflowV2BatchDeleteEntitiesRequest
7001	raw := NoMethod(*s)
7002	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7003}
7004
7005// GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest: The request
7006// message for EntityTypes.BatchDeleteEntityTypes.
7007type GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest struct {
7008	// EntityTypeNames: Required. The names entity types to delete. All
7009	// names must point to the same agent as `parent`.
7010	EntityTypeNames []string `json:"entityTypeNames,omitempty"`
7011
7012	// ForceSendFields is a list of field names (e.g. "EntityTypeNames") to
7013	// unconditionally include in API requests. By default, fields with
7014	// empty values are omitted from API requests. However, any non-pointer,
7015	// non-interface field appearing in ForceSendFields will be sent to the
7016	// server regardless of whether the field is empty or not. This may be
7017	// used to include empty fields in Patch requests.
7018	ForceSendFields []string `json:"-"`
7019
7020	// NullFields is a list of field names (e.g. "EntityTypeNames") to
7021	// include in API requests with the JSON null value. By default, fields
7022	// with empty values are omitted from API requests. However, any field
7023	// with an empty value appearing in NullFields will be sent to the
7024	// server as null. It is an error if a field in this list has a
7025	// non-empty value. This may be used to include null fields in Patch
7026	// requests.
7027	NullFields []string `json:"-"`
7028}
7029
7030func (s *GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest) MarshalJSON() ([]byte, error) {
7031	type NoMethod GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest
7032	raw := NoMethod(*s)
7033	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7034}
7035
7036// GoogleCloudDialogflowV2BatchDeleteIntentsRequest: The request message
7037// for Intents.BatchDeleteIntents.
7038type GoogleCloudDialogflowV2BatchDeleteIntentsRequest struct {
7039	// Intents: Required. The collection of intents to delete. Only intent
7040	// `name` must be filled in.
7041	Intents []*GoogleCloudDialogflowV2Intent `json:"intents,omitempty"`
7042
7043	// ForceSendFields is a list of field names (e.g. "Intents") to
7044	// unconditionally include in API requests. By default, fields with
7045	// empty values are omitted from API requests. However, any non-pointer,
7046	// non-interface field appearing in ForceSendFields will be sent to the
7047	// server regardless of whether the field is empty or not. This may be
7048	// used to include empty fields in Patch requests.
7049	ForceSendFields []string `json:"-"`
7050
7051	// NullFields is a list of field names (e.g. "Intents") to include in
7052	// API requests with the JSON null value. By default, fields with empty
7053	// values are omitted from API requests. However, any field with an
7054	// empty value appearing in NullFields will be sent to the server as
7055	// null. It is an error if a field in this list has a non-empty value.
7056	// This may be used to include null fields in Patch requests.
7057	NullFields []string `json:"-"`
7058}
7059
7060func (s *GoogleCloudDialogflowV2BatchDeleteIntentsRequest) MarshalJSON() ([]byte, error) {
7061	type NoMethod GoogleCloudDialogflowV2BatchDeleteIntentsRequest
7062	raw := NoMethod(*s)
7063	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7064}
7065
7066// GoogleCloudDialogflowV2BatchUpdateEntitiesRequest: The request
7067// message for EntityTypes.BatchUpdateEntities.
7068type GoogleCloudDialogflowV2BatchUpdateEntitiesRequest struct {
7069	// Entities: Required. The entities to update or create.
7070	Entities []*GoogleCloudDialogflowV2EntityTypeEntity `json:"entities,omitempty"`
7071
7072	// LanguageCode: Optional. The language used to access language-specific
7073	// data. If not specified, the agent's default language is used. For
7074	// more information, see Multilingual intent and entity data
7075	// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
7076	LanguageCode string `json:"languageCode,omitempty"`
7077
7078	// UpdateMask: Optional. The mask to control which fields get updated.
7079	UpdateMask string `json:"updateMask,omitempty"`
7080
7081	// ForceSendFields is a list of field names (e.g. "Entities") to
7082	// unconditionally include in API requests. By default, fields with
7083	// empty values are omitted from API requests. However, any non-pointer,
7084	// non-interface field appearing in ForceSendFields will be sent to the
7085	// server regardless of whether the field is empty or not. This may be
7086	// used to include empty fields in Patch requests.
7087	ForceSendFields []string `json:"-"`
7088
7089	// NullFields is a list of field names (e.g. "Entities") to include in
7090	// API requests with the JSON null value. By default, fields with empty
7091	// values are omitted from API requests. However, any field with an
7092	// empty value appearing in NullFields will be sent to the server as
7093	// null. It is an error if a field in this list has a non-empty value.
7094	// This may be used to include null fields in Patch requests.
7095	NullFields []string `json:"-"`
7096}
7097
7098func (s *GoogleCloudDialogflowV2BatchUpdateEntitiesRequest) MarshalJSON() ([]byte, error) {
7099	type NoMethod GoogleCloudDialogflowV2BatchUpdateEntitiesRequest
7100	raw := NoMethod(*s)
7101	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7102}
7103
7104// GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest: The request
7105// message for EntityTypes.BatchUpdateEntityTypes.
7106type GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest struct {
7107	// EntityTypeBatchInline: The collection of entity types to update or
7108	// create.
7109	EntityTypeBatchInline *GoogleCloudDialogflowV2EntityTypeBatch `json:"entityTypeBatchInline,omitempty"`
7110
7111	// EntityTypeBatchUri: The URI to a Google Cloud Storage file containing
7112	// entity types to update or create. The file format can either be a
7113	// serialized proto (of EntityBatch type) or a JSON object. Note: The
7114	// URI must start with "gs://".
7115	EntityTypeBatchUri string `json:"entityTypeBatchUri,omitempty"`
7116
7117	// LanguageCode: Optional. The language used to access language-specific
7118	// data. If not specified, the agent's default language is used. For
7119	// more information, see Multilingual intent and entity data
7120	// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
7121	LanguageCode string `json:"languageCode,omitempty"`
7122
7123	// UpdateMask: Optional. The mask to control which fields get updated.
7124	UpdateMask string `json:"updateMask,omitempty"`
7125
7126	// ForceSendFields is a list of field names (e.g.
7127	// "EntityTypeBatchInline") to unconditionally include in API requests.
7128	// By default, fields with empty values are omitted from API requests.
7129	// However, any non-pointer, non-interface field appearing in
7130	// ForceSendFields will be sent to the server regardless of whether the
7131	// field is empty or not. This may be used to include empty fields in
7132	// Patch requests.
7133	ForceSendFields []string `json:"-"`
7134
7135	// NullFields is a list of field names (e.g. "EntityTypeBatchInline") to
7136	// include in API requests with the JSON null value. By default, fields
7137	// with empty values are omitted from API requests. However, any field
7138	// with an empty value appearing in NullFields will be sent to the
7139	// server as null. It is an error if a field in this list has a
7140	// non-empty value. This may be used to include null fields in Patch
7141	// requests.
7142	NullFields []string `json:"-"`
7143}
7144
7145func (s *GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest) MarshalJSON() ([]byte, error) {
7146	type NoMethod GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest
7147	raw := NoMethod(*s)
7148	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7149}
7150
7151// GoogleCloudDialogflowV2BatchUpdateEntityTypesResponse: The response
7152// message for EntityTypes.BatchUpdateEntityTypes.
7153type GoogleCloudDialogflowV2BatchUpdateEntityTypesResponse struct {
7154	// EntityTypes: The collection of updated or created entity types.
7155	EntityTypes []*GoogleCloudDialogflowV2EntityType `json:"entityTypes,omitempty"`
7156
7157	// ForceSendFields is a list of field names (e.g. "EntityTypes") to
7158	// unconditionally include in API requests. By default, fields with
7159	// empty values are omitted from API requests. However, any non-pointer,
7160	// non-interface field appearing in ForceSendFields will be sent to the
7161	// server regardless of whether the field is empty or not. This may be
7162	// used to include empty fields in Patch requests.
7163	ForceSendFields []string `json:"-"`
7164
7165	// NullFields is a list of field names (e.g. "EntityTypes") to include
7166	// in API requests with the JSON null value. By default, fields with
7167	// empty values are omitted from API requests. However, any field with
7168	// an empty value appearing in NullFields will be sent to the server as
7169	// null. It is an error if a field in this list has a non-empty value.
7170	// This may be used to include null fields in Patch requests.
7171	NullFields []string `json:"-"`
7172}
7173
7174func (s *GoogleCloudDialogflowV2BatchUpdateEntityTypesResponse) MarshalJSON() ([]byte, error) {
7175	type NoMethod GoogleCloudDialogflowV2BatchUpdateEntityTypesResponse
7176	raw := NoMethod(*s)
7177	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7178}
7179
7180type GoogleCloudDialogflowV2BatchUpdateIntentsRequest struct {
7181	// IntentBatchInline: The collection of intents to update or create.
7182	IntentBatchInline *GoogleCloudDialogflowV2IntentBatch `json:"intentBatchInline,omitempty"`
7183
7184	// IntentBatchUri: The URI to a Google Cloud Storage file containing
7185	// intents to update or create. The file format can either be a
7186	// serialized proto (of IntentBatch type) or JSON object. Note: The URI
7187	// must start with "gs://".
7188	IntentBatchUri string `json:"intentBatchUri,omitempty"`
7189
7190	// IntentView: Optional. The resource view to apply to the returned
7191	// intent.
7192	//
7193	// Possible values:
7194	//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
7195	// in the response.
7196	//   "INTENT_VIEW_FULL" - All fields are populated.
7197	IntentView string `json:"intentView,omitempty"`
7198
7199	// LanguageCode: Optional. The language used to access language-specific
7200	// data. If not specified, the agent's default language is used. For
7201	// more information, see Multilingual intent and entity data
7202	// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
7203	LanguageCode string `json:"languageCode,omitempty"`
7204
7205	// UpdateMask: Optional. The mask to control which fields get updated.
7206	UpdateMask string `json:"updateMask,omitempty"`
7207
7208	// ForceSendFields is a list of field names (e.g. "IntentBatchInline")
7209	// to unconditionally include in API requests. By default, fields with
7210	// empty values are omitted from API requests. However, any non-pointer,
7211	// non-interface field appearing in ForceSendFields will be sent to the
7212	// server regardless of whether the field is empty or not. This may be
7213	// used to include empty fields in Patch requests.
7214	ForceSendFields []string `json:"-"`
7215
7216	// NullFields is a list of field names (e.g. "IntentBatchInline") to
7217	// include in API requests with the JSON null value. By default, fields
7218	// with empty values are omitted from API requests. However, any field
7219	// with an empty value appearing in NullFields will be sent to the
7220	// server as null. It is an error if a field in this list has a
7221	// non-empty value. This may be used to include null fields in Patch
7222	// requests.
7223	NullFields []string `json:"-"`
7224}
7225
7226func (s *GoogleCloudDialogflowV2BatchUpdateIntentsRequest) MarshalJSON() ([]byte, error) {
7227	type NoMethod GoogleCloudDialogflowV2BatchUpdateIntentsRequest
7228	raw := NoMethod(*s)
7229	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7230}
7231
7232// GoogleCloudDialogflowV2BatchUpdateIntentsResponse: The response
7233// message for Intents.BatchUpdateIntents.
7234type GoogleCloudDialogflowV2BatchUpdateIntentsResponse struct {
7235	// Intents: The collection of updated or created intents.
7236	Intents []*GoogleCloudDialogflowV2Intent `json:"intents,omitempty"`
7237
7238	// ForceSendFields is a list of field names (e.g. "Intents") to
7239	// unconditionally include in API requests. By default, fields with
7240	// empty values are omitted from API requests. However, any non-pointer,
7241	// non-interface field appearing in ForceSendFields will be sent to the
7242	// server regardless of whether the field is empty or not. This may be
7243	// used to include empty fields in Patch requests.
7244	ForceSendFields []string `json:"-"`
7245
7246	// NullFields is a list of field names (e.g. "Intents") to include in
7247	// API requests with the JSON null value. By default, fields with empty
7248	// values are omitted from API requests. However, any field with an
7249	// empty value appearing in NullFields will be sent to the server as
7250	// null. It is an error if a field in this list has a non-empty value.
7251	// This may be used to include null fields in Patch requests.
7252	NullFields []string `json:"-"`
7253}
7254
7255func (s *GoogleCloudDialogflowV2BatchUpdateIntentsResponse) MarshalJSON() ([]byte, error) {
7256	type NoMethod GoogleCloudDialogflowV2BatchUpdateIntentsResponse
7257	raw := NoMethod(*s)
7258	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7259}
7260
7261// GoogleCloudDialogflowV2CompleteConversationRequest: The request
7262// message for Conversations.CompleteConversation.
7263type GoogleCloudDialogflowV2CompleteConversationRequest struct {
7264}
7265
7266// GoogleCloudDialogflowV2Context: Dialogflow contexts are similar to
7267// natural language context. If a person says to you "they are orange",
7268// you need context in order to understand what "they" is referring to.
7269// Similarly, for Dialogflow to handle an end-user expression like that,
7270// it needs to be provided with context in order to correctly match an
7271// intent. Using contexts, you can control the flow of a conversation.
7272// You can configure contexts for an intent by setting input and output
7273// contexts, which are identified by string names. When an intent is
7274// matched, any configured output contexts for that intent become
7275// active. While any contexts are active, Dialogflow is more likely to
7276// match intents that are configured with input contexts that correspond
7277// to the currently active contexts. For more information about context,
7278// see the Contexts guide
7279// (https://cloud.google.com/dialogflow/docs/contexts-overview).
7280type GoogleCloudDialogflowV2Context struct {
7281	// LifespanCount: Optional. The number of conversational query requests
7282	// after which the context expires. The default is `0`. If set to `0`,
7283	// the context expires immediately. Contexts expire automatically after
7284	// 20 minutes if there are no matching queries.
7285	LifespanCount int64 `json:"lifespanCount,omitempty"`
7286
7287	// Name: Required. The unique identifier of the context. Format:
7288	// `projects//agent/sessions//contexts/`, or
7289	// `projects//agent/environments//users//sessions//contexts/`. The
7290	// `Context ID` is always converted to lowercase, may only contain
7291	// characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If
7292	// `Environment ID` is not specified, we assume default 'draft'
7293	// environment. If `User ID` is not specified, we assume default '-'
7294	// user. The following context names are reserved for internal use by
7295	// Dialogflow. You should not use these contexts or create contexts with
7296	// these names: * `__system_counters__` * `*_id_dialog_context` *
7297	// `*_dialog_params_size`
7298	Name string `json:"name,omitempty"`
7299
7300	// Parameters: Optional. The collection of parameters associated with
7301	// this context. Depending on your protocol or client library language,
7302	// this is a map, associative array, symbol table, dictionary, or JSON
7303	// object composed of a collection of (MapKey, MapValue) pairs: - MapKey
7304	// type: string - MapKey value: parameter name - MapValue type: - If
7305	// parameter's entity type is a composite entity: map - Else: depending
7306	// on parameter value type, could be one of string, number, boolean,
7307	// null, list or map - MapValue value: - If parameter's entity type is a
7308	// composite entity: map from composite entity property names to
7309	// property values - Else: parameter value
7310	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
7311
7312	// ServerResponse contains the HTTP response code and headers from the
7313	// server.
7314	googleapi.ServerResponse `json:"-"`
7315
7316	// ForceSendFields is a list of field names (e.g. "LifespanCount") to
7317	// unconditionally include in API requests. By default, fields with
7318	// empty values are omitted from API requests. However, any non-pointer,
7319	// non-interface field appearing in ForceSendFields will be sent to the
7320	// server regardless of whether the field is empty or not. This may be
7321	// used to include empty fields in Patch requests.
7322	ForceSendFields []string `json:"-"`
7323
7324	// NullFields is a list of field names (e.g. "LifespanCount") to include
7325	// in API requests with the JSON null value. By default, fields with
7326	// empty values are omitted from API requests. However, any field with
7327	// an empty value appearing in NullFields will be sent to the server as
7328	// null. It is an error if a field in this list has a non-empty value.
7329	// This may be used to include null fields in Patch requests.
7330	NullFields []string `json:"-"`
7331}
7332
7333func (s *GoogleCloudDialogflowV2Context) MarshalJSON() ([]byte, error) {
7334	type NoMethod GoogleCloudDialogflowV2Context
7335	raw := NoMethod(*s)
7336	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7337}
7338
7339// GoogleCloudDialogflowV2Conversation: Represents a conversation. A
7340// conversation is an interaction between an agent, including live
7341// agents and Dialogflow agents, and a support customer. Conversations
7342// can include phone calls and text-based chat sessions.
7343type GoogleCloudDialogflowV2Conversation struct {
7344	// ConversationProfile: Required. The Conversation Profile to be used to
7345	// configure this Conversation. This field cannot be updated. Format:
7346	// `projects//locations//conversationProfiles/`.
7347	ConversationProfile string `json:"conversationProfile,omitempty"`
7348
7349	// ConversationStage: The stage of a conversation. It indicates whether
7350	// the virtual agent or a human agent is handling the conversation. If
7351	// the conversation is created with the conversation profile that has
7352	// Dialogflow config set, defaults to
7353	// ConversationStage.VIRTUAL_AGENT_STAGE; Otherwise, defaults to
7354	// ConversationStage.HUMAN_ASSIST_STAGE. If the conversation is created
7355	// with the conversation profile that has Dialogflow config set but
7356	// explicitly sets conversation_stage to
7357	// ConversationStage.HUMAN_ASSIST_STAGE, it skips
7358	// ConversationStage.VIRTUAL_AGENT_STAGE stage and directly goes to
7359	// ConversationStage.HUMAN_ASSIST_STAGE.
7360	//
7361	// Possible values:
7362	//   "CONVERSATION_STAGE_UNSPECIFIED" - Unknown. Should never be used
7363	// after a conversation is successfully created.
7364	//   "VIRTUAL_AGENT_STAGE" - The conversation should return virtual
7365	// agent responses into the conversation.
7366	//   "HUMAN_ASSIST_STAGE" - The conversation should not provide
7367	// responses, just listen and provide suggestions.
7368	ConversationStage string `json:"conversationStage,omitempty"`
7369
7370	// EndTime: Output only. The time the conversation was finished.
7371	EndTime string `json:"endTime,omitempty"`
7372
7373	// LifecycleState: Output only. The current state of the Conversation.
7374	//
7375	// Possible values:
7376	//   "LIFECYCLE_STATE_UNSPECIFIED" - Unknown.
7377	//   "IN_PROGRESS" - Conversation is currently open for media analysis.
7378	//   "COMPLETED" - Conversation has been completed.
7379	LifecycleState string `json:"lifecycleState,omitempty"`
7380
7381	// Name: Output only. The unique identifier of this conversation.
7382	// Format: `projects//locations//conversations/`.
7383	Name string `json:"name,omitempty"`
7384
7385	// PhoneNumber: Output only. It will not be empty if the conversation is
7386	// to be connected over telephony.
7387	PhoneNumber *GoogleCloudDialogflowV2ConversationPhoneNumber `json:"phoneNumber,omitempty"`
7388
7389	// StartTime: Output only. The time the conversation was started.
7390	StartTime string `json:"startTime,omitempty"`
7391
7392	// ServerResponse contains the HTTP response code and headers from the
7393	// server.
7394	googleapi.ServerResponse `json:"-"`
7395
7396	// ForceSendFields is a list of field names (e.g. "ConversationProfile")
7397	// to unconditionally include in API requests. By default, fields with
7398	// empty values are omitted from API requests. However, any non-pointer,
7399	// non-interface field appearing in ForceSendFields will be sent to the
7400	// server regardless of whether the field is empty or not. This may be
7401	// used to include empty fields in Patch requests.
7402	ForceSendFields []string `json:"-"`
7403
7404	// NullFields is a list of field names (e.g. "ConversationProfile") to
7405	// include in API requests with the JSON null value. By default, fields
7406	// with empty values are omitted from API requests. However, any field
7407	// with an empty value appearing in NullFields will be sent to the
7408	// server as null. It is an error if a field in this list has a
7409	// non-empty value. This may be used to include null fields in Patch
7410	// requests.
7411	NullFields []string `json:"-"`
7412}
7413
7414func (s *GoogleCloudDialogflowV2Conversation) MarshalJSON() ([]byte, error) {
7415	type NoMethod GoogleCloudDialogflowV2Conversation
7416	raw := NoMethod(*s)
7417	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7418}
7419
7420// GoogleCloudDialogflowV2ConversationEvent: Represents a notification
7421// sent to Pub/Sub subscribers for conversation lifecycle events.
7422type GoogleCloudDialogflowV2ConversationEvent struct {
7423	// Conversation: The unique identifier of the conversation this
7424	// notification refers to. Format: `projects//conversations/`.
7425	Conversation string `json:"conversation,omitempty"`
7426
7427	// ErrorStatus: More detailed information about an error. Only set for
7428	// type UNRECOVERABLE_ERROR_IN_PHONE_CALL.
7429	ErrorStatus *GoogleRpcStatus `json:"errorStatus,omitempty"`
7430
7431	// NewMessagePayload: Payload of NEW_MESSAGE event.
7432	NewMessagePayload *GoogleCloudDialogflowV2Message `json:"newMessagePayload,omitempty"`
7433
7434	// Type: The type of the event that this notification refers to.
7435	//
7436	// Possible values:
7437	//   "TYPE_UNSPECIFIED" - Type not set.
7438	//   "CONVERSATION_STARTED" - A new conversation has been opened. This
7439	// is fired when a telephone call is answered, or a conversation is
7440	// created via the API.
7441	//   "CONVERSATION_FINISHED" - An existing conversation has closed. This
7442	// is fired when a telephone call is terminated, or a conversation is
7443	// closed via the API.
7444	//   "HUMAN_INTERVENTION_NEEDED" - An existing conversation has received
7445	// notification from Dialogflow that human intervention is required.
7446	//   "NEW_MESSAGE" - An existing conversation has received a new
7447	// message, either from API or telephony. It is configured in
7448	// ConversationProfile.new_message_event_notification_config
7449	//   "UNRECOVERABLE_ERROR" - Unrecoverable error during a telephone
7450	// call. In general non-recoverable errors only occur if something was
7451	// misconfigured in the ConversationProfile corresponding to the call.
7452	// After a non-recoverable error, Dialogflow may stop responding. We
7453	// don't fire this event: * in an API call because we can directly
7454	// return the error, or, * when we can recover from an error.
7455	Type string `json:"type,omitempty"`
7456
7457	// ForceSendFields is a list of field names (e.g. "Conversation") to
7458	// unconditionally include in API requests. By default, fields with
7459	// empty values are omitted from API requests. However, any non-pointer,
7460	// non-interface field appearing in ForceSendFields will be sent to the
7461	// server regardless of whether the field is empty or not. This may be
7462	// used to include empty fields in Patch requests.
7463	ForceSendFields []string `json:"-"`
7464
7465	// NullFields is a list of field names (e.g. "Conversation") to include
7466	// in API requests with the JSON null value. By default, fields with
7467	// empty values are omitted from API requests. However, any field with
7468	// an empty value appearing in NullFields will be sent to the server as
7469	// null. It is an error if a field in this list has a non-empty value.
7470	// This may be used to include null fields in Patch requests.
7471	NullFields []string `json:"-"`
7472}
7473
7474func (s *GoogleCloudDialogflowV2ConversationEvent) MarshalJSON() ([]byte, error) {
7475	type NoMethod GoogleCloudDialogflowV2ConversationEvent
7476	raw := NoMethod(*s)
7477	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7478}
7479
7480// GoogleCloudDialogflowV2ConversationPhoneNumber: Represents a phone
7481// number for telephony integration. It allows for connecting a
7482// particular conversation over telephony.
7483type GoogleCloudDialogflowV2ConversationPhoneNumber struct {
7484	// PhoneNumber: Output only. The phone number to connect to this
7485	// conversation.
7486	PhoneNumber string `json:"phoneNumber,omitempty"`
7487
7488	// ForceSendFields is a list of field names (e.g. "PhoneNumber") to
7489	// unconditionally include in API requests. By default, fields with
7490	// empty values are omitted from API requests. However, any non-pointer,
7491	// non-interface field appearing in ForceSendFields will be sent to the
7492	// server regardless of whether the field is empty or not. This may be
7493	// used to include empty fields in Patch requests.
7494	ForceSendFields []string `json:"-"`
7495
7496	// NullFields is a list of field names (e.g. "PhoneNumber") to include
7497	// in API requests with the JSON null value. By default, fields with
7498	// empty values are omitted from API requests. However, any field with
7499	// an empty value appearing in NullFields will be sent to the server as
7500	// null. It is an error if a field in this list has a non-empty value.
7501	// This may be used to include null fields in Patch requests.
7502	NullFields []string `json:"-"`
7503}
7504
7505func (s *GoogleCloudDialogflowV2ConversationPhoneNumber) MarshalJSON() ([]byte, error) {
7506	type NoMethod GoogleCloudDialogflowV2ConversationPhoneNumber
7507	raw := NoMethod(*s)
7508	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7509}
7510
7511// GoogleCloudDialogflowV2ConversationProfile: Defines the services to
7512// connect to incoming Dialogflow conversations.
7513type GoogleCloudDialogflowV2ConversationProfile struct {
7514	// AutomatedAgentConfig: Configuration for an automated agent to use
7515	// with this profile.
7516	AutomatedAgentConfig *GoogleCloudDialogflowV2AutomatedAgentConfig `json:"automatedAgentConfig,omitempty"`
7517
7518	// CreateTime: Output only. Create time of the conversation profile.
7519	CreateTime string `json:"createTime,omitempty"`
7520
7521	// DisplayName: Required. Human readable name for this profile. Max
7522	// length 1024 bytes.
7523	DisplayName string `json:"displayName,omitempty"`
7524
7525	// HumanAgentAssistantConfig: Configuration for agent assistance to use
7526	// with this profile.
7527	HumanAgentAssistantConfig *GoogleCloudDialogflowV2HumanAgentAssistantConfig `json:"humanAgentAssistantConfig,omitempty"`
7528
7529	// HumanAgentHandoffConfig: Configuration for connecting to a live
7530	// agent. Currently, this feature is not general available, please
7531	// contact Google to get access.
7532	HumanAgentHandoffConfig *GoogleCloudDialogflowV2HumanAgentHandoffConfig `json:"humanAgentHandoffConfig,omitempty"`
7533
7534	// LanguageCode: Language which represents the conversationProfile. If
7535	// unspecified, the default language code en-us applies. Users need to
7536	// create a ConversationProfile for each language they want to support.
7537	LanguageCode string `json:"languageCode,omitempty"`
7538
7539	// LoggingConfig: Configuration for logging conversation lifecycle
7540	// events.
7541	LoggingConfig *GoogleCloudDialogflowV2LoggingConfig `json:"loggingConfig,omitempty"`
7542
7543	// Name: The unique identifier of this conversation profile. Format:
7544	// `projects//locations//conversationProfiles/`.
7545	Name string `json:"name,omitempty"`
7546
7547	// NewMessageEventNotificationConfig: Configuration for publishing new
7548	// message events. Event will be sent in format of ConversationEvent
7549	NewMessageEventNotificationConfig *GoogleCloudDialogflowV2NotificationConfig `json:"newMessageEventNotificationConfig,omitempty"`
7550
7551	// NotificationConfig: Configuration for publishing conversation
7552	// lifecycle events.
7553	NotificationConfig *GoogleCloudDialogflowV2NotificationConfig `json:"notificationConfig,omitempty"`
7554
7555	// SttConfig: Settings for speech transcription.
7556	SttConfig *GoogleCloudDialogflowV2SpeechToTextConfig `json:"sttConfig,omitempty"`
7557
7558	// UpdateTime: Output only. Update time of the conversation profile.
7559	UpdateTime string `json:"updateTime,omitempty"`
7560
7561	// ServerResponse contains the HTTP response code and headers from the
7562	// server.
7563	googleapi.ServerResponse `json:"-"`
7564
7565	// ForceSendFields is a list of field names (e.g.
7566	// "AutomatedAgentConfig") to unconditionally include in API requests.
7567	// By default, fields with empty values are omitted from API requests.
7568	// However, any non-pointer, non-interface field appearing in
7569	// ForceSendFields will be sent to the server regardless of whether the
7570	// field is empty or not. This may be used to include empty fields in
7571	// Patch requests.
7572	ForceSendFields []string `json:"-"`
7573
7574	// NullFields is a list of field names (e.g. "AutomatedAgentConfig") to
7575	// include in API requests with the JSON null value. By default, fields
7576	// with empty values are omitted from API requests. However, any field
7577	// with an empty value appearing in NullFields will be sent to the
7578	// server as null. It is an error if a field in this list has a
7579	// non-empty value. This may be used to include null fields in Patch
7580	// requests.
7581	NullFields []string `json:"-"`
7582}
7583
7584func (s *GoogleCloudDialogflowV2ConversationProfile) MarshalJSON() ([]byte, error) {
7585	type NoMethod GoogleCloudDialogflowV2ConversationProfile
7586	raw := NoMethod(*s)
7587	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7588}
7589
7590// GoogleCloudDialogflowV2DetectIntentRequest: The request to detect
7591// user's intent.
7592type GoogleCloudDialogflowV2DetectIntentRequest struct {
7593	// InputAudio: The natural language speech audio to be processed. This
7594	// field should be populated iff `query_input` is set to an input audio
7595	// config. A single request can contain up to 1 minute of speech audio
7596	// data.
7597	InputAudio string `json:"inputAudio,omitempty"`
7598
7599	// OutputAudioConfig: Instructs the speech synthesizer how to generate
7600	// the output audio. If this field is not set and agent-level speech
7601	// synthesizer is not configured, no output audio is generated.
7602	OutputAudioConfig *GoogleCloudDialogflowV2OutputAudioConfig `json:"outputAudioConfig,omitempty"`
7603
7604	// OutputAudioConfigMask: Mask for output_audio_config indicating which
7605	// settings in this request-level config should override speech
7606	// synthesizer settings defined at agent-level. If unspecified or empty,
7607	// output_audio_config replaces the agent-level config in its entirety.
7608	OutputAudioConfigMask string `json:"outputAudioConfigMask,omitempty"`
7609
7610	// QueryInput: Required. The input specification. It can be set to: 1.
7611	// an audio config which instructs the speech recognizer how to process
7612	// the speech audio, 2. a conversational query in the form of text, or
7613	// 3. an event that specifies which intent to trigger.
7614	QueryInput *GoogleCloudDialogflowV2QueryInput `json:"queryInput,omitempty"`
7615
7616	// QueryParams: The parameters of this query.
7617	QueryParams *GoogleCloudDialogflowV2QueryParameters `json:"queryParams,omitempty"`
7618
7619	// ForceSendFields is a list of field names (e.g. "InputAudio") to
7620	// unconditionally include in API requests. By default, fields with
7621	// empty values are omitted from API requests. However, any non-pointer,
7622	// non-interface field appearing in ForceSendFields will be sent to the
7623	// server regardless of whether the field is empty or not. This may be
7624	// used to include empty fields in Patch requests.
7625	ForceSendFields []string `json:"-"`
7626
7627	// NullFields is a list of field names (e.g. "InputAudio") to include in
7628	// API requests with the JSON null value. By default, fields with empty
7629	// values are omitted from API requests. However, any field with an
7630	// empty value appearing in NullFields will be sent to the server as
7631	// null. It is an error if a field in this list has a non-empty value.
7632	// This may be used to include null fields in Patch requests.
7633	NullFields []string `json:"-"`
7634}
7635
7636func (s *GoogleCloudDialogflowV2DetectIntentRequest) MarshalJSON() ([]byte, error) {
7637	type NoMethod GoogleCloudDialogflowV2DetectIntentRequest
7638	raw := NoMethod(*s)
7639	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7640}
7641
7642// GoogleCloudDialogflowV2DetectIntentResponse: The message returned
7643// from the DetectIntent method.
7644type GoogleCloudDialogflowV2DetectIntentResponse struct {
7645	// OutputAudio: The audio data bytes encoded as specified in the
7646	// request. Note: The output audio is generated based on the values of
7647	// default platform text responses found in the
7648	// `query_result.fulfillment_messages` field. If multiple default text
7649	// responses exist, they will be concatenated when generating audio. If
7650	// no default platform text responses exist, the generated audio content
7651	// will be empty. In some scenarios, multiple output audio fields may be
7652	// present in the response structure. In these cases, only the
7653	// top-most-level audio output has content.
7654	OutputAudio string `json:"outputAudio,omitempty"`
7655
7656	// OutputAudioConfig: The config used by the speech synthesizer to
7657	// generate the output audio.
7658	OutputAudioConfig *GoogleCloudDialogflowV2OutputAudioConfig `json:"outputAudioConfig,omitempty"`
7659
7660	// QueryResult: The selected results of the conversational query or
7661	// event processing. See `alternative_query_results` for additional
7662	// potential results.
7663	QueryResult *GoogleCloudDialogflowV2QueryResult `json:"queryResult,omitempty"`
7664
7665	// ResponseId: The unique identifier of the response. It can be used to
7666	// locate a response in the training example set or for reporting
7667	// issues.
7668	ResponseId string `json:"responseId,omitempty"`
7669
7670	// WebhookStatus: Specifies the status of the webhook request.
7671	WebhookStatus *GoogleRpcStatus `json:"webhookStatus,omitempty"`
7672
7673	// ServerResponse contains the HTTP response code and headers from the
7674	// server.
7675	googleapi.ServerResponse `json:"-"`
7676
7677	// ForceSendFields is a list of field names (e.g. "OutputAudio") to
7678	// unconditionally include in API requests. By default, fields with
7679	// empty values are omitted from API requests. However, any non-pointer,
7680	// non-interface field appearing in ForceSendFields will be sent to the
7681	// server regardless of whether the field is empty or not. This may be
7682	// used to include empty fields in Patch requests.
7683	ForceSendFields []string `json:"-"`
7684
7685	// NullFields is a list of field names (e.g. "OutputAudio") to include
7686	// in API requests with the JSON null value. By default, fields with
7687	// empty values are omitted from API requests. However, any field with
7688	// an empty value appearing in NullFields will be sent to the server as
7689	// null. It is an error if a field in this list has a non-empty value.
7690	// This may be used to include null fields in Patch requests.
7691	NullFields []string `json:"-"`
7692}
7693
7694func (s *GoogleCloudDialogflowV2DetectIntentResponse) MarshalJSON() ([]byte, error) {
7695	type NoMethod GoogleCloudDialogflowV2DetectIntentResponse
7696	raw := NoMethod(*s)
7697	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7698}
7699
7700// GoogleCloudDialogflowV2Document: A knowledge document to be used by a
7701// KnowledgeBase. For more information, see the knowledge base guide
7702// (https://cloud.google.com/dialogflow/docs/how/knowledge-bases). Note:
7703// The `projects.agent.knowledgeBases.documents` resource is deprecated;
7704// only use `projects.knowledgeBases.documents`.
7705type GoogleCloudDialogflowV2Document struct {
7706	// ContentUri: The URI where the file content is located. For documents
7707	// stored in Google Cloud Storage, these URIs must have the form
7708	// `gs:///`. NOTE: External URLs must correspond to public webpages,
7709	// i.e., they must be indexed by Google Search. In particular, URLs for
7710	// showing documents in Google Cloud Storage (i.e. the URL in your
7711	// browser) are not supported. Instead use the `gs://` format URI
7712	// described above.
7713	ContentUri string `json:"contentUri,omitempty"`
7714
7715	// DisplayName: Required. The display name of the document. The name
7716	// must be 1024 bytes or less; otherwise, the creation request fails.
7717	DisplayName string `json:"displayName,omitempty"`
7718
7719	// EnableAutoReload: Optional. If true, we try to automatically reload
7720	// the document every day (at a time picked by the system). If false or
7721	// unspecified, we don't try to automatically reload the document.
7722	// Currently you can only enable automatic reload for documents sourced
7723	// from a public url, see `source` field for the source types. Reload
7724	// status can be tracked in `latest_reload_status`. If a reload fails,
7725	// we will keep the document unchanged. If a reload fails with internal
7726	// errors, the system will try to reload the document on the next day.
7727	// If a reload fails with non-retriable errors (e.g. PERMISION_DENIED),
7728	// the system will not try to reload the document anymore. You need to
7729	// manually reload the document successfully by calling `ReloadDocument`
7730	// and clear the errors.
7731	EnableAutoReload bool `json:"enableAutoReload,omitempty"`
7732
7733	// KnowledgeTypes: Required. The knowledge type of document content.
7734	//
7735	// Possible values:
7736	//   "KNOWLEDGE_TYPE_UNSPECIFIED" - The type is unspecified or
7737	// arbitrary.
7738	//   "FAQ" - The document content contains question and answer pairs as
7739	// either HTML or CSV. Typical FAQ HTML formats are parsed accurately,
7740	// but unusual formats may fail to be parsed. CSV must have questions in
7741	// the first column and answers in the second, with no header. Because
7742	// of this explicit format, they are always parsed accurately.
7743	//   "EXTRACTIVE_QA" - Documents for which unstructured text is
7744	// extracted and used for question answering.
7745	//   "ARTICLE_SUGGESTION" - The entire document content as a whole can
7746	// be used for query results. Only for Contact Center Solutions on
7747	// Dialogflow.
7748	KnowledgeTypes []string `json:"knowledgeTypes,omitempty"`
7749
7750	// LatestReloadStatus: Output only. The time and status of the latest
7751	// reload. This reload may have been triggered automatically or manually
7752	// and may not have succeeded.
7753	LatestReloadStatus *GoogleCloudDialogflowV2DocumentReloadStatus `json:"latestReloadStatus,omitempty"`
7754
7755	// Metadata: Optional. Metadata for the document. The metadata supports
7756	// arbitrary key-value pairs. Suggested use cases include storing a
7757	// document's title, an external URL distinct from the document's
7758	// content_uri, etc. The max size of a `key` or a `value` of the
7759	// metadata is 1024 bytes.
7760	Metadata map[string]string `json:"metadata,omitempty"`
7761
7762	// MimeType: Required. The MIME type of this document.
7763	MimeType string `json:"mimeType,omitempty"`
7764
7765	// Name: Optional. The document resource name. The name must be empty
7766	// when creating a document. Format:
7767	// `projects//locations//knowledgeBases//documents/`.
7768	Name string `json:"name,omitempty"`
7769
7770	// RawContent: The raw content of the document. This field is only
7771	// permitted for EXTRACTIVE_QA and FAQ knowledge types.
7772	RawContent string `json:"rawContent,omitempty"`
7773
7774	// ServerResponse contains the HTTP response code and headers from the
7775	// server.
7776	googleapi.ServerResponse `json:"-"`
7777
7778	// ForceSendFields is a list of field names (e.g. "ContentUri") to
7779	// unconditionally include in API requests. By default, fields with
7780	// empty values are omitted from API requests. However, any non-pointer,
7781	// non-interface field appearing in ForceSendFields will be sent to the
7782	// server regardless of whether the field is empty or not. This may be
7783	// used to include empty fields in Patch requests.
7784	ForceSendFields []string `json:"-"`
7785
7786	// NullFields is a list of field names (e.g. "ContentUri") to include in
7787	// API requests with the JSON null value. By default, fields with empty
7788	// values are omitted from API requests. However, any field with an
7789	// empty value appearing in NullFields will be sent to the server as
7790	// null. It is an error if a field in this list has a non-empty value.
7791	// This may be used to include null fields in Patch requests.
7792	NullFields []string `json:"-"`
7793}
7794
7795func (s *GoogleCloudDialogflowV2Document) MarshalJSON() ([]byte, error) {
7796	type NoMethod GoogleCloudDialogflowV2Document
7797	raw := NoMethod(*s)
7798	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7799}
7800
7801// GoogleCloudDialogflowV2DocumentReloadStatus: The status of a reload
7802// attempt.
7803type GoogleCloudDialogflowV2DocumentReloadStatus struct {
7804	// Status: The status of a reload attempt or the initial load.
7805	Status *GoogleRpcStatus `json:"status,omitempty"`
7806
7807	// Time: The time of a reload attempt. This reload may have been
7808	// triggered automatically or manually and may not have succeeded.
7809	Time string `json:"time,omitempty"`
7810
7811	// ForceSendFields is a list of field names (e.g. "Status") to
7812	// unconditionally include in API requests. By default, fields with
7813	// empty values are omitted from API requests. However, any non-pointer,
7814	// non-interface field appearing in ForceSendFields will be sent to the
7815	// server regardless of whether the field is empty or not. This may be
7816	// used to include empty fields in Patch requests.
7817	ForceSendFields []string `json:"-"`
7818
7819	// NullFields is a list of field names (e.g. "Status") to include in API
7820	// requests with the JSON null value. By default, fields with empty
7821	// values are omitted from API requests. However, any field with an
7822	// empty value appearing in NullFields will be sent to the server as
7823	// null. It is an error if a field in this list has a non-empty value.
7824	// This may be used to include null fields in Patch requests.
7825	NullFields []string `json:"-"`
7826}
7827
7828func (s *GoogleCloudDialogflowV2DocumentReloadStatus) MarshalJSON() ([]byte, error) {
7829	type NoMethod GoogleCloudDialogflowV2DocumentReloadStatus
7830	raw := NoMethod(*s)
7831	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7832}
7833
7834// GoogleCloudDialogflowV2DtmfParameters: The message in the response
7835// that indicates the parameters of DTMF.
7836type GoogleCloudDialogflowV2DtmfParameters struct {
7837	// AcceptsDtmfInput: Indicates whether DTMF input can be handled in the
7838	// next request.
7839	AcceptsDtmfInput bool `json:"acceptsDtmfInput,omitempty"`
7840
7841	// ForceSendFields is a list of field names (e.g. "AcceptsDtmfInput") to
7842	// unconditionally include in API requests. By default, fields with
7843	// empty values are omitted from API requests. However, any non-pointer,
7844	// non-interface field appearing in ForceSendFields will be sent to the
7845	// server regardless of whether the field is empty or not. This may be
7846	// used to include empty fields in Patch requests.
7847	ForceSendFields []string `json:"-"`
7848
7849	// NullFields is a list of field names (e.g. "AcceptsDtmfInput") to
7850	// include in API requests with the JSON null value. By default, fields
7851	// with empty values are omitted from API requests. However, any field
7852	// with an empty value appearing in NullFields will be sent to the
7853	// server as null. It is an error if a field in this list has a
7854	// non-empty value. This may be used to include null fields in Patch
7855	// requests.
7856	NullFields []string `json:"-"`
7857}
7858
7859func (s *GoogleCloudDialogflowV2DtmfParameters) MarshalJSON() ([]byte, error) {
7860	type NoMethod GoogleCloudDialogflowV2DtmfParameters
7861	raw := NoMethod(*s)
7862	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7863}
7864
7865// GoogleCloudDialogflowV2EntityType: Each intent parameter has a type,
7866// called the entity type, which dictates exactly how data from an
7867// end-user expression is extracted. Dialogflow provides predefined
7868// system entities that can match many common types of data. For
7869// example, there are system entities for matching dates, times, colors,
7870// email addresses, and so on. You can also create your own custom
7871// entities for matching custom data. For example, you could define a
7872// vegetable entity that can match the types of vegetables available for
7873// purchase with a grocery store agent. For more information, see the
7874// Entity guide
7875// (https://cloud.google.com/dialogflow/docs/entities-overview).
7876type GoogleCloudDialogflowV2EntityType struct {
7877	// AutoExpansionMode: Optional. Indicates whether the entity type can be
7878	// automatically expanded.
7879	//
7880	// Possible values:
7881	//   "AUTO_EXPANSION_MODE_UNSPECIFIED" - Auto expansion disabled for the
7882	// entity.
7883	//   "AUTO_EXPANSION_MODE_DEFAULT" - Allows an agent to recognize values
7884	// that have not been explicitly listed in the entity.
7885	AutoExpansionMode string `json:"autoExpansionMode,omitempty"`
7886
7887	// DisplayName: Required. The name of the entity type.
7888	DisplayName string `json:"displayName,omitempty"`
7889
7890	// EnableFuzzyExtraction: Optional. Enables fuzzy entity extraction
7891	// during classification.
7892	EnableFuzzyExtraction bool `json:"enableFuzzyExtraction,omitempty"`
7893
7894	// Entities: Optional. The collection of entity entries associated with
7895	// the entity type.
7896	Entities []*GoogleCloudDialogflowV2EntityTypeEntity `json:"entities,omitempty"`
7897
7898	// Kind: Required. Indicates the kind of entity type.
7899	//
7900	// Possible values:
7901	//   "KIND_UNSPECIFIED" - Not specified. This value should be never
7902	// used.
7903	//   "KIND_MAP" - Map entity types allow mapping of a group of synonyms
7904	// to a reference value.
7905	//   "KIND_LIST" - List entity types contain a set of entries that do
7906	// not map to reference values. However, list entity types can contain
7907	// references to other entity types (with or without aliases).
7908	//   "KIND_REGEXP" - Regexp entity types allow to specify regular
7909	// expressions in entries values.
7910	Kind string `json:"kind,omitempty"`
7911
7912	// Name: The unique identifier of the entity type. Required for
7913	// EntityTypes.UpdateEntityType and EntityTypes.BatchUpdateEntityTypes
7914	// methods. Format: `projects//agent/entityTypes/`.
7915	Name string `json:"name,omitempty"`
7916
7917	// ServerResponse contains the HTTP response code and headers from the
7918	// server.
7919	googleapi.ServerResponse `json:"-"`
7920
7921	// ForceSendFields is a list of field names (e.g. "AutoExpansionMode")
7922	// to unconditionally include in API requests. By default, fields with
7923	// empty values are omitted from API requests. However, any non-pointer,
7924	// non-interface field appearing in ForceSendFields will be sent to the
7925	// server regardless of whether the field is empty or not. This may be
7926	// used to include empty fields in Patch requests.
7927	ForceSendFields []string `json:"-"`
7928
7929	// NullFields is a list of field names (e.g. "AutoExpansionMode") to
7930	// include in API requests with the JSON null value. By default, fields
7931	// with empty values are omitted from API requests. However, any field
7932	// with an empty value appearing in NullFields will be sent to the
7933	// server as null. It is an error if a field in this list has a
7934	// non-empty value. This may be used to include null fields in Patch
7935	// requests.
7936	NullFields []string `json:"-"`
7937}
7938
7939func (s *GoogleCloudDialogflowV2EntityType) MarshalJSON() ([]byte, error) {
7940	type NoMethod GoogleCloudDialogflowV2EntityType
7941	raw := NoMethod(*s)
7942	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7943}
7944
7945// GoogleCloudDialogflowV2EntityTypeBatch: This message is a wrapper
7946// around a collection of entity types.
7947type GoogleCloudDialogflowV2EntityTypeBatch struct {
7948	// EntityTypes: A collection of entity types.
7949	EntityTypes []*GoogleCloudDialogflowV2EntityType `json:"entityTypes,omitempty"`
7950
7951	// ForceSendFields is a list of field names (e.g. "EntityTypes") to
7952	// unconditionally include in API requests. By default, fields with
7953	// empty values are omitted from API requests. However, any non-pointer,
7954	// non-interface field appearing in ForceSendFields will be sent to the
7955	// server regardless of whether the field is empty or not. This may be
7956	// used to include empty fields in Patch requests.
7957	ForceSendFields []string `json:"-"`
7958
7959	// NullFields is a list of field names (e.g. "EntityTypes") to include
7960	// in API requests with the JSON null value. By default, fields with
7961	// empty values are omitted from API requests. However, any field with
7962	// an empty value appearing in NullFields will be sent to the server as
7963	// null. It is an error if a field in this list has a non-empty value.
7964	// This may be used to include null fields in Patch requests.
7965	NullFields []string `json:"-"`
7966}
7967
7968func (s *GoogleCloudDialogflowV2EntityTypeBatch) MarshalJSON() ([]byte, error) {
7969	type NoMethod GoogleCloudDialogflowV2EntityTypeBatch
7970	raw := NoMethod(*s)
7971	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7972}
7973
7974// GoogleCloudDialogflowV2EntityTypeEntity: An **entity entry** for an
7975// associated entity type.
7976type GoogleCloudDialogflowV2EntityTypeEntity struct {
7977	// Synonyms: Required. A collection of value synonyms. For example, if
7978	// the entity type is *vegetable*, and `value` is *scallions*, a synonym
7979	// could be *green onions*. For `KIND_LIST` entity types: * This
7980	// collection must contain exactly one synonym equal to `value`.
7981	Synonyms []string `json:"synonyms,omitempty"`
7982
7983	// Value: Required. The primary value associated with this entity entry.
7984	// For example, if the entity type is *vegetable*, the value could be
7985	// *scallions*. For `KIND_MAP` entity types: * A reference value to be
7986	// used in place of synonyms. For `KIND_LIST` entity types: * A string
7987	// that can contain references to other entity types (with or without
7988	// aliases).
7989	Value string `json:"value,omitempty"`
7990
7991	// ForceSendFields is a list of field names (e.g. "Synonyms") to
7992	// unconditionally include in API requests. By default, fields with
7993	// empty values are omitted from API requests. However, any non-pointer,
7994	// non-interface field appearing in ForceSendFields will be sent to the
7995	// server regardless of whether the field is empty or not. This may be
7996	// used to include empty fields in Patch requests.
7997	ForceSendFields []string `json:"-"`
7998
7999	// NullFields is a list of field names (e.g. "Synonyms") to include in
8000	// API requests with the JSON null value. By default, fields with empty
8001	// values are omitted from API requests. However, any field with an
8002	// empty value appearing in NullFields will be sent to the server as
8003	// null. It is an error if a field in this list has a non-empty value.
8004	// This may be used to include null fields in Patch requests.
8005	NullFields []string `json:"-"`
8006}
8007
8008func (s *GoogleCloudDialogflowV2EntityTypeEntity) MarshalJSON() ([]byte, error) {
8009	type NoMethod GoogleCloudDialogflowV2EntityTypeEntity
8010	raw := NoMethod(*s)
8011	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8012}
8013
8014// GoogleCloudDialogflowV2Environment: You can create multiple versions
8015// of your agent and publish them to separate environments. When you
8016// edit an agent, you are editing the draft agent. At any point, you can
8017// save the draft agent as an agent version, which is an immutable
8018// snapshot of your agent. When you save the draft agent, it is
8019// published to the default environment. When you create agent versions,
8020// you can publish them to custom environments. You can create a variety
8021// of custom environments for: - testing - development - production -
8022// etc. For more information, see the versions and environments guide
8023// (https://cloud.google.com/dialogflow/docs/agents-versions).
8024type GoogleCloudDialogflowV2Environment struct {
8025	// AgentVersion: Optional. The agent version loaded into this
8026	// environment. Format: `projects//agent/versions/`.
8027	AgentVersion string `json:"agentVersion,omitempty"`
8028
8029	// Description: Optional. The developer-provided description for this
8030	// environment. The maximum length is 500 characters. If exceeded, the
8031	// request is rejected.
8032	Description string `json:"description,omitempty"`
8033
8034	// Name: Output only. The unique identifier of this agent environment.
8035	// Format: `projects//agent/environments/`. For Environment ID, "-" is
8036	// reserved for 'draft' environment.
8037	Name string `json:"name,omitempty"`
8038
8039	// State: Output only. The state of this environment. This field is
8040	// read-only, i.e., it cannot be set by create and update methods.
8041	//
8042	// Possible values:
8043	//   "STATE_UNSPECIFIED" - Not specified. This value is not used.
8044	//   "STOPPED" - Stopped.
8045	//   "LOADING" - Loading.
8046	//   "RUNNING" - Running.
8047	State string `json:"state,omitempty"`
8048
8049	// UpdateTime: Output only. The last update time of this environment.
8050	// This field is read-only, i.e., it cannot be set by create and update
8051	// methods.
8052	UpdateTime string `json:"updateTime,omitempty"`
8053
8054	// ForceSendFields is a list of field names (e.g. "AgentVersion") to
8055	// unconditionally include in API requests. By default, fields with
8056	// empty values are omitted from API requests. However, any non-pointer,
8057	// non-interface field appearing in ForceSendFields will be sent to the
8058	// server regardless of whether the field is empty or not. This may be
8059	// used to include empty fields in Patch requests.
8060	ForceSendFields []string `json:"-"`
8061
8062	// NullFields is a list of field names (e.g. "AgentVersion") to include
8063	// in API requests with the JSON null value. By default, fields with
8064	// empty values are omitted from API requests. However, any field with
8065	// an empty value appearing in NullFields will be sent to the server as
8066	// null. It is an error if a field in this list has a non-empty value.
8067	// This may be used to include null fields in Patch requests.
8068	NullFields []string `json:"-"`
8069}
8070
8071func (s *GoogleCloudDialogflowV2Environment) MarshalJSON() ([]byte, error) {
8072	type NoMethod GoogleCloudDialogflowV2Environment
8073	raw := NoMethod(*s)
8074	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8075}
8076
8077// GoogleCloudDialogflowV2EventInput: Events allow for matching intents
8078// by event name instead of the natural language input. For instance,
8079// input `` can trigger a personalized welcome response. The parameter
8080// `name` may be used by the agent in the response: "Hello
8081// #welcome_event.name! What can I do for you today?".
8082type GoogleCloudDialogflowV2EventInput struct {
8083	// LanguageCode: Required. The language of this query. See Language
8084	// Support (https://cloud.google.com/dialogflow/docs/reference/language)
8085	// for a list of the currently supported language codes. Note that
8086	// queries in the same session do not necessarily need to specify the
8087	// same language.
8088	LanguageCode string `json:"languageCode,omitempty"`
8089
8090	// Name: Required. The unique identifier of the event.
8091	Name string `json:"name,omitempty"`
8092
8093	// Parameters: The collection of parameters associated with the event.
8094	// Depending on your protocol or client library language, this is a map,
8095	// associative array, symbol table, dictionary, or JSON object composed
8096	// of a collection of (MapKey, MapValue) pairs: - MapKey type: string -
8097	// MapKey value: parameter name - MapValue type: - If parameter's entity
8098	// type is a composite entity: map - Else: depending on parameter value
8099	// type, could be one of string, number, boolean, null, list or map -
8100	// MapValue value: - If parameter's entity type is a composite entity:
8101	// map from composite entity property names to property values - Else:
8102	// parameter value
8103	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
8104
8105	// ForceSendFields is a list of field names (e.g. "LanguageCode") to
8106	// unconditionally include in API requests. By default, fields with
8107	// empty values are omitted from API requests. However, any non-pointer,
8108	// non-interface field appearing in ForceSendFields will be sent to the
8109	// server regardless of whether the field is empty or not. This may be
8110	// used to include empty fields in Patch requests.
8111	ForceSendFields []string `json:"-"`
8112
8113	// NullFields is a list of field names (e.g. "LanguageCode") to include
8114	// in API requests with the JSON null value. By default, fields with
8115	// empty values are omitted from API requests. However, any field with
8116	// an empty value appearing in NullFields will be sent to the server as
8117	// null. It is an error if a field in this list has a non-empty value.
8118	// This may be used to include null fields in Patch requests.
8119	NullFields []string `json:"-"`
8120}
8121
8122func (s *GoogleCloudDialogflowV2EventInput) MarshalJSON() ([]byte, error) {
8123	type NoMethod GoogleCloudDialogflowV2EventInput
8124	raw := NoMethod(*s)
8125	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8126}
8127
8128// GoogleCloudDialogflowV2ExportAgentRequest: The request message for
8129// Agents.ExportAgent.
8130type GoogleCloudDialogflowV2ExportAgentRequest struct {
8131	// AgentUri: Required. The Google Cloud Storage
8132	// (https://cloud.google.com/storage/docs/) URI to export the agent to.
8133	// The format of this URI must be `gs:///`. If left unspecified, the
8134	// serialized agent is returned inline.
8135	AgentUri string `json:"agentUri,omitempty"`
8136
8137	// ForceSendFields is a list of field names (e.g. "AgentUri") to
8138	// unconditionally include in API requests. By default, fields with
8139	// empty values are omitted from API requests. However, any non-pointer,
8140	// non-interface field appearing in ForceSendFields will be sent to the
8141	// server regardless of whether the field is empty or not. This may be
8142	// used to include empty fields in Patch requests.
8143	ForceSendFields []string `json:"-"`
8144
8145	// NullFields is a list of field names (e.g. "AgentUri") to include in
8146	// API requests with the JSON null value. By default, fields with empty
8147	// values are omitted from API requests. However, any field with an
8148	// empty value appearing in NullFields will be sent to the server as
8149	// null. It is an error if a field in this list has a non-empty value.
8150	// This may be used to include null fields in Patch requests.
8151	NullFields []string `json:"-"`
8152}
8153
8154func (s *GoogleCloudDialogflowV2ExportAgentRequest) MarshalJSON() ([]byte, error) {
8155	type NoMethod GoogleCloudDialogflowV2ExportAgentRequest
8156	raw := NoMethod(*s)
8157	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8158}
8159
8160// GoogleCloudDialogflowV2ExportAgentResponse: The response message for
8161// Agents.ExportAgent.
8162type GoogleCloudDialogflowV2ExportAgentResponse struct {
8163	// AgentContent: Zip compressed raw byte content for agent.
8164	AgentContent string `json:"agentContent,omitempty"`
8165
8166	// AgentUri: The URI to a file containing the exported agent. This field
8167	// is populated only if `agent_uri` is specified in
8168	// `ExportAgentRequest`.
8169	AgentUri string `json:"agentUri,omitempty"`
8170
8171	// ForceSendFields is a list of field names (e.g. "AgentContent") to
8172	// unconditionally include in API requests. By default, fields with
8173	// empty values are omitted from API requests. However, any non-pointer,
8174	// non-interface field appearing in ForceSendFields will be sent to the
8175	// server regardless of whether the field is empty or not. This may be
8176	// used to include empty fields in Patch requests.
8177	ForceSendFields []string `json:"-"`
8178
8179	// NullFields is a list of field names (e.g. "AgentContent") to include
8180	// in API requests with the JSON null value. By default, fields with
8181	// empty values are omitted from API requests. However, any field with
8182	// an empty value appearing in NullFields will be sent to the server as
8183	// null. It is an error if a field in this list has a non-empty value.
8184	// This may be used to include null fields in Patch requests.
8185	NullFields []string `json:"-"`
8186}
8187
8188func (s *GoogleCloudDialogflowV2ExportAgentResponse) MarshalJSON() ([]byte, error) {
8189	type NoMethod GoogleCloudDialogflowV2ExportAgentResponse
8190	raw := NoMethod(*s)
8191	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8192}
8193
8194// GoogleCloudDialogflowV2FaqAnswer: Represents answer from "frequently
8195// asked questions".
8196type GoogleCloudDialogflowV2FaqAnswer struct {
8197	// Answer: The piece of text from the `source` knowledge base document.
8198	Answer string `json:"answer,omitempty"`
8199
8200	// AnswerRecord: The name of answer record, in the format of
8201	// "projects//locations//answerRecords/"
8202	AnswerRecord string `json:"answerRecord,omitempty"`
8203
8204	// Confidence: The system's confidence score that this Knowledge answer
8205	// is a good match for this conversational query, range from 0.0
8206	// (completely uncertain) to 1.0 (completely certain).
8207	Confidence float64 `json:"confidence,omitempty"`
8208
8209	// Metadata: A map that contains metadata about the answer and the
8210	// document from which it originates.
8211	Metadata map[string]string `json:"metadata,omitempty"`
8212
8213	// Question: The corresponding FAQ question.
8214	Question string `json:"question,omitempty"`
8215
8216	// Source: Indicates which Knowledge Document this answer was extracted
8217	// from. Format:
8218	// `projects//locations//agent/knowledgeBases//documents/`.
8219	Source string `json:"source,omitempty"`
8220
8221	// ForceSendFields is a list of field names (e.g. "Answer") to
8222	// unconditionally include in API requests. By default, fields with
8223	// empty values are omitted from API requests. However, any non-pointer,
8224	// non-interface field appearing in ForceSendFields will be sent to the
8225	// server regardless of whether the field is empty or not. This may be
8226	// used to include empty fields in Patch requests.
8227	ForceSendFields []string `json:"-"`
8228
8229	// NullFields is a list of field names (e.g. "Answer") to include in API
8230	// requests with the JSON null value. By default, fields with empty
8231	// values are omitted from API requests. However, any field with an
8232	// empty value appearing in NullFields will be sent to the server as
8233	// null. It is an error if a field in this list has a non-empty value.
8234	// This may be used to include null fields in Patch requests.
8235	NullFields []string `json:"-"`
8236}
8237
8238func (s *GoogleCloudDialogflowV2FaqAnswer) MarshalJSON() ([]byte, error) {
8239	type NoMethod GoogleCloudDialogflowV2FaqAnswer
8240	raw := NoMethod(*s)
8241	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8242}
8243
8244func (s *GoogleCloudDialogflowV2FaqAnswer) UnmarshalJSON(data []byte) error {
8245	type NoMethod GoogleCloudDialogflowV2FaqAnswer
8246	var s1 struct {
8247		Confidence gensupport.JSONFloat64 `json:"confidence"`
8248		*NoMethod
8249	}
8250	s1.NoMethod = (*NoMethod)(s)
8251	if err := json.Unmarshal(data, &s1); err != nil {
8252		return err
8253	}
8254	s.Confidence = float64(s1.Confidence)
8255	return nil
8256}
8257
8258// GoogleCloudDialogflowV2Fulfillment: By default, your agent responds
8259// to a matched intent with a static response. As an alternative, you
8260// can provide a more dynamic response by using fulfillment. When you
8261// enable fulfillment for an intent, Dialogflow responds to that intent
8262// by calling a service that you define. For example, if an end-user
8263// wants to schedule a haircut on Friday, your service can check your
8264// database and respond to the end-user with availability information
8265// for Friday. For more information, see the fulfillment guide
8266// (https://cloud.google.com/dialogflow/docs/fulfillment-overview).
8267type GoogleCloudDialogflowV2Fulfillment struct {
8268	// DisplayName: Optional. The human-readable name of the fulfillment,
8269	// unique within the agent.
8270	DisplayName string `json:"displayName,omitempty"`
8271
8272	// Enabled: Optional. Whether fulfillment is enabled.
8273	Enabled bool `json:"enabled,omitempty"`
8274
8275	// Features: Optional. The field defines whether the fulfillment is
8276	// enabled for certain features.
8277	Features []*GoogleCloudDialogflowV2FulfillmentFeature `json:"features,omitempty"`
8278
8279	// GenericWebService: Configuration for a generic web service.
8280	GenericWebService *GoogleCloudDialogflowV2FulfillmentGenericWebService `json:"genericWebService,omitempty"`
8281
8282	// Name: Required. The unique identifier of the fulfillment. Format:
8283	// `projects//agent/fulfillment`.
8284	Name string `json:"name,omitempty"`
8285
8286	// ServerResponse contains the HTTP response code and headers from the
8287	// server.
8288	googleapi.ServerResponse `json:"-"`
8289
8290	// ForceSendFields is a list of field names (e.g. "DisplayName") to
8291	// unconditionally include in API requests. By default, fields with
8292	// empty values are omitted from API requests. However, any non-pointer,
8293	// non-interface field appearing in ForceSendFields will be sent to the
8294	// server regardless of whether the field is empty or not. This may be
8295	// used to include empty fields in Patch requests.
8296	ForceSendFields []string `json:"-"`
8297
8298	// NullFields is a list of field names (e.g. "DisplayName") to include
8299	// in API requests with the JSON null value. By default, fields with
8300	// empty values are omitted from API requests. However, any field with
8301	// an empty value appearing in NullFields will be sent to the server as
8302	// null. It is an error if a field in this list has a non-empty value.
8303	// This may be used to include null fields in Patch requests.
8304	NullFields []string `json:"-"`
8305}
8306
8307func (s *GoogleCloudDialogflowV2Fulfillment) MarshalJSON() ([]byte, error) {
8308	type NoMethod GoogleCloudDialogflowV2Fulfillment
8309	raw := NoMethod(*s)
8310	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8311}
8312
8313// GoogleCloudDialogflowV2FulfillmentFeature: Whether fulfillment is
8314// enabled for the specific feature.
8315type GoogleCloudDialogflowV2FulfillmentFeature struct {
8316	// Type: The type of the feature that enabled for fulfillment.
8317	//
8318	// Possible values:
8319	//   "TYPE_UNSPECIFIED" - Feature type not specified.
8320	//   "SMALLTALK" - Fulfillment is enabled for SmallTalk.
8321	Type string `json:"type,omitempty"`
8322
8323	// ForceSendFields is a list of field names (e.g. "Type") to
8324	// unconditionally include in API requests. By default, fields with
8325	// empty values are omitted from API requests. However, any non-pointer,
8326	// non-interface field appearing in ForceSendFields will be sent to the
8327	// server regardless of whether the field is empty or not. This may be
8328	// used to include empty fields in Patch requests.
8329	ForceSendFields []string `json:"-"`
8330
8331	// NullFields is a list of field names (e.g. "Type") to include in API
8332	// requests with the JSON null value. By default, fields with empty
8333	// values are omitted from API requests. However, any field with an
8334	// empty value appearing in NullFields will be sent to the server as
8335	// null. It is an error if a field in this list has a non-empty value.
8336	// This may be used to include null fields in Patch requests.
8337	NullFields []string `json:"-"`
8338}
8339
8340func (s *GoogleCloudDialogflowV2FulfillmentFeature) MarshalJSON() ([]byte, error) {
8341	type NoMethod GoogleCloudDialogflowV2FulfillmentFeature
8342	raw := NoMethod(*s)
8343	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8344}
8345
8346// GoogleCloudDialogflowV2FulfillmentGenericWebService: Represents
8347// configuration for a generic web service. Dialogflow supports two
8348// mechanisms for authentications: - Basic authentication with username
8349// and password. - Authentication with additional authentication
8350// headers. More information could be found at:
8351// https://cloud.google.com/dialogflow/docs/fulfillment-configure.
8352type GoogleCloudDialogflowV2FulfillmentGenericWebService struct {
8353	// IsCloudFunction: Optional. Indicates if generic web service is
8354	// created through Cloud Functions integration. Defaults to false.
8355	IsCloudFunction bool `json:"isCloudFunction,omitempty"`
8356
8357	// Password: Optional. The password for HTTP Basic authentication.
8358	Password string `json:"password,omitempty"`
8359
8360	// RequestHeaders: Optional. The HTTP request headers to send together
8361	// with fulfillment requests.
8362	RequestHeaders map[string]string `json:"requestHeaders,omitempty"`
8363
8364	// Uri: Required. The fulfillment URI for receiving POST requests. It
8365	// must use https protocol.
8366	Uri string `json:"uri,omitempty"`
8367
8368	// Username: Optional. The user name for HTTP Basic authentication.
8369	Username string `json:"username,omitempty"`
8370
8371	// ForceSendFields is a list of field names (e.g. "IsCloudFunction") to
8372	// unconditionally include in API requests. By default, fields with
8373	// empty values are omitted from API requests. However, any non-pointer,
8374	// non-interface field appearing in ForceSendFields will be sent to the
8375	// server regardless of whether the field is empty or not. This may be
8376	// used to include empty fields in Patch requests.
8377	ForceSendFields []string `json:"-"`
8378
8379	// NullFields is a list of field names (e.g. "IsCloudFunction") to
8380	// include in API requests with the JSON null value. By default, fields
8381	// with empty values are omitted from API requests. However, any field
8382	// with an empty value appearing in NullFields will be sent to the
8383	// server as null. It is an error if a field in this list has a
8384	// non-empty value. This may be used to include null fields in Patch
8385	// requests.
8386	NullFields []string `json:"-"`
8387}
8388
8389func (s *GoogleCloudDialogflowV2FulfillmentGenericWebService) MarshalJSON() ([]byte, error) {
8390	type NoMethod GoogleCloudDialogflowV2FulfillmentGenericWebService
8391	raw := NoMethod(*s)
8392	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8393}
8394
8395// GoogleCloudDialogflowV2HumanAgentAssistantConfig: Defines the Human
8396// Agent Assist to connect to a conversation.
8397type GoogleCloudDialogflowV2HumanAgentAssistantConfig struct {
8398	// EndUserSuggestionConfig: Configuration for agent assistance of end
8399	// user participant. Currently, this feature is not general available,
8400	// please contact Google to get access.
8401	EndUserSuggestionConfig *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig `json:"endUserSuggestionConfig,omitempty"`
8402
8403	// HumanAgentSuggestionConfig: Configuration for agent assistance of
8404	// human agent participant.
8405	HumanAgentSuggestionConfig *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig `json:"humanAgentSuggestionConfig,omitempty"`
8406
8407	// MessageAnalysisConfig: Configuration for message analysis.
8408	MessageAnalysisConfig *GoogleCloudDialogflowV2HumanAgentAssistantConfigMessageAnalysisConfig `json:"messageAnalysisConfig,omitempty"`
8409
8410	// NotificationConfig: Pub/Sub topic on which to publish new agent
8411	// assistant events.
8412	NotificationConfig *GoogleCloudDialogflowV2NotificationConfig `json:"notificationConfig,omitempty"`
8413
8414	// ForceSendFields is a list of field names (e.g.
8415	// "EndUserSuggestionConfig") to unconditionally include in API
8416	// requests. By default, fields with empty values are omitted from API
8417	// requests. However, any non-pointer, non-interface field appearing in
8418	// ForceSendFields will be sent to the server regardless of whether the
8419	// field is empty or not. This may be used to include empty fields in
8420	// Patch requests.
8421	ForceSendFields []string `json:"-"`
8422
8423	// NullFields is a list of field names (e.g. "EndUserSuggestionConfig")
8424	// to include in API requests with the JSON null value. By default,
8425	// fields with empty values are omitted from API requests. However, any
8426	// field with an empty value appearing in NullFields will be sent to the
8427	// server as null. It is an error if a field in this list has a
8428	// non-empty value. This may be used to include null fields in Patch
8429	// requests.
8430	NullFields []string `json:"-"`
8431}
8432
8433func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfig) MarshalJSON() ([]byte, error) {
8434	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfig
8435	raw := NoMethod(*s)
8436	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8437}
8438
8439// GoogleCloudDialogflowV2HumanAgentAssistantConfigConversationModelConfi
8440// g: Custom conversation models used in agent assist feature. Supported
8441// feature: ARTICLE_SUGGESTION, SMART_COMPOSE, SMART_REPLY.
8442type GoogleCloudDialogflowV2HumanAgentAssistantConfigConversationModelConfig struct {
8443	// Model: Required. Conversation model resource name. Format:
8444	// `projects//conversationModels/`.
8445	Model string `json:"model,omitempty"`
8446
8447	// ForceSendFields is a list of field names (e.g. "Model") to
8448	// unconditionally include in API requests. By default, fields with
8449	// empty values are omitted from API requests. However, any non-pointer,
8450	// non-interface field appearing in ForceSendFields will be sent to the
8451	// server regardless of whether the field is empty or not. This may be
8452	// used to include empty fields in Patch requests.
8453	ForceSendFields []string `json:"-"`
8454
8455	// NullFields is a list of field names (e.g. "Model") to include in API
8456	// requests with the JSON null value. By default, fields with empty
8457	// values are omitted from API requests. However, any field with an
8458	// empty value appearing in NullFields will be sent to the server as
8459	// null. It is an error if a field in this list has a non-empty value.
8460	// This may be used to include null fields in Patch requests.
8461	NullFields []string `json:"-"`
8462}
8463
8464func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigConversationModelConfig) MarshalJSON() ([]byte, error) {
8465	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigConversationModelConfig
8466	raw := NoMethod(*s)
8467	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8468}
8469
8470// GoogleCloudDialogflowV2HumanAgentAssistantConfigMessageAnalysisConfig:
8471//  Configuration for analyses to run on each conversation message.
8472type GoogleCloudDialogflowV2HumanAgentAssistantConfigMessageAnalysisConfig struct {
8473	// EnableEntityExtraction: Enable entity extraction in conversation
8474	// messages on agent assist stage
8475	// (https://cloud.google.com/dialogflow/priv/docs/contact-center/basics#stages).
8476	// If unspecified, defaults to false. Currently, this feature is not
8477	// general available, please contact Google to get access.
8478	EnableEntityExtraction bool `json:"enableEntityExtraction,omitempty"`
8479
8480	// EnableSentimentAnalysis: Enable sentiment analysis in conversation
8481	// messages on agent assist stage
8482	// (https://cloud.google.com/dialogflow/priv/docs/contact-center/basics#stages).
8483	// If unspecified, defaults to false. Sentiment analysis inspects user
8484	// input and identifies the prevailing subjective opinion, especially to
8485	// determine a user's attitude as positive, negative, or neutral:
8486	// https://cloud.google.com/natural-language/docs/basics#sentiment_analysis
8487	// For Participants.StreamingAnalyzeContent method, result will be in
8488	// StreamingAnalyzeContentResponse.message.SentimentAnalysisResult. For
8489	// Participants.AnalyzeContent method, result will be in
8490	// AnalyzeContentResponse.message.SentimentAnalysisResult For
8491	// Conversations.ListMessages method, result will be in
8492	// ListMessagesResponse.messages.SentimentAnalysisResult If Pub/Sub
8493	// notification is configured, result will be in
8494	// ConversationEvent.new_message_payload.SentimentAnalysisResult.
8495	EnableSentimentAnalysis bool `json:"enableSentimentAnalysis,omitempty"`
8496
8497	// ForceSendFields is a list of field names (e.g.
8498	// "EnableEntityExtraction") to unconditionally include in API requests.
8499	// By default, fields with empty values are omitted from API requests.
8500	// However, any non-pointer, non-interface field appearing in
8501	// ForceSendFields will be sent to the server regardless of whether the
8502	// field is empty or not. This may be used to include empty fields in
8503	// Patch requests.
8504	ForceSendFields []string `json:"-"`
8505
8506	// NullFields is a list of field names (e.g. "EnableEntityExtraction")
8507	// to include in API requests with the JSON null value. By default,
8508	// fields with empty values are omitted from API requests. However, any
8509	// field with an empty value appearing in NullFields will be sent to the
8510	// server as null. It is an error if a field in this list has a
8511	// non-empty value. This may be used to include null fields in Patch
8512	// requests.
8513	NullFields []string `json:"-"`
8514}
8515
8516func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigMessageAnalysisConfig) MarshalJSON() ([]byte, error) {
8517	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigMessageAnalysisConfig
8518	raw := NoMethod(*s)
8519	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8520}
8521
8522// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig:
8523// Detail human agent assistant config.
8524type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig struct {
8525	// FeatureConfigs: Configuration of different suggestion features. One
8526	// feature can have only one config.
8527	FeatureConfigs []*GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionFeatureConfig `json:"featureConfigs,omitempty"`
8528
8529	// GroupSuggestionResponses: If `group_suggestion_responses` is false,
8530	// and there are multiple `feature_configs` in `event based suggestion`
8531	// or StreamingAnalyzeContent, we will try to deliver suggestions to
8532	// customers as soon as we get new suggestion. Different type of
8533	// suggestions based on the same context will be in separate Pub/Sub
8534	// event or `StreamingAnalyzeContentResponse`. If
8535	// `group_suggestion_responses` set to true. All the suggestions to the
8536	// same participant based on the same context will be grouped into a
8537	// single Pub/Sub event or StreamingAnalyzeContentResponse.
8538	GroupSuggestionResponses bool `json:"groupSuggestionResponses,omitempty"`
8539
8540	// ForceSendFields is a list of field names (e.g. "FeatureConfigs") to
8541	// unconditionally include in API requests. By default, fields with
8542	// empty values are omitted from API requests. However, any non-pointer,
8543	// non-interface field appearing in ForceSendFields will be sent to the
8544	// server regardless of whether the field is empty or not. This may be
8545	// used to include empty fields in Patch requests.
8546	ForceSendFields []string `json:"-"`
8547
8548	// NullFields is a list of field names (e.g. "FeatureConfigs") to
8549	// include in API requests with the JSON null value. By default, fields
8550	// with empty values are omitted from API requests. However, any field
8551	// with an empty value appearing in NullFields will be sent to the
8552	// server as null. It is an error if a field in this list has a
8553	// non-empty value. This may be used to include null fields in Patch
8554	// requests.
8555	NullFields []string `json:"-"`
8556}
8557
8558func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig) MarshalJSON() ([]byte, error) {
8559	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig
8560	raw := NoMethod(*s)
8561	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8562}
8563
8564// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionFeatureConfi
8565// g: Config for suggestion features.
8566type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionFeatureConfig struct {
8567	// ConversationModelConfig: Configs of custom conversation model.
8568	ConversationModelConfig *GoogleCloudDialogflowV2HumanAgentAssistantConfigConversationModelConfig `json:"conversationModelConfig,omitempty"`
8569
8570	// EnableEventBasedSuggestion: Automatically iterates all participants
8571	// and tries to compile suggestions. Supported features:
8572	// ARTICLE_SUGGESTION, FAQ, DIALOGFLOW_ASSIST.
8573	EnableEventBasedSuggestion bool `json:"enableEventBasedSuggestion,omitempty"`
8574
8575	// QueryConfig: Configs of query.
8576	QueryConfig *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig `json:"queryConfig,omitempty"`
8577
8578	// SuggestionFeature: The suggestion feature.
8579	SuggestionFeature *GoogleCloudDialogflowV2SuggestionFeature `json:"suggestionFeature,omitempty"`
8580
8581	// SuggestionTriggerSettings: Settings of suggestion trigger. Currently,
8582	// only ARTICLE_SUGGESTION and FAQ will use this field.
8583	SuggestionTriggerSettings *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionTriggerSettings `json:"suggestionTriggerSettings,omitempty"`
8584
8585	// ForceSendFields is a list of field names (e.g.
8586	// "ConversationModelConfig") to unconditionally include in API
8587	// requests. By default, fields with empty values are omitted from API
8588	// requests. However, any non-pointer, non-interface field appearing in
8589	// ForceSendFields will be sent to the server regardless of whether the
8590	// field is empty or not. This may be used to include empty fields in
8591	// Patch requests.
8592	ForceSendFields []string `json:"-"`
8593
8594	// NullFields is a list of field names (e.g. "ConversationModelConfig")
8595	// to include in API requests with the JSON null value. By default,
8596	// fields with empty values are omitted from API requests. However, any
8597	// field with an empty value appearing in NullFields will be sent to the
8598	// server as null. It is an error if a field in this list has a
8599	// non-empty value. This may be used to include null fields in Patch
8600	// requests.
8601	NullFields []string `json:"-"`
8602}
8603
8604func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionFeatureConfig) MarshalJSON() ([]byte, error) {
8605	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionFeatureConfig
8606	raw := NoMethod(*s)
8607	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8608}
8609
8610// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig:
8611//  Config for suggestion query.
8612type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig struct {
8613	// ConfidenceThreshold: Confidence threshold of query result. Agent
8614	// Assist gives each suggestion a score in the range [0.0, 1.0], based
8615	// on the relevance between the suggestion and the current conversation
8616	// context. A score of 0.0 has no relevance, while a score of 1.0 has
8617	// high relevance. Only suggestions with a score greater than or equal
8618	// to the value of this field are included in the results. For a
8619	// baseline model (the default), the recommended value is in the range
8620	// [0.05, 0.1]. For a custom model, there is no recommended value. Tune
8621	// this value by starting from a very low value and slowly increasing
8622	// until you have desired results. If this field is not set, it defaults
8623	// to 0.0, which means that all suggestions are returned. Supported
8624	// features: ARTICLE_SUGGESTION.
8625	ConfidenceThreshold float64 `json:"confidenceThreshold,omitempty"`
8626
8627	// ContextFilterSettings: Determines how recent conversation context is
8628	// filtered when generating suggestions. If unspecified, no messages
8629	// will be dropped.
8630	ContextFilterSettings *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigContextFilterSettings `json:"contextFilterSettings,omitempty"`
8631
8632	// DialogflowQuerySource: Query from Dialogflow agent. It is used by
8633	// DIALOGFLOW_ASSIST.
8634	DialogflowQuerySource *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDialogflowQuerySource `json:"dialogflowQuerySource,omitempty"`
8635
8636	// DocumentQuerySource: Query from knowledge base document. It is used
8637	// by: SMART_REPLY, SMART_COMPOSE.
8638	DocumentQuerySource *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDocumentQuerySource `json:"documentQuerySource,omitempty"`
8639
8640	// KnowledgeBaseQuerySource: Query from knowledgebase. It is used by:
8641	// ARTICLE_SUGGESTION, FAQ.
8642	KnowledgeBaseQuerySource *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigKnowledgeBaseQuerySource `json:"knowledgeBaseQuerySource,omitempty"`
8643
8644	// MaxResults: Maximum number of results to return. Currently, if unset,
8645	// defaults to 10. And the max number is 20.
8646	MaxResults int64 `json:"maxResults,omitempty"`
8647
8648	// ForceSendFields is a list of field names (e.g. "ConfidenceThreshold")
8649	// to unconditionally include in API requests. By default, fields with
8650	// empty values are omitted from API requests. However, any non-pointer,
8651	// non-interface field appearing in ForceSendFields will be sent to the
8652	// server regardless of whether the field is empty or not. This may be
8653	// used to include empty fields in Patch requests.
8654	ForceSendFields []string `json:"-"`
8655
8656	// NullFields is a list of field names (e.g. "ConfidenceThreshold") to
8657	// include in API requests with the JSON null value. By default, fields
8658	// with empty values are omitted from API requests. However, any field
8659	// with an empty value appearing in NullFields will be sent to the
8660	// server as null. It is an error if a field in this list has a
8661	// non-empty value. This may be used to include null fields in Patch
8662	// requests.
8663	NullFields []string `json:"-"`
8664}
8665
8666func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig) MarshalJSON() ([]byte, error) {
8667	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig
8668	raw := NoMethod(*s)
8669	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8670}
8671
8672func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig) UnmarshalJSON(data []byte) error {
8673	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig
8674	var s1 struct {
8675		ConfidenceThreshold gensupport.JSONFloat64 `json:"confidenceThreshold"`
8676		*NoMethod
8677	}
8678	s1.NoMethod = (*NoMethod)(s)
8679	if err := json.Unmarshal(data, &s1); err != nil {
8680		return err
8681	}
8682	s.ConfidenceThreshold = float64(s1.ConfidenceThreshold)
8683	return nil
8684}
8685
8686// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigC
8687// ontextFilterSettings: Settings that determine how to filter recent
8688// conversation context when generating suggestions.
8689type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigContextFilterSettings struct {
8690	// DropHandoffMessages: If set to true, the last message from virtual
8691	// agent (hand off message) and the message before it (trigger message
8692	// of hand off) are dropped.
8693	DropHandoffMessages bool `json:"dropHandoffMessages,omitempty"`
8694
8695	// DropIvrMessages: If set to true, all messages from ivr stage are
8696	// dropped.
8697	DropIvrMessages bool `json:"dropIvrMessages,omitempty"`
8698
8699	// DropVirtualAgentMessages: If set to true, all messages from virtual
8700	// agent are dropped.
8701	DropVirtualAgentMessages bool `json:"dropVirtualAgentMessages,omitempty"`
8702
8703	// ForceSendFields is a list of field names (e.g. "DropHandoffMessages")
8704	// to unconditionally include in API requests. By default, fields with
8705	// empty values are omitted from API requests. However, any non-pointer,
8706	// non-interface field appearing in ForceSendFields will be sent to the
8707	// server regardless of whether the field is empty or not. This may be
8708	// used to include empty fields in Patch requests.
8709	ForceSendFields []string `json:"-"`
8710
8711	// NullFields is a list of field names (e.g. "DropHandoffMessages") to
8712	// include in API requests with the JSON null value. By default, fields
8713	// with empty values are omitted from API requests. However, any field
8714	// with an empty value appearing in NullFields will be sent to the
8715	// server as null. It is an error if a field in this list has a
8716	// non-empty value. This may be used to include null fields in Patch
8717	// requests.
8718	NullFields []string `json:"-"`
8719}
8720
8721func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigContextFilterSettings) MarshalJSON() ([]byte, error) {
8722	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigContextFilterSettings
8723	raw := NoMethod(*s)
8724	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8725}
8726
8727// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigD
8728// ialogflowQuerySource: Dialogflow source setting. Supported feature:
8729// DIALOGFLOW_ASSIST.
8730type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDialogflowQuerySource struct {
8731	// Agent: Required. The name of a Dialogflow virtual agent used for end
8732	// user side intent detection and suggestion. Format:
8733	// `projects//locations//agent`. When multiple agents are allowed in the
8734	// same Dialogflow project.
8735	Agent string `json:"agent,omitempty"`
8736
8737	// ForceSendFields is a list of field names (e.g. "Agent") to
8738	// unconditionally include in API requests. By default, fields with
8739	// empty values are omitted from API requests. However, any non-pointer,
8740	// non-interface field appearing in ForceSendFields will be sent to the
8741	// server regardless of whether the field is empty or not. This may be
8742	// used to include empty fields in Patch requests.
8743	ForceSendFields []string `json:"-"`
8744
8745	// NullFields is a list of field names (e.g. "Agent") to include in API
8746	// requests with the JSON null value. By default, fields with empty
8747	// values are omitted from API requests. However, any field with an
8748	// empty value appearing in NullFields will be sent to the server as
8749	// null. It is an error if a field in this list has a non-empty value.
8750	// This may be used to include null fields in Patch requests.
8751	NullFields []string `json:"-"`
8752}
8753
8754func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDialogflowQuerySource) MarshalJSON() ([]byte, error) {
8755	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDialogflowQuerySource
8756	raw := NoMethod(*s)
8757	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8758}
8759
8760// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigD
8761// ocumentQuerySource: Document source settings. Supported features:
8762// SMART_REPLY, SMART_COMPOSE.
8763type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDocumentQuerySource struct {
8764	// Documents: Required. Knowledge documents to query from. Format:
8765	// `projects//locations//knowledgeBases//documents/`. Currently, at most
8766	// 5 documents are supported.
8767	Documents []string `json:"documents,omitempty"`
8768
8769	// ForceSendFields is a list of field names (e.g. "Documents") to
8770	// unconditionally include in API requests. By default, fields with
8771	// empty values are omitted from API requests. However, any non-pointer,
8772	// non-interface field appearing in ForceSendFields will be sent to the
8773	// server regardless of whether the field is empty or not. This may be
8774	// used to include empty fields in Patch requests.
8775	ForceSendFields []string `json:"-"`
8776
8777	// NullFields is a list of field names (e.g. "Documents") to include in
8778	// API requests with the JSON null value. By default, fields with empty
8779	// values are omitted from API requests. However, any field with an
8780	// empty value appearing in NullFields will be sent to the server as
8781	// null. It is an error if a field in this list has a non-empty value.
8782	// This may be used to include null fields in Patch requests.
8783	NullFields []string `json:"-"`
8784}
8785
8786func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDocumentQuerySource) MarshalJSON() ([]byte, error) {
8787	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDocumentQuerySource
8788	raw := NoMethod(*s)
8789	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8790}
8791
8792// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigK
8793// nowledgeBaseQuerySource: Knowledge base source settings. Supported
8794// features: ARTICLE_SUGGESTION, FAQ.
8795type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigKnowledgeBaseQuerySource struct {
8796	// KnowledgeBases: Required. Knowledge bases to query. Format:
8797	// `projects//locations//knowledgeBases/`. Currently, at most 5
8798	// knowledge bases are supported.
8799	KnowledgeBases []string `json:"knowledgeBases,omitempty"`
8800
8801	// ForceSendFields is a list of field names (e.g. "KnowledgeBases") to
8802	// unconditionally include in API requests. By default, fields with
8803	// empty values are omitted from API requests. However, any non-pointer,
8804	// non-interface field appearing in ForceSendFields will be sent to the
8805	// server regardless of whether the field is empty or not. This may be
8806	// used to include empty fields in Patch requests.
8807	ForceSendFields []string `json:"-"`
8808
8809	// NullFields is a list of field names (e.g. "KnowledgeBases") to
8810	// include in API requests with the JSON null value. By default, fields
8811	// with empty values are omitted from API requests. However, any field
8812	// with an empty value appearing in NullFields will be sent to the
8813	// server as null. It is an error if a field in this list has a
8814	// non-empty value. This may be used to include null fields in Patch
8815	// requests.
8816	NullFields []string `json:"-"`
8817}
8818
8819func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigKnowledgeBaseQuerySource) MarshalJSON() ([]byte, error) {
8820	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigKnowledgeBaseQuerySource
8821	raw := NoMethod(*s)
8822	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8823}
8824
8825// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionTriggerSetti
8826// ngs: Settings of suggestion trigger.
8827type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionTriggerSettings struct {
8828	// NoSmalltalk: Do not trigger if last utterance is small talk.
8829	NoSmalltalk bool `json:"noSmalltalk,omitempty"`
8830
8831	// OnlyEndUser: Only trigger suggestion if participant role of last
8832	// utterance is END_USER.
8833	OnlyEndUser bool `json:"onlyEndUser,omitempty"`
8834
8835	// ForceSendFields is a list of field names (e.g. "NoSmalltalk") to
8836	// unconditionally include in API requests. By default, fields with
8837	// empty values are omitted from API requests. However, any non-pointer,
8838	// non-interface field appearing in ForceSendFields will be sent to the
8839	// server regardless of whether the field is empty or not. This may be
8840	// used to include empty fields in Patch requests.
8841	ForceSendFields []string `json:"-"`
8842
8843	// NullFields is a list of field names (e.g. "NoSmalltalk") to include
8844	// in API requests with the JSON null value. By default, fields with
8845	// empty values are omitted from API requests. However, any field with
8846	// an empty value appearing in NullFields will be sent to the server as
8847	// null. It is an error if a field in this list has a non-empty value.
8848	// This may be used to include null fields in Patch requests.
8849	NullFields []string `json:"-"`
8850}
8851
8852func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionTriggerSettings) MarshalJSON() ([]byte, error) {
8853	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionTriggerSettings
8854	raw := NoMethod(*s)
8855	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8856}
8857
8858// GoogleCloudDialogflowV2HumanAgentAssistantEvent: Represents a
8859// notification sent to Cloud Pub/Sub subscribers for human agent
8860// assistant events in a specific conversation.
8861type GoogleCloudDialogflowV2HumanAgentAssistantEvent struct {
8862	// Conversation: The conversation this notification refers to. Format:
8863	// `projects//conversations/`.
8864	Conversation string `json:"conversation,omitempty"`
8865
8866	// Participant: The participant that the suggestion is compiled for.
8867	// Format: `projects//conversations//participants/`. It will not be set
8868	// in legacy workflow.
8869	Participant string `json:"participant,omitempty"`
8870
8871	// SuggestionResults: The suggestion results payload that this
8872	// notification refers to.
8873	SuggestionResults []*GoogleCloudDialogflowV2SuggestionResult `json:"suggestionResults,omitempty"`
8874
8875	// ForceSendFields is a list of field names (e.g. "Conversation") to
8876	// unconditionally include in API requests. By default, fields with
8877	// empty values are omitted from API requests. However, any non-pointer,
8878	// non-interface field appearing in ForceSendFields will be sent to the
8879	// server regardless of whether the field is empty or not. This may be
8880	// used to include empty fields in Patch requests.
8881	ForceSendFields []string `json:"-"`
8882
8883	// NullFields is a list of field names (e.g. "Conversation") to include
8884	// in API requests with the JSON null value. By default, fields with
8885	// empty values are omitted from API requests. However, any field with
8886	// an empty value appearing in NullFields will be sent to the server as
8887	// null. It is an error if a field in this list has a non-empty value.
8888	// This may be used to include null fields in Patch requests.
8889	NullFields []string `json:"-"`
8890}
8891
8892func (s *GoogleCloudDialogflowV2HumanAgentAssistantEvent) MarshalJSON() ([]byte, error) {
8893	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantEvent
8894	raw := NoMethod(*s)
8895	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8896}
8897
8898// GoogleCloudDialogflowV2HumanAgentHandoffConfig: Defines the hand off
8899// to a live agent, typically on which external agent service provider
8900// to connect to a conversation. Currently, this feature is not general
8901// available, please contact Google to get access.
8902type GoogleCloudDialogflowV2HumanAgentHandoffConfig struct {
8903	// LivePersonConfig: Uses LivePerson (https://www.liveperson.com).
8904	LivePersonConfig *GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig `json:"livePersonConfig,omitempty"`
8905
8906	// SalesforceLiveAgentConfig: Uses Salesforce Live Agent.
8907	SalesforceLiveAgentConfig *GoogleCloudDialogflowV2HumanAgentHandoffConfigSalesforceLiveAgentConfig `json:"salesforceLiveAgentConfig,omitempty"`
8908
8909	// ForceSendFields is a list of field names (e.g. "LivePersonConfig") to
8910	// unconditionally include in API requests. By default, fields with
8911	// empty values are omitted from API requests. However, any non-pointer,
8912	// non-interface field appearing in ForceSendFields will be sent to the
8913	// server regardless of whether the field is empty or not. This may be
8914	// used to include empty fields in Patch requests.
8915	ForceSendFields []string `json:"-"`
8916
8917	// NullFields is a list of field names (e.g. "LivePersonConfig") to
8918	// include in API requests with the JSON null value. By default, fields
8919	// with empty values are omitted from API requests. However, any field
8920	// with an empty value appearing in NullFields will be sent to the
8921	// server as null. It is an error if a field in this list has a
8922	// non-empty value. This may be used to include null fields in Patch
8923	// requests.
8924	NullFields []string `json:"-"`
8925}
8926
8927func (s *GoogleCloudDialogflowV2HumanAgentHandoffConfig) MarshalJSON() ([]byte, error) {
8928	type NoMethod GoogleCloudDialogflowV2HumanAgentHandoffConfig
8929	raw := NoMethod(*s)
8930	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8931}
8932
8933// GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig:
8934// Configuration specific to LivePerson (https://www.liveperson.com).
8935type GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig struct {
8936	// AccountNumber: Required. Account number of the LivePerson account to
8937	// connect. This is the account number you input at the login page.
8938	AccountNumber string `json:"accountNumber,omitempty"`
8939
8940	// ForceSendFields is a list of field names (e.g. "AccountNumber") to
8941	// unconditionally include in API requests. By default, fields with
8942	// empty values are omitted from API requests. However, any non-pointer,
8943	// non-interface field appearing in ForceSendFields will be sent to the
8944	// server regardless of whether the field is empty or not. This may be
8945	// used to include empty fields in Patch requests.
8946	ForceSendFields []string `json:"-"`
8947
8948	// NullFields is a list of field names (e.g. "AccountNumber") to include
8949	// in API requests with the JSON null value. By default, fields with
8950	// empty values are omitted from API requests. However, any field with
8951	// an empty value appearing in NullFields will be sent to the server as
8952	// null. It is an error if a field in this list has a non-empty value.
8953	// This may be used to include null fields in Patch requests.
8954	NullFields []string `json:"-"`
8955}
8956
8957func (s *GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig) MarshalJSON() ([]byte, error) {
8958	type NoMethod GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig
8959	raw := NoMethod(*s)
8960	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8961}
8962
8963// GoogleCloudDialogflowV2HumanAgentHandoffConfigSalesforceLiveAgentConfi
8964// g: Configuration specific to Salesforce Live Agent.
8965type GoogleCloudDialogflowV2HumanAgentHandoffConfigSalesforceLiveAgentConfig struct {
8966	// ButtonId: Required. Live Agent chat button ID.
8967	ButtonId string `json:"buttonId,omitempty"`
8968
8969	// DeploymentId: Required. Live Agent deployment ID.
8970	DeploymentId string `json:"deploymentId,omitempty"`
8971
8972	// EndpointDomain: Required. Domain of the Live Agent endpoint for this
8973	// agent. You can find the endpoint URL in the `Live Agent settings`
8974	// page. For example if URL has the form
8975	// https://d.la4-c2-phx.salesforceliveagent.com/..., you should fill in
8976	// d.la4-c2-phx.salesforceliveagent.com.
8977	EndpointDomain string `json:"endpointDomain,omitempty"`
8978
8979	// OrganizationId: Required. The organization ID of the Salesforce
8980	// account.
8981	OrganizationId string `json:"organizationId,omitempty"`
8982
8983	// ForceSendFields is a list of field names (e.g. "ButtonId") to
8984	// unconditionally include in API requests. By default, fields with
8985	// empty values are omitted from API requests. However, any non-pointer,
8986	// non-interface field appearing in ForceSendFields will be sent to the
8987	// server regardless of whether the field is empty or not. This may be
8988	// used to include empty fields in Patch requests.
8989	ForceSendFields []string `json:"-"`
8990
8991	// NullFields is a list of field names (e.g. "ButtonId") to include in
8992	// API requests with the JSON null value. By default, fields with empty
8993	// values are omitted from API requests. However, any field with an
8994	// empty value appearing in NullFields will be sent to the server as
8995	// null. It is an error if a field in this list has a non-empty value.
8996	// This may be used to include null fields in Patch requests.
8997	NullFields []string `json:"-"`
8998}
8999
9000func (s *GoogleCloudDialogflowV2HumanAgentHandoffConfigSalesforceLiveAgentConfig) MarshalJSON() ([]byte, error) {
9001	type NoMethod GoogleCloudDialogflowV2HumanAgentHandoffConfigSalesforceLiveAgentConfig
9002	raw := NoMethod(*s)
9003	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9004}
9005
9006// GoogleCloudDialogflowV2ImportAgentRequest: The request message for
9007// Agents.ImportAgent.
9008type GoogleCloudDialogflowV2ImportAgentRequest struct {
9009	// AgentContent: Zip compressed raw byte content for agent.
9010	AgentContent string `json:"agentContent,omitempty"`
9011
9012	// AgentUri: The URI to a Google Cloud Storage file containing the agent
9013	// to import. Note: The URI must start with "gs://".
9014	AgentUri string `json:"agentUri,omitempty"`
9015
9016	// ForceSendFields is a list of field names (e.g. "AgentContent") to
9017	// unconditionally include in API requests. By default, fields with
9018	// empty values are omitted from API requests. However, any non-pointer,
9019	// non-interface field appearing in ForceSendFields will be sent to the
9020	// server regardless of whether the field is empty or not. This may be
9021	// used to include empty fields in Patch requests.
9022	ForceSendFields []string `json:"-"`
9023
9024	// NullFields is a list of field names (e.g. "AgentContent") 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 *GoogleCloudDialogflowV2ImportAgentRequest) MarshalJSON() ([]byte, error) {
9034	type NoMethod GoogleCloudDialogflowV2ImportAgentRequest
9035	raw := NoMethod(*s)
9036	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9037}
9038
9039// GoogleCloudDialogflowV2InputAudioConfig: Instructs the speech
9040// recognizer how to process the audio content.
9041type GoogleCloudDialogflowV2InputAudioConfig struct {
9042	// AudioEncoding: Required. Audio encoding of the audio content to
9043	// process.
9044	//
9045	// Possible values:
9046	//   "AUDIO_ENCODING_UNSPECIFIED" - Not specified.
9047	//   "AUDIO_ENCODING_LINEAR_16" - Uncompressed 16-bit signed
9048	// little-endian samples (Linear PCM).
9049	//   "AUDIO_ENCODING_FLAC" -
9050	// [`FLAC`](https://xiph.org/flac/documentation.html) (Free Lossless
9051	// Audio Codec) is the recommended encoding because it is lossless
9052	// (therefore recognition is not compromised) and requires only about
9053	// half the bandwidth of `LINEAR16`. `FLAC` stream encoding supports
9054	// 16-bit and 24-bit samples, however, not all fields in `STREAMINFO`
9055	// are supported.
9056	//   "AUDIO_ENCODING_MULAW" - 8-bit samples that compand 14-bit audio
9057	// samples using G.711 PCMU/mu-law.
9058	//   "AUDIO_ENCODING_AMR" - Adaptive Multi-Rate Narrowband codec.
9059	// `sample_rate_hertz` must be 8000.
9060	//   "AUDIO_ENCODING_AMR_WB" - Adaptive Multi-Rate Wideband codec.
9061	// `sample_rate_hertz` must be 16000.
9062	//   "AUDIO_ENCODING_OGG_OPUS" - Opus encoded audio frames in Ogg
9063	// container ([OggOpus](https://wiki.xiph.org/OggOpus)).
9064	// `sample_rate_hertz` must be 16000.
9065	//   "AUDIO_ENCODING_SPEEX_WITH_HEADER_BYTE" - Although the use of lossy
9066	// encodings is not recommended, if a very low bitrate encoding is
9067	// required, `OGG_OPUS` is highly preferred over Speex encoding. The
9068	// [Speex](https://speex.org/) encoding supported by Dialogflow API has
9069	// a header byte in each block, as in MIME type
9070	// `audio/x-speex-with-header-byte`. It is a variant of the RTP Speex
9071	// encoding defined in [RFC 5574](https://tools.ietf.org/html/rfc5574).
9072	// The stream is a sequence of blocks, one block per RTP packet. Each
9073	// block starts with a byte containing the length of the block, in
9074	// bytes, followed by one or more frames of Speex data, padded to an
9075	// integral number of bytes (octets) as specified in RFC 5574. In other
9076	// words, each RTP header is replaced with a single byte containing the
9077	// block length. Only Speex wideband is supported. `sample_rate_hertz`
9078	// must be 16000.
9079	AudioEncoding string `json:"audioEncoding,omitempty"`
9080
9081	// DisableNoSpeechRecognizedEvent: Only used in
9082	// Participants.AnalyzeContent and Participants.StreamingAnalyzeContent.
9083	// If `false` and recognition doesn't return any result, trigger
9084	// `NO_SPEECH_RECOGNIZED` event to Dialogflow agent.
9085	DisableNoSpeechRecognizedEvent bool `json:"disableNoSpeechRecognizedEvent,omitempty"`
9086
9087	// EnableWordInfo: If `true`, Dialogflow returns SpeechWordInfo in
9088	// StreamingRecognitionResult with information about the recognized
9089	// speech words, e.g. start and end time offsets. If false or
9090	// unspecified, Speech doesn't return any word-level information.
9091	EnableWordInfo bool `json:"enableWordInfo,omitempty"`
9092
9093	// LanguageCode: Required. The language of the supplied audio.
9094	// Dialogflow does not do translations. See Language Support
9095	// (https://cloud.google.com/dialogflow/docs/reference/language) for a
9096	// list of the currently supported language codes. Note that queries in
9097	// the same session do not necessarily need to specify the same
9098	// language.
9099	LanguageCode string `json:"languageCode,omitempty"`
9100
9101	// Model: Which Speech model to select for the given request. Select the
9102	// model best suited to your domain to get best results. If a model is
9103	// not explicitly specified, then we auto-select a model based on the
9104	// parameters in the InputAudioConfig. If enhanced speech model is
9105	// enabled for the agent and an enhanced version of the specified model
9106	// for the language does not exist, then the speech is recognized using
9107	// the standard version of the specified model. Refer to Cloud Speech
9108	// API documentation
9109	// (https://cloud.google.com/speech-to-text/docs/basics#select-model)
9110	// for more details.
9111	Model string `json:"model,omitempty"`
9112
9113	// ModelVariant: Which variant of the Speech model to use.
9114	//
9115	// Possible values:
9116	//   "SPEECH_MODEL_VARIANT_UNSPECIFIED" - No model variant specified. In
9117	// this case Dialogflow defaults to USE_BEST_AVAILABLE.
9118	//   "USE_BEST_AVAILABLE" - Use the best available variant of the Speech
9119	// model that the caller is eligible for. Please see the [Dialogflow
9120	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
9121	// to make your project eligible for enhanced models.
9122	//   "USE_STANDARD" - Use standard model variant even if an enhanced
9123	// model is available. See the [Cloud Speech
9124	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
9125	// odels) for details about enhanced models.
9126	//   "USE_ENHANCED" - Use an enhanced model variant: * If an enhanced
9127	// variant does not exist for the given model and request language,
9128	// Dialogflow falls back to the standard variant. The [Cloud Speech
9129	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
9130	// odels) describes which models have enhanced variants. * If the API
9131	// caller isn't eligible for enhanced models, Dialogflow returns an
9132	// error. Please see the [Dialogflow
9133	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
9134	// to make your project eligible.
9135	ModelVariant string `json:"modelVariant,omitempty"`
9136
9137	// PhraseHints: A list of strings containing words and phrases that the
9138	// speech recognizer should recognize with higher likelihood. See the
9139	// Cloud Speech documentation
9140	// (https://cloud.google.com/speech-to-text/docs/basics#phrase-hints)
9141	// for more details. This field is deprecated. Please use
9142	// speech_contexts () instead. If you specify both phrase_hints () and
9143	// speech_contexts (), Dialogflow will treat the phrase_hints () as a
9144	// single additional SpeechContext ().
9145	PhraseHints []string `json:"phraseHints,omitempty"`
9146
9147	// SampleRateHertz: Required. Sample rate (in Hertz) of the audio
9148	// content sent in the query. Refer to Cloud Speech API documentation
9149	// (https://cloud.google.com/speech-to-text/docs/basics) for more
9150	// details.
9151	SampleRateHertz int64 `json:"sampleRateHertz,omitempty"`
9152
9153	// SingleUtterance: If `false` (default), recognition does not cease
9154	// until the client closes the stream. If `true`, the recognizer will
9155	// detect a single spoken utterance in input audio. Recognition ceases
9156	// when it detects the audio's voice has stopped or paused. In this
9157	// case, once a detected intent is received, the client should close the
9158	// stream and start a new request with a new stream as needed. Note:
9159	// This setting is relevant only for streaming methods. Note: When
9160	// specified, InputAudioConfig.single_utterance takes precedence over
9161	// StreamingDetectIntentRequest.single_utterance.
9162	SingleUtterance bool `json:"singleUtterance,omitempty"`
9163
9164	// SpeechContexts: Context information to assist speech recognition. See
9165	// the Cloud Speech documentation
9166	// (https://cloud.google.com/speech-to-text/docs/basics#phrase-hints)
9167	// for more details.
9168	SpeechContexts []*GoogleCloudDialogflowV2SpeechContext `json:"speechContexts,omitempty"`
9169
9170	// ForceSendFields is a list of field names (e.g. "AudioEncoding") to
9171	// unconditionally include in API requests. By default, fields with
9172	// empty values are omitted from API requests. However, any non-pointer,
9173	// non-interface field appearing in ForceSendFields will be sent to the
9174	// server regardless of whether the field is empty or not. This may be
9175	// used to include empty fields in Patch requests.
9176	ForceSendFields []string `json:"-"`
9177
9178	// NullFields is a list of field names (e.g. "AudioEncoding") to include
9179	// in API requests with the JSON null value. By default, fields with
9180	// empty values are omitted from API requests. However, any field with
9181	// an empty value appearing in NullFields will be sent to the server as
9182	// null. It is an error if a field in this list has a non-empty value.
9183	// This may be used to include null fields in Patch requests.
9184	NullFields []string `json:"-"`
9185}
9186
9187func (s *GoogleCloudDialogflowV2InputAudioConfig) MarshalJSON() ([]byte, error) {
9188	type NoMethod GoogleCloudDialogflowV2InputAudioConfig
9189	raw := NoMethod(*s)
9190	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9191}
9192
9193// GoogleCloudDialogflowV2Intent: An intent categorizes an end-user's
9194// intention for one conversation turn. For each agent, you define many
9195// intents, where your combined intents can handle a complete
9196// conversation. When an end-user writes or says something, referred to
9197// as an end-user expression or end-user input, Dialogflow matches the
9198// end-user input to the best intent in your agent. Matching an intent
9199// is also known as intent classification. For more information, see the
9200// intent guide
9201// (https://cloud.google.com/dialogflow/docs/intents-overview).
9202type GoogleCloudDialogflowV2Intent struct {
9203	// Action: Optional. The name of the action associated with the intent.
9204	// Note: The action name must not contain whitespaces.
9205	Action string `json:"action,omitempty"`
9206
9207	// DefaultResponsePlatforms: Optional. The list of platforms for which
9208	// the first responses will be copied from the messages in
9209	// PLATFORM_UNSPECIFIED (i.e. default platform).
9210	//
9211	// Possible values:
9212	//   "PLATFORM_UNSPECIFIED" - Default platform.
9213	//   "FACEBOOK" - Facebook.
9214	//   "SLACK" - Slack.
9215	//   "TELEGRAM" - Telegram.
9216	//   "KIK" - Kik.
9217	//   "SKYPE" - Skype.
9218	//   "LINE" - Line.
9219	//   "VIBER" - Viber.
9220	//   "ACTIONS_ON_GOOGLE" - Google Assistant See [Dialogflow webhook
9221	// format](https://developers.google.com/assistant/actions/build/json/dia
9222	// logflow-webhook-json)
9223	//   "GOOGLE_HANGOUTS" - Google Hangouts.
9224	DefaultResponsePlatforms []string `json:"defaultResponsePlatforms,omitempty"`
9225
9226	// DisplayName: Required. The name of this intent.
9227	DisplayName string `json:"displayName,omitempty"`
9228
9229	// EndInteraction: Optional. Indicates that this intent ends an
9230	// interaction. Some integrations (e.g., Actions on Google or Dialogflow
9231	// phone gateway) use this information to close interaction with an end
9232	// user. Default is false.
9233	EndInteraction bool `json:"endInteraction,omitempty"`
9234
9235	// Events: Optional. The collection of event names that trigger the
9236	// intent. If the collection of input contexts is not empty, all of the
9237	// contexts must be present in the active user session for an event to
9238	// trigger this intent. Event names are limited to 150 characters.
9239	Events []string `json:"events,omitempty"`
9240
9241	// FollowupIntentInfo: Read-only. Information about all followup intents
9242	// that have this intent as a direct or indirect parent. We populate
9243	// this field only in the output.
9244	FollowupIntentInfo []*GoogleCloudDialogflowV2IntentFollowupIntentInfo `json:"followupIntentInfo,omitempty"`
9245
9246	// InputContextNames: Optional. The list of context names required for
9247	// this intent to be triggered. Format:
9248	// `projects//agent/sessions/-/contexts/`.
9249	InputContextNames []string `json:"inputContextNames,omitempty"`
9250
9251	// IsFallback: Optional. Indicates whether this is a fallback intent.
9252	IsFallback bool `json:"isFallback,omitempty"`
9253
9254	// LiveAgentHandoff: Optional. Indicates that a live agent should be
9255	// brought in to handle the interaction with the user. In most cases,
9256	// when you set this flag to true, you would also want to set
9257	// end_interaction to true as well. Default is false.
9258	LiveAgentHandoff bool `json:"liveAgentHandoff,omitempty"`
9259
9260	// Messages: Optional. The collection of rich messages corresponding to
9261	// the `Response` field in the Dialogflow console.
9262	Messages []*GoogleCloudDialogflowV2IntentMessage `json:"messages,omitempty"`
9263
9264	// MlDisabled: Optional. Indicates whether Machine Learning is disabled
9265	// for the intent. Note: If `ml_disabled` setting is set to true, then
9266	// this intent is not taken into account during inference in `ML ONLY`
9267	// match mode. Also, auto-markup in the UI is turned off.
9268	MlDisabled bool `json:"mlDisabled,omitempty"`
9269
9270	// Name: Optional. The unique identifier of this intent. Required for
9271	// Intents.UpdateIntent and Intents.BatchUpdateIntents methods. Format:
9272	// `projects//agent/intents/`.
9273	Name string `json:"name,omitempty"`
9274
9275	// OutputContexts: Optional. The collection of contexts that are
9276	// activated when the intent is matched. Context messages in this
9277	// collection should not set the parameters field. Setting the
9278	// `lifespan_count` to 0 will reset the context when the intent is
9279	// matched. Format: `projects//agent/sessions/-/contexts/`.
9280	OutputContexts []*GoogleCloudDialogflowV2Context `json:"outputContexts,omitempty"`
9281
9282	// Parameters: Optional. The collection of parameters associated with
9283	// the intent.
9284	Parameters []*GoogleCloudDialogflowV2IntentParameter `json:"parameters,omitempty"`
9285
9286	// ParentFollowupIntentName: Read-only after creation. The unique
9287	// identifier of the parent intent in the chain of followup intents. You
9288	// can set this field when creating an intent, for example with
9289	// CreateIntent or BatchUpdateIntents, in order to make this intent a
9290	// followup intent. It identifies the parent followup intent. Format:
9291	// `projects//agent/intents/`.
9292	ParentFollowupIntentName string `json:"parentFollowupIntentName,omitempty"`
9293
9294	// Priority: Optional. The priority of this intent. Higher numbers
9295	// represent higher priorities. - If the supplied value is unspecified
9296	// or 0, the service translates the value to 500,000, which corresponds
9297	// to the `Normal` priority in the console. - If the supplied value is
9298	// negative, the intent is ignored in runtime detect intent requests.
9299	Priority int64 `json:"priority,omitempty"`
9300
9301	// ResetContexts: Optional. Indicates whether to delete all contexts in
9302	// the current session when this intent is matched.
9303	ResetContexts bool `json:"resetContexts,omitempty"`
9304
9305	// RootFollowupIntentName: Read-only. The unique identifier of the root
9306	// intent in the chain of followup intents. It identifies the correct
9307	// followup intents chain for this intent. We populate this field only
9308	// in the output. Format: `projects//agent/intents/`.
9309	RootFollowupIntentName string `json:"rootFollowupIntentName,omitempty"`
9310
9311	// TrainingPhrases: Optional. The collection of examples that the agent
9312	// is trained on.
9313	TrainingPhrases []*GoogleCloudDialogflowV2IntentTrainingPhrase `json:"trainingPhrases,omitempty"`
9314
9315	// WebhookState: Optional. Indicates whether webhooks are enabled for
9316	// the intent.
9317	//
9318	// Possible values:
9319	//   "WEBHOOK_STATE_UNSPECIFIED" - Webhook is disabled in the agent and
9320	// in the intent.
9321	//   "WEBHOOK_STATE_ENABLED" - Webhook is enabled in the agent and in
9322	// the intent.
9323	//   "WEBHOOK_STATE_ENABLED_FOR_SLOT_FILLING" - Webhook is enabled in
9324	// the agent and in the intent. Also, each slot filling prompt is
9325	// forwarded to the webhook.
9326	WebhookState string `json:"webhookState,omitempty"`
9327
9328	// ServerResponse contains the HTTP response code and headers from the
9329	// server.
9330	googleapi.ServerResponse `json:"-"`
9331
9332	// ForceSendFields is a list of field names (e.g. "Action") to
9333	// unconditionally include in API requests. By default, fields with
9334	// empty values are omitted from API requests. However, any non-pointer,
9335	// non-interface field appearing in ForceSendFields will be sent to the
9336	// server regardless of whether the field is empty or not. This may be
9337	// used to include empty fields in Patch requests.
9338	ForceSendFields []string `json:"-"`
9339
9340	// NullFields is a list of field names (e.g. "Action") to include in API
9341	// requests with the JSON null value. By default, fields with empty
9342	// values are omitted from API requests. However, any field with an
9343	// empty value appearing in NullFields will be sent to the server as
9344	// null. It is an error if a field in this list has a non-empty value.
9345	// This may be used to include null fields in Patch requests.
9346	NullFields []string `json:"-"`
9347}
9348
9349func (s *GoogleCloudDialogflowV2Intent) MarshalJSON() ([]byte, error) {
9350	type NoMethod GoogleCloudDialogflowV2Intent
9351	raw := NoMethod(*s)
9352	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9353}
9354
9355// GoogleCloudDialogflowV2IntentBatch: This message is a wrapper around
9356// a collection of intents.
9357type GoogleCloudDialogflowV2IntentBatch struct {
9358	// Intents: A collection of intents.
9359	Intents []*GoogleCloudDialogflowV2Intent `json:"intents,omitempty"`
9360
9361	// ForceSendFields is a list of field names (e.g. "Intents") to
9362	// unconditionally include in API requests. By default, fields with
9363	// empty values are omitted from API requests. However, any non-pointer,
9364	// non-interface field appearing in ForceSendFields will be sent to the
9365	// server regardless of whether the field is empty or not. This may be
9366	// used to include empty fields in Patch requests.
9367	ForceSendFields []string `json:"-"`
9368
9369	// NullFields is a list of field names (e.g. "Intents") to include in
9370	// API requests with the JSON null value. By default, fields with empty
9371	// values are omitted from API requests. However, any field with an
9372	// empty value appearing in NullFields will be sent to the server as
9373	// null. It is an error if a field in this list has a non-empty value.
9374	// This may be used to include null fields in Patch requests.
9375	NullFields []string `json:"-"`
9376}
9377
9378func (s *GoogleCloudDialogflowV2IntentBatch) MarshalJSON() ([]byte, error) {
9379	type NoMethod GoogleCloudDialogflowV2IntentBatch
9380	raw := NoMethod(*s)
9381	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9382}
9383
9384// GoogleCloudDialogflowV2IntentFollowupIntentInfo: Represents a single
9385// followup intent in the chain.
9386type GoogleCloudDialogflowV2IntentFollowupIntentInfo struct {
9387	// FollowupIntentName: The unique identifier of the followup intent.
9388	// Format: `projects//agent/intents/`.
9389	FollowupIntentName string `json:"followupIntentName,omitempty"`
9390
9391	// ParentFollowupIntentName: The unique identifier of the followup
9392	// intent's parent. Format: `projects//agent/intents/`.
9393	ParentFollowupIntentName string `json:"parentFollowupIntentName,omitempty"`
9394
9395	// ForceSendFields is a list of field names (e.g. "FollowupIntentName")
9396	// to unconditionally include in API requests. By default, fields with
9397	// empty values are omitted from API requests. However, any non-pointer,
9398	// non-interface field appearing in ForceSendFields will be sent to the
9399	// server regardless of whether the field is empty or not. This may be
9400	// used to include empty fields in Patch requests.
9401	ForceSendFields []string `json:"-"`
9402
9403	// NullFields is a list of field names (e.g. "FollowupIntentName") to
9404	// include in API requests with the JSON null value. By default, fields
9405	// with empty values are omitted from API requests. However, any field
9406	// with an empty value appearing in NullFields will be sent to the
9407	// server as null. It is an error if a field in this list has a
9408	// non-empty value. This may be used to include null fields in Patch
9409	// requests.
9410	NullFields []string `json:"-"`
9411}
9412
9413func (s *GoogleCloudDialogflowV2IntentFollowupIntentInfo) MarshalJSON() ([]byte, error) {
9414	type NoMethod GoogleCloudDialogflowV2IntentFollowupIntentInfo
9415	raw := NoMethod(*s)
9416	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9417}
9418
9419// GoogleCloudDialogflowV2IntentMessage: A rich response message.
9420// Corresponds to the intent `Response` field in the Dialogflow console.
9421// For more information, see Rich response messages
9422// (https://cloud.google.com/dialogflow/docs/intents-rich-messages).
9423type GoogleCloudDialogflowV2IntentMessage struct {
9424	// BasicCard: The basic card response for Actions on Google.
9425	BasicCard *GoogleCloudDialogflowV2IntentMessageBasicCard `json:"basicCard,omitempty"`
9426
9427	// BrowseCarouselCard: Browse carousel card for Actions on Google.
9428	BrowseCarouselCard *GoogleCloudDialogflowV2IntentMessageBrowseCarouselCard `json:"browseCarouselCard,omitempty"`
9429
9430	// Card: The card response.
9431	Card *GoogleCloudDialogflowV2IntentMessageCard `json:"card,omitempty"`
9432
9433	// CarouselSelect: The carousel card response for Actions on Google.
9434	CarouselSelect *GoogleCloudDialogflowV2IntentMessageCarouselSelect `json:"carouselSelect,omitempty"`
9435
9436	// Image: The image response.
9437	Image *GoogleCloudDialogflowV2IntentMessageImage `json:"image,omitempty"`
9438
9439	// LinkOutSuggestion: The link out suggestion chip for Actions on
9440	// Google.
9441	LinkOutSuggestion *GoogleCloudDialogflowV2IntentMessageLinkOutSuggestion `json:"linkOutSuggestion,omitempty"`
9442
9443	// ListSelect: The list card response for Actions on Google.
9444	ListSelect *GoogleCloudDialogflowV2IntentMessageListSelect `json:"listSelect,omitempty"`
9445
9446	// MediaContent: The media content card for Actions on Google.
9447	MediaContent *GoogleCloudDialogflowV2IntentMessageMediaContent `json:"mediaContent,omitempty"`
9448
9449	// Payload: A custom platform-specific response.
9450	Payload googleapi.RawMessage `json:"payload,omitempty"`
9451
9452	// Platform: Optional. The platform that this message is intended for.
9453	//
9454	// Possible values:
9455	//   "PLATFORM_UNSPECIFIED" - Default platform.
9456	//   "FACEBOOK" - Facebook.
9457	//   "SLACK" - Slack.
9458	//   "TELEGRAM" - Telegram.
9459	//   "KIK" - Kik.
9460	//   "SKYPE" - Skype.
9461	//   "LINE" - Line.
9462	//   "VIBER" - Viber.
9463	//   "ACTIONS_ON_GOOGLE" - Google Assistant See [Dialogflow webhook
9464	// format](https://developers.google.com/assistant/actions/build/json/dia
9465	// logflow-webhook-json)
9466	//   "GOOGLE_HANGOUTS" - Google Hangouts.
9467	Platform string `json:"platform,omitempty"`
9468
9469	// QuickReplies: The quick replies response.
9470	QuickReplies *GoogleCloudDialogflowV2IntentMessageQuickReplies `json:"quickReplies,omitempty"`
9471
9472	// SimpleResponses: The voice and text-only responses for Actions on
9473	// Google.
9474	SimpleResponses *GoogleCloudDialogflowV2IntentMessageSimpleResponses `json:"simpleResponses,omitempty"`
9475
9476	// Suggestions: The suggestion chips for Actions on Google.
9477	Suggestions *GoogleCloudDialogflowV2IntentMessageSuggestions `json:"suggestions,omitempty"`
9478
9479	// TableCard: Table card for Actions on Google.
9480	TableCard *GoogleCloudDialogflowV2IntentMessageTableCard `json:"tableCard,omitempty"`
9481
9482	// Text: The text response.
9483	Text *GoogleCloudDialogflowV2IntentMessageText `json:"text,omitempty"`
9484
9485	// ForceSendFields is a list of field names (e.g. "BasicCard") to
9486	// unconditionally include in API requests. By default, fields with
9487	// empty values are omitted from API requests. However, any non-pointer,
9488	// non-interface field appearing in ForceSendFields will be sent to the
9489	// server regardless of whether the field is empty or not. This may be
9490	// used to include empty fields in Patch requests.
9491	ForceSendFields []string `json:"-"`
9492
9493	// NullFields is a list of field names (e.g. "BasicCard") to include in
9494	// API requests with the JSON null value. By default, fields with empty
9495	// values are omitted from API requests. However, any field with an
9496	// empty value appearing in NullFields will be sent to the server as
9497	// null. It is an error if a field in this list has a non-empty value.
9498	// This may be used to include null fields in Patch requests.
9499	NullFields []string `json:"-"`
9500}
9501
9502func (s *GoogleCloudDialogflowV2IntentMessage) MarshalJSON() ([]byte, error) {
9503	type NoMethod GoogleCloudDialogflowV2IntentMessage
9504	raw := NoMethod(*s)
9505	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9506}
9507
9508// GoogleCloudDialogflowV2IntentMessageBasicCard: The basic card
9509// message. Useful for displaying information.
9510type GoogleCloudDialogflowV2IntentMessageBasicCard struct {
9511	// Buttons: Optional. The collection of card buttons.
9512	Buttons []*GoogleCloudDialogflowV2IntentMessageBasicCardButton `json:"buttons,omitempty"`
9513
9514	// FormattedText: Required, unless image is present. The body text of
9515	// the card.
9516	FormattedText string `json:"formattedText,omitempty"`
9517
9518	// Image: Optional. The image for the card.
9519	Image *GoogleCloudDialogflowV2IntentMessageImage `json:"image,omitempty"`
9520
9521	// Subtitle: Optional. The subtitle of the card.
9522	Subtitle string `json:"subtitle,omitempty"`
9523
9524	// Title: Optional. The title of the card.
9525	Title string `json:"title,omitempty"`
9526
9527	// ForceSendFields is a list of field names (e.g. "Buttons") to
9528	// unconditionally include in API requests. By default, fields with
9529	// empty values are omitted from API requests. However, any non-pointer,
9530	// non-interface field appearing in ForceSendFields will be sent to the
9531	// server regardless of whether the field is empty or not. This may be
9532	// used to include empty fields in Patch requests.
9533	ForceSendFields []string `json:"-"`
9534
9535	// NullFields is a list of field names (e.g. "Buttons") to include in
9536	// API requests with the JSON null value. By default, fields with empty
9537	// values are omitted from API requests. However, any field with an
9538	// empty value appearing in NullFields will be sent to the server as
9539	// null. It is an error if a field in this list has a non-empty value.
9540	// This may be used to include null fields in Patch requests.
9541	NullFields []string `json:"-"`
9542}
9543
9544func (s *GoogleCloudDialogflowV2IntentMessageBasicCard) MarshalJSON() ([]byte, error) {
9545	type NoMethod GoogleCloudDialogflowV2IntentMessageBasicCard
9546	raw := NoMethod(*s)
9547	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9548}
9549
9550// GoogleCloudDialogflowV2IntentMessageBasicCardButton: The button
9551// object that appears at the bottom of a card.
9552type GoogleCloudDialogflowV2IntentMessageBasicCardButton struct {
9553	// OpenUriAction: Required. Action to take when a user taps on the
9554	// button.
9555	OpenUriAction *GoogleCloudDialogflowV2IntentMessageBasicCardButtonOpenUriAction `json:"openUriAction,omitempty"`
9556
9557	// Title: Required. The title of the button.
9558	Title string `json:"title,omitempty"`
9559
9560	// ForceSendFields is a list of field names (e.g. "OpenUriAction") to
9561	// unconditionally include in API requests. By default, fields with
9562	// empty values are omitted from API requests. However, any non-pointer,
9563	// non-interface field appearing in ForceSendFields will be sent to the
9564	// server regardless of whether the field is empty or not. This may be
9565	// used to include empty fields in Patch requests.
9566	ForceSendFields []string `json:"-"`
9567
9568	// NullFields is a list of field names (e.g. "OpenUriAction") to include
9569	// in API requests with the JSON null value. By default, fields with
9570	// empty values are omitted from API requests. However, any field with
9571	// an empty value appearing in NullFields will be sent to the server as
9572	// null. It is an error if a field in this list has a non-empty value.
9573	// This may be used to include null fields in Patch requests.
9574	NullFields []string `json:"-"`
9575}
9576
9577func (s *GoogleCloudDialogflowV2IntentMessageBasicCardButton) MarshalJSON() ([]byte, error) {
9578	type NoMethod GoogleCloudDialogflowV2IntentMessageBasicCardButton
9579	raw := NoMethod(*s)
9580	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9581}
9582
9583// GoogleCloudDialogflowV2IntentMessageBasicCardButtonOpenUriAction:
9584// Opens the given URI.
9585type GoogleCloudDialogflowV2IntentMessageBasicCardButtonOpenUriAction struct {
9586	// Uri: Required. The HTTP or HTTPS scheme URI.
9587	Uri string `json:"uri,omitempty"`
9588
9589	// ForceSendFields is a list of field names (e.g. "Uri") to
9590	// unconditionally include in API requests. By default, fields with
9591	// empty values are omitted from API requests. However, any non-pointer,
9592	// non-interface field appearing in ForceSendFields will be sent to the
9593	// server regardless of whether the field is empty or not. This may be
9594	// used to include empty fields in Patch requests.
9595	ForceSendFields []string `json:"-"`
9596
9597	// NullFields is a list of field names (e.g. "Uri") to include in API
9598	// requests with the JSON null value. By default, fields with empty
9599	// values are omitted from API requests. However, any field with an
9600	// empty value appearing in NullFields will be sent to the server as
9601	// null. It is an error if a field in this list has a non-empty value.
9602	// This may be used to include null fields in Patch requests.
9603	NullFields []string `json:"-"`
9604}
9605
9606func (s *GoogleCloudDialogflowV2IntentMessageBasicCardButtonOpenUriAction) MarshalJSON() ([]byte, error) {
9607	type NoMethod GoogleCloudDialogflowV2IntentMessageBasicCardButtonOpenUriAction
9608	raw := NoMethod(*s)
9609	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9610}
9611
9612// GoogleCloudDialogflowV2IntentMessageBrowseCarouselCard: Browse
9613// Carousel Card for Actions on Google.
9614// https://developers.google.com/actions/assistant/responses#browsing_carousel
9615type GoogleCloudDialogflowV2IntentMessageBrowseCarouselCard struct {
9616	// ImageDisplayOptions: Optional. Settings for displaying the image.
9617	// Applies to every image in items.
9618	//
9619	// Possible values:
9620	//   "IMAGE_DISPLAY_OPTIONS_UNSPECIFIED" - Fill the gaps between the
9621	// image and the image container with gray bars.
9622	//   "GRAY" - Fill the gaps between the image and the image container
9623	// with gray bars.
9624	//   "WHITE" - Fill the gaps between the image and the image container
9625	// with white bars.
9626	//   "CROPPED" - Image is scaled such that the image width and height
9627	// match or exceed the container dimensions. This may crop the top and
9628	// bottom of the image if the scaled image height is greater than the
9629	// container height, or crop the left and right of the image if the
9630	// scaled image width is greater than the container width. This is
9631	// similar to "Zoom Mode" on a widescreen TV when playing a 4:3 video.
9632	//   "BLURRED_BACKGROUND" - Pad the gaps between image and image frame
9633	// with a blurred copy of the same image.
9634	ImageDisplayOptions string `json:"imageDisplayOptions,omitempty"`
9635
9636	// Items: Required. List of items in the Browse Carousel Card. Minimum
9637	// of two items, maximum of ten.
9638	Items []*GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItem `json:"items,omitempty"`
9639
9640	// ForceSendFields is a list of field names (e.g. "ImageDisplayOptions")
9641	// to unconditionally include in API requests. By default, fields with
9642	// empty values are omitted from API requests. However, any non-pointer,
9643	// non-interface field appearing in ForceSendFields will be sent to the
9644	// server regardless of whether the field is empty or not. This may be
9645	// used to include empty fields in Patch requests.
9646	ForceSendFields []string `json:"-"`
9647
9648	// NullFields is a list of field names (e.g. "ImageDisplayOptions") to
9649	// include in API requests with the JSON null value. By default, fields
9650	// with empty values are omitted from API requests. However, any field
9651	// with an empty value appearing in NullFields will be sent to the
9652	// server as null. It is an error if a field in this list has a
9653	// non-empty value. This may be used to include null fields in Patch
9654	// requests.
9655	NullFields []string `json:"-"`
9656}
9657
9658func (s *GoogleCloudDialogflowV2IntentMessageBrowseCarouselCard) MarshalJSON() ([]byte, error) {
9659	type NoMethod GoogleCloudDialogflowV2IntentMessageBrowseCarouselCard
9660	raw := NoMethod(*s)
9661	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9662}
9663
9664// GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCa
9665// rdItem: Browsing carousel tile
9666type GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItem struct {
9667	// Description: Optional. Description of the carousel item. Maximum of
9668	// four lines of text.
9669	Description string `json:"description,omitempty"`
9670
9671	// Footer: Optional. Text that appears at the bottom of the Browse
9672	// Carousel Card. Maximum of one line of text.
9673	Footer string `json:"footer,omitempty"`
9674
9675	// Image: Optional. Hero image for the carousel item.
9676	Image *GoogleCloudDialogflowV2IntentMessageImage `json:"image,omitempty"`
9677
9678	// OpenUriAction: Required. Action to present to the user.
9679	OpenUriAction *GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction `json:"openUriAction,omitempty"`
9680
9681	// Title: Required. Title of the carousel item. Maximum of two lines of
9682	// text.
9683	Title string `json:"title,omitempty"`
9684
9685	// ForceSendFields is a list of field names (e.g. "Description") to
9686	// unconditionally include in API requests. By default, fields with
9687	// empty values are omitted from API requests. However, any non-pointer,
9688	// non-interface field appearing in ForceSendFields will be sent to the
9689	// server regardless of whether the field is empty or not. This may be
9690	// used to include empty fields in Patch requests.
9691	ForceSendFields []string `json:"-"`
9692
9693	// NullFields is a list of field names (e.g. "Description") to include
9694	// in API requests with the JSON null value. By default, fields with
9695	// empty values are omitted from API requests. However, any field with
9696	// an 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 *GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItem) MarshalJSON() ([]byte, error) {
9703	type NoMethod GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItem
9704	raw := NoMethod(*s)
9705	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9706}
9707
9708// GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCa
9709// rdItemOpenUrlAction: Actions on Google action to open a given url.
9710type GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction struct {
9711	// Url: Required. URL
9712	Url string `json:"url,omitempty"`
9713
9714	// UrlTypeHint: Optional. Specifies the type of viewer that is used when
9715	// opening the URL. Defaults to opening via web browser.
9716	//
9717	// Possible values:
9718	//   "URL_TYPE_HINT_UNSPECIFIED" - Unspecified
9719	//   "AMP_ACTION" - Url would be an amp action
9720	//   "AMP_CONTENT" - URL that points directly to AMP content, or to a
9721	// canonical URL which refers to AMP content via .
9722	UrlTypeHint string `json:"urlTypeHint,omitempty"`
9723
9724	// ForceSendFields is a list of field names (e.g. "Url") to
9725	// unconditionally include in API requests. By default, fields with
9726	// empty values are omitted from API requests. However, any non-pointer,
9727	// non-interface field appearing in ForceSendFields will be sent to the
9728	// server regardless of whether the field is empty or not. This may be
9729	// used to include empty fields in Patch requests.
9730	ForceSendFields []string `json:"-"`
9731
9732	// NullFields is a list of field names (e.g. "Url") to include in API
9733	// requests with the JSON null value. By default, fields with empty
9734	// values are omitted from API requests. However, any field with an
9735	// empty value appearing in NullFields will be sent to the server as
9736	// null. It is an error if a field in this list has a non-empty value.
9737	// This may be used to include null fields in Patch requests.
9738	NullFields []string `json:"-"`
9739}
9740
9741func (s *GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction) MarshalJSON() ([]byte, error) {
9742	type NoMethod GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction
9743	raw := NoMethod(*s)
9744	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9745}
9746
9747// GoogleCloudDialogflowV2IntentMessageCard: The card response message.
9748type GoogleCloudDialogflowV2IntentMessageCard struct {
9749	// Buttons: Optional. The collection of card buttons.
9750	Buttons []*GoogleCloudDialogflowV2IntentMessageCardButton `json:"buttons,omitempty"`
9751
9752	// ImageUri: Optional. The public URI to an image file for the card.
9753	ImageUri string `json:"imageUri,omitempty"`
9754
9755	// Subtitle: Optional. The subtitle of the card.
9756	Subtitle string `json:"subtitle,omitempty"`
9757
9758	// Title: Optional. The title of the card.
9759	Title string `json:"title,omitempty"`
9760
9761	// ForceSendFields is a list of field names (e.g. "Buttons") to
9762	// unconditionally include in API requests. By default, fields with
9763	// empty values are omitted from API requests. However, any non-pointer,
9764	// non-interface field appearing in ForceSendFields will be sent to the
9765	// server regardless of whether the field is empty or not. This may be
9766	// used to include empty fields in Patch requests.
9767	ForceSendFields []string `json:"-"`
9768
9769	// NullFields is a list of field names (e.g. "Buttons") to include in
9770	// API requests with the JSON null value. By default, fields with empty
9771	// values are omitted from API requests. However, any field with an
9772	// empty value appearing in NullFields will be sent to the server as
9773	// null. It is an error if a field in this list has a non-empty value.
9774	// This may be used to include null fields in Patch requests.
9775	NullFields []string `json:"-"`
9776}
9777
9778func (s *GoogleCloudDialogflowV2IntentMessageCard) MarshalJSON() ([]byte, error) {
9779	type NoMethod GoogleCloudDialogflowV2IntentMessageCard
9780	raw := NoMethod(*s)
9781	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9782}
9783
9784// GoogleCloudDialogflowV2IntentMessageCardButton: Contains information
9785// about a button.
9786type GoogleCloudDialogflowV2IntentMessageCardButton struct {
9787	// Postback: Optional. The text to send back to the Dialogflow API or a
9788	// URI to open.
9789	Postback string `json:"postback,omitempty"`
9790
9791	// Text: Optional. The text to show on the button.
9792	Text string `json:"text,omitempty"`
9793
9794	// ForceSendFields is a list of field names (e.g. "Postback") to
9795	// unconditionally include in API requests. By default, fields with
9796	// empty values are omitted from API requests. However, any non-pointer,
9797	// non-interface field appearing in ForceSendFields will be sent to the
9798	// server regardless of whether the field is empty or not. This may be
9799	// used to include empty fields in Patch requests.
9800	ForceSendFields []string `json:"-"`
9801
9802	// NullFields is a list of field names (e.g. "Postback") to include in
9803	// API requests with the JSON null value. By default, fields with empty
9804	// values are omitted from API requests. However, any field with an
9805	// empty value appearing in NullFields will be sent to the server as
9806	// null. It is an error if a field in this list has a non-empty value.
9807	// This may be used to include null fields in Patch requests.
9808	NullFields []string `json:"-"`
9809}
9810
9811func (s *GoogleCloudDialogflowV2IntentMessageCardButton) MarshalJSON() ([]byte, error) {
9812	type NoMethod GoogleCloudDialogflowV2IntentMessageCardButton
9813	raw := NoMethod(*s)
9814	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9815}
9816
9817// GoogleCloudDialogflowV2IntentMessageCarouselSelect: The card for
9818// presenting a carousel of options to select from.
9819type GoogleCloudDialogflowV2IntentMessageCarouselSelect struct {
9820	// Items: Required. Carousel items.
9821	Items []*GoogleCloudDialogflowV2IntentMessageCarouselSelectItem `json:"items,omitempty"`
9822
9823	// ForceSendFields is a list of field names (e.g. "Items") to
9824	// unconditionally include in API requests. By default, fields with
9825	// empty values are omitted from API requests. However, any non-pointer,
9826	// non-interface field appearing in ForceSendFields will be sent to the
9827	// server regardless of whether the field is empty or not. This may be
9828	// used to include empty fields in Patch requests.
9829	ForceSendFields []string `json:"-"`
9830
9831	// NullFields is a list of field names (e.g. "Items") to include in API
9832	// requests with the JSON null value. By default, fields with empty
9833	// values are omitted from API requests. However, any field with an
9834	// empty value appearing in NullFields will be sent to the server as
9835	// null. It is an error if a field in this list has a non-empty value.
9836	// This may be used to include null fields in Patch requests.
9837	NullFields []string `json:"-"`
9838}
9839
9840func (s *GoogleCloudDialogflowV2IntentMessageCarouselSelect) MarshalJSON() ([]byte, error) {
9841	type NoMethod GoogleCloudDialogflowV2IntentMessageCarouselSelect
9842	raw := NoMethod(*s)
9843	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9844}
9845
9846// GoogleCloudDialogflowV2IntentMessageCarouselSelectItem: An item in
9847// the carousel.
9848type GoogleCloudDialogflowV2IntentMessageCarouselSelectItem struct {
9849	// Description: Optional. The body text of the card.
9850	Description string `json:"description,omitempty"`
9851
9852	// Image: Optional. The image to display.
9853	Image *GoogleCloudDialogflowV2IntentMessageImage `json:"image,omitempty"`
9854
9855	// Info: Required. Additional info about the option item.
9856	Info *GoogleCloudDialogflowV2IntentMessageSelectItemInfo `json:"info,omitempty"`
9857
9858	// Title: Required. Title of the carousel item.
9859	Title string `json:"title,omitempty"`
9860
9861	// ForceSendFields is a list of field names (e.g. "Description") to
9862	// unconditionally include in API requests. By default, fields with
9863	// empty values are omitted from API requests. However, any non-pointer,
9864	// non-interface field appearing in ForceSendFields will be sent to the
9865	// server regardless of whether the field is empty or not. This may be
9866	// used to include empty fields in Patch requests.
9867	ForceSendFields []string `json:"-"`
9868
9869	// NullFields is a list of field names (e.g. "Description") to include
9870	// in API requests with the JSON null value. By default, fields with
9871	// empty values are omitted from API requests. However, any field with
9872	// an empty value appearing in NullFields will be sent to the server as
9873	// null. It is an error if a field in this list has a non-empty value.
9874	// This may be used to include null fields in Patch requests.
9875	NullFields []string `json:"-"`
9876}
9877
9878func (s *GoogleCloudDialogflowV2IntentMessageCarouselSelectItem) MarshalJSON() ([]byte, error) {
9879	type NoMethod GoogleCloudDialogflowV2IntentMessageCarouselSelectItem
9880	raw := NoMethod(*s)
9881	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9882}
9883
9884// GoogleCloudDialogflowV2IntentMessageColumnProperties: Column
9885// properties for TableCard.
9886type GoogleCloudDialogflowV2IntentMessageColumnProperties struct {
9887	// Header: Required. Column heading.
9888	Header string `json:"header,omitempty"`
9889
9890	// HorizontalAlignment: Optional. Defines text alignment for all cells
9891	// in this column.
9892	//
9893	// Possible values:
9894	//   "HORIZONTAL_ALIGNMENT_UNSPECIFIED" - Text is aligned to the leading
9895	// edge of the column.
9896	//   "LEADING" - Text is aligned to the leading edge of the column.
9897	//   "CENTER" - Text is centered in the column.
9898	//   "TRAILING" - Text is aligned to the trailing edge of the column.
9899	HorizontalAlignment string `json:"horizontalAlignment,omitempty"`
9900
9901	// ForceSendFields is a list of field names (e.g. "Header") to
9902	// unconditionally include in API requests. By default, fields with
9903	// empty values are omitted from API requests. However, any non-pointer,
9904	// non-interface field appearing in ForceSendFields will be sent to the
9905	// server regardless of whether the field is empty or not. This may be
9906	// used to include empty fields in Patch requests.
9907	ForceSendFields []string `json:"-"`
9908
9909	// NullFields is a list of field names (e.g. "Header") to include in API
9910	// requests with the JSON null value. By default, fields with empty
9911	// values are omitted from API requests. However, any field with an
9912	// empty value appearing in NullFields will be sent to the server as
9913	// null. It is an error if a field in this list has a non-empty value.
9914	// This may be used to include null fields in Patch requests.
9915	NullFields []string `json:"-"`
9916}
9917
9918func (s *GoogleCloudDialogflowV2IntentMessageColumnProperties) MarshalJSON() ([]byte, error) {
9919	type NoMethod GoogleCloudDialogflowV2IntentMessageColumnProperties
9920	raw := NoMethod(*s)
9921	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9922}
9923
9924// GoogleCloudDialogflowV2IntentMessageImage: The image response
9925// message.
9926type GoogleCloudDialogflowV2IntentMessageImage struct {
9927	// AccessibilityText: Optional. A text description of the image to be
9928	// used for accessibility, e.g., screen readers.
9929	AccessibilityText string `json:"accessibilityText,omitempty"`
9930
9931	// ImageUri: Optional. The public URI to an image file.
9932	ImageUri string `json:"imageUri,omitempty"`
9933
9934	// ForceSendFields is a list of field names (e.g. "AccessibilityText")
9935	// to unconditionally include in API requests. By default, fields with
9936	// empty values are omitted from API requests. However, any non-pointer,
9937	// non-interface field appearing in ForceSendFields will be sent to the
9938	// server regardless of whether the field is empty or not. This may be
9939	// used to include empty fields in Patch requests.
9940	ForceSendFields []string `json:"-"`
9941
9942	// NullFields is a list of field names (e.g. "AccessibilityText") to
9943	// include in API requests with the JSON null value. By default, fields
9944	// with empty values are omitted from API requests. However, any field
9945	// with an empty value appearing in NullFields will be sent to the
9946	// server as null. It is an error if a field in this list has a
9947	// non-empty value. This may be used to include null fields in Patch
9948	// requests.
9949	NullFields []string `json:"-"`
9950}
9951
9952func (s *GoogleCloudDialogflowV2IntentMessageImage) MarshalJSON() ([]byte, error) {
9953	type NoMethod GoogleCloudDialogflowV2IntentMessageImage
9954	raw := NoMethod(*s)
9955	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9956}
9957
9958// GoogleCloudDialogflowV2IntentMessageLinkOutSuggestion: The suggestion
9959// chip message that allows the user to jump out to the app or website
9960// associated with this agent.
9961type GoogleCloudDialogflowV2IntentMessageLinkOutSuggestion struct {
9962	// DestinationName: Required. The name of the app or site this chip is
9963	// linking to.
9964	DestinationName string `json:"destinationName,omitempty"`
9965
9966	// Uri: Required. The URI of the app or site to open when the user taps
9967	// the suggestion chip.
9968	Uri string `json:"uri,omitempty"`
9969
9970	// ForceSendFields is a list of field names (e.g. "DestinationName") to
9971	// unconditionally include in API requests. By default, fields with
9972	// empty values are omitted from API requests. However, any non-pointer,
9973	// non-interface field appearing in ForceSendFields will be sent to the
9974	// server regardless of whether the field is empty or not. This may be
9975	// used to include empty fields in Patch requests.
9976	ForceSendFields []string `json:"-"`
9977
9978	// NullFields is a list of field names (e.g. "DestinationName") to
9979	// include in API requests with the JSON null value. By default, fields
9980	// with empty values are omitted from API requests. However, any field
9981	// with an empty value appearing in NullFields will be sent to the
9982	// server as null. It is an error if a field in this list has a
9983	// non-empty value. This may be used to include null fields in Patch
9984	// requests.
9985	NullFields []string `json:"-"`
9986}
9987
9988func (s *GoogleCloudDialogflowV2IntentMessageLinkOutSuggestion) MarshalJSON() ([]byte, error) {
9989	type NoMethod GoogleCloudDialogflowV2IntentMessageLinkOutSuggestion
9990	raw := NoMethod(*s)
9991	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9992}
9993
9994// GoogleCloudDialogflowV2IntentMessageListSelect: The card for
9995// presenting a list of options to select from.
9996type GoogleCloudDialogflowV2IntentMessageListSelect struct {
9997	// Items: Required. List items.
9998	Items []*GoogleCloudDialogflowV2IntentMessageListSelectItem `json:"items,omitempty"`
9999
10000	// Subtitle: Optional. Subtitle of the list.
10001	Subtitle string `json:"subtitle,omitempty"`
10002
10003	// Title: Optional. The overall title of the list.
10004	Title string `json:"title,omitempty"`
10005
10006	// ForceSendFields is a list of field names (e.g. "Items") to
10007	// unconditionally include in API requests. By default, fields with
10008	// empty values are omitted from API requests. However, any non-pointer,
10009	// non-interface field appearing in ForceSendFields will be sent to the
10010	// server regardless of whether the field is empty or not. This may be
10011	// used to include empty fields in Patch requests.
10012	ForceSendFields []string `json:"-"`
10013
10014	// NullFields is a list of field names (e.g. "Items") to include in API
10015	// requests with the JSON null value. By default, fields with empty
10016	// values are omitted from API requests. However, any field with an
10017	// empty value appearing in NullFields will be sent to the server as
10018	// null. It is an error if a field in this list has a non-empty value.
10019	// This may be used to include null fields in Patch requests.
10020	NullFields []string `json:"-"`
10021}
10022
10023func (s *GoogleCloudDialogflowV2IntentMessageListSelect) MarshalJSON() ([]byte, error) {
10024	type NoMethod GoogleCloudDialogflowV2IntentMessageListSelect
10025	raw := NoMethod(*s)
10026	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10027}
10028
10029// GoogleCloudDialogflowV2IntentMessageListSelectItem: An item in the
10030// list.
10031type GoogleCloudDialogflowV2IntentMessageListSelectItem struct {
10032	// Description: Optional. The main text describing the item.
10033	Description string `json:"description,omitempty"`
10034
10035	// Image: Optional. The image to display.
10036	Image *GoogleCloudDialogflowV2IntentMessageImage `json:"image,omitempty"`
10037
10038	// Info: Required. Additional information about this option.
10039	Info *GoogleCloudDialogflowV2IntentMessageSelectItemInfo `json:"info,omitempty"`
10040
10041	// Title: Required. The title of the list item.
10042	Title string `json:"title,omitempty"`
10043
10044	// ForceSendFields is a list of field names (e.g. "Description") to
10045	// unconditionally include in API requests. By default, fields with
10046	// empty values are omitted from API requests. However, any non-pointer,
10047	// non-interface field appearing in ForceSendFields will be sent to the
10048	// server regardless of whether the field is empty or not. This may be
10049	// used to include empty fields in Patch requests.
10050	ForceSendFields []string `json:"-"`
10051
10052	// NullFields is a list of field names (e.g. "Description") to include
10053	// in API requests with the JSON null value. By default, fields with
10054	// empty values are omitted from API requests. However, any field with
10055	// an empty value appearing in NullFields will be sent to the server as
10056	// null. It is an error if a field in this list has a non-empty value.
10057	// This may be used to include null fields in Patch requests.
10058	NullFields []string `json:"-"`
10059}
10060
10061func (s *GoogleCloudDialogflowV2IntentMessageListSelectItem) MarshalJSON() ([]byte, error) {
10062	type NoMethod GoogleCloudDialogflowV2IntentMessageListSelectItem
10063	raw := NoMethod(*s)
10064	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10065}
10066
10067// GoogleCloudDialogflowV2IntentMessageMediaContent: The media content
10068// card for Actions on Google.
10069type GoogleCloudDialogflowV2IntentMessageMediaContent struct {
10070	// MediaObjects: Required. List of media objects.
10071	MediaObjects []*GoogleCloudDialogflowV2IntentMessageMediaContentResponseMediaObject `json:"mediaObjects,omitempty"`
10072
10073	// MediaType: Optional. What type of media is the content (ie "audio").
10074	//
10075	// Possible values:
10076	//   "RESPONSE_MEDIA_TYPE_UNSPECIFIED" - Unspecified.
10077	//   "AUDIO" - Response media type is audio.
10078	MediaType string `json:"mediaType,omitempty"`
10079
10080	// ForceSendFields is a list of field names (e.g. "MediaObjects") to
10081	// unconditionally include in API requests. By default, fields with
10082	// empty values are omitted from API requests. However, any non-pointer,
10083	// non-interface field appearing in ForceSendFields will be sent to the
10084	// server regardless of whether the field is empty or not. This may be
10085	// used to include empty fields in Patch requests.
10086	ForceSendFields []string `json:"-"`
10087
10088	// NullFields is a list of field names (e.g. "MediaObjects") to include
10089	// in API requests with the JSON null value. By default, fields with
10090	// empty values are omitted from API requests. However, any field with
10091	// an empty value appearing in NullFields will be sent to the server as
10092	// null. It is an error if a field in this list has a non-empty value.
10093	// This may be used to include null fields in Patch requests.
10094	NullFields []string `json:"-"`
10095}
10096
10097func (s *GoogleCloudDialogflowV2IntentMessageMediaContent) MarshalJSON() ([]byte, error) {
10098	type NoMethod GoogleCloudDialogflowV2IntentMessageMediaContent
10099	raw := NoMethod(*s)
10100	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10101}
10102
10103// GoogleCloudDialogflowV2IntentMessageMediaContentResponseMediaObject:
10104// Response media object for media content card.
10105type GoogleCloudDialogflowV2IntentMessageMediaContentResponseMediaObject struct {
10106	// ContentUrl: Required. Url where the media is stored.
10107	ContentUrl string `json:"contentUrl,omitempty"`
10108
10109	// Description: Optional. Description of media card.
10110	Description string `json:"description,omitempty"`
10111
10112	// Icon: Optional. Icon to display above media content.
10113	Icon *GoogleCloudDialogflowV2IntentMessageImage `json:"icon,omitempty"`
10114
10115	// LargeImage: Optional. Image to display above media content.
10116	LargeImage *GoogleCloudDialogflowV2IntentMessageImage `json:"largeImage,omitempty"`
10117
10118	// Name: Required. Name of media card.
10119	Name string `json:"name,omitempty"`
10120
10121	// ForceSendFields is a list of field names (e.g. "ContentUrl") to
10122	// unconditionally include in API requests. By default, fields with
10123	// empty values are omitted from API requests. However, any non-pointer,
10124	// non-interface field appearing in ForceSendFields will be sent to the
10125	// server regardless of whether the field is empty or not. This may be
10126	// used to include empty fields in Patch requests.
10127	ForceSendFields []string `json:"-"`
10128
10129	// NullFields is a list of field names (e.g. "ContentUrl") to include in
10130	// API requests with the JSON null value. By default, fields with empty
10131	// values are omitted from API requests. However, any field with an
10132	// empty value appearing in NullFields will be sent to the server as
10133	// null. It is an error if a field in this list has a non-empty value.
10134	// This may be used to include null fields in Patch requests.
10135	NullFields []string `json:"-"`
10136}
10137
10138func (s *GoogleCloudDialogflowV2IntentMessageMediaContentResponseMediaObject) MarshalJSON() ([]byte, error) {
10139	type NoMethod GoogleCloudDialogflowV2IntentMessageMediaContentResponseMediaObject
10140	raw := NoMethod(*s)
10141	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10142}
10143
10144// GoogleCloudDialogflowV2IntentMessageQuickReplies: The quick replies
10145// response message.
10146type GoogleCloudDialogflowV2IntentMessageQuickReplies struct {
10147	// QuickReplies: Optional. The collection of quick replies.
10148	QuickReplies []string `json:"quickReplies,omitempty"`
10149
10150	// Title: Optional. The title of the collection of quick replies.
10151	Title string `json:"title,omitempty"`
10152
10153	// ForceSendFields is a list of field names (e.g. "QuickReplies") to
10154	// unconditionally include in API requests. By default, fields with
10155	// empty values are omitted from API requests. However, any non-pointer,
10156	// non-interface field appearing in ForceSendFields will be sent to the
10157	// server regardless of whether the field is empty or not. This may be
10158	// used to include empty fields in Patch requests.
10159	ForceSendFields []string `json:"-"`
10160
10161	// NullFields is a list of field names (e.g. "QuickReplies") to include
10162	// in API requests with the JSON null value. By default, fields with
10163	// empty values are omitted from API requests. However, any field with
10164	// an empty value appearing in NullFields will be sent to the server as
10165	// null. It is an error if a field in this list has a non-empty value.
10166	// This may be used to include null fields in Patch requests.
10167	NullFields []string `json:"-"`
10168}
10169
10170func (s *GoogleCloudDialogflowV2IntentMessageQuickReplies) MarshalJSON() ([]byte, error) {
10171	type NoMethod GoogleCloudDialogflowV2IntentMessageQuickReplies
10172	raw := NoMethod(*s)
10173	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10174}
10175
10176// GoogleCloudDialogflowV2IntentMessageSelectItemInfo: Additional info
10177// about the select item for when it is triggered in a dialog.
10178type GoogleCloudDialogflowV2IntentMessageSelectItemInfo struct {
10179	// Key: Required. A unique key that will be sent back to the agent if
10180	// this response is given.
10181	Key string `json:"key,omitempty"`
10182
10183	// Synonyms: Optional. A list of synonyms that can also be used to
10184	// trigger this item in dialog.
10185	Synonyms []string `json:"synonyms,omitempty"`
10186
10187	// ForceSendFields is a list of field names (e.g. "Key") to
10188	// unconditionally include in API requests. By default, fields with
10189	// empty values are omitted from API requests. However, any non-pointer,
10190	// non-interface field appearing in ForceSendFields will be sent to the
10191	// server regardless of whether the field is empty or not. This may be
10192	// used to include empty fields in Patch requests.
10193	ForceSendFields []string `json:"-"`
10194
10195	// NullFields is a list of field names (e.g. "Key") to include in API
10196	// requests with the JSON null value. By default, fields with empty
10197	// values are omitted from API requests. However, any field with an
10198	// empty value appearing in NullFields will be sent to the server as
10199	// null. It is an error if a field in this list has a non-empty value.
10200	// This may be used to include null fields in Patch requests.
10201	NullFields []string `json:"-"`
10202}
10203
10204func (s *GoogleCloudDialogflowV2IntentMessageSelectItemInfo) MarshalJSON() ([]byte, error) {
10205	type NoMethod GoogleCloudDialogflowV2IntentMessageSelectItemInfo
10206	raw := NoMethod(*s)
10207	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10208}
10209
10210// GoogleCloudDialogflowV2IntentMessageSimpleResponse: The simple
10211// response message containing speech or text.
10212type GoogleCloudDialogflowV2IntentMessageSimpleResponse struct {
10213	// DisplayText: Optional. The text to display.
10214	DisplayText string `json:"displayText,omitempty"`
10215
10216	// Ssml: One of text_to_speech or ssml must be provided. Structured
10217	// spoken response to the user in the SSML format. Mutually exclusive
10218	// with text_to_speech.
10219	Ssml string `json:"ssml,omitempty"`
10220
10221	// TextToSpeech: One of text_to_speech or ssml must be provided. The
10222	// plain text of the speech output. Mutually exclusive with ssml.
10223	TextToSpeech string `json:"textToSpeech,omitempty"`
10224
10225	// ForceSendFields is a list of field names (e.g. "DisplayText") to
10226	// unconditionally include in API requests. By default, fields with
10227	// empty values are omitted from API requests. However, any non-pointer,
10228	// non-interface field appearing in ForceSendFields will be sent to the
10229	// server regardless of whether the field is empty or not. This may be
10230	// used to include empty fields in Patch requests.
10231	ForceSendFields []string `json:"-"`
10232
10233	// NullFields is a list of field names (e.g. "DisplayText") to include
10234	// in API requests with the JSON null value. By default, fields with
10235	// empty values are omitted from API requests. However, any field with
10236	// an empty value appearing in NullFields will be sent to the server as
10237	// null. It is an error if a field in this list has a non-empty value.
10238	// This may be used to include null fields in Patch requests.
10239	NullFields []string `json:"-"`
10240}
10241
10242func (s *GoogleCloudDialogflowV2IntentMessageSimpleResponse) MarshalJSON() ([]byte, error) {
10243	type NoMethod GoogleCloudDialogflowV2IntentMessageSimpleResponse
10244	raw := NoMethod(*s)
10245	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10246}
10247
10248// GoogleCloudDialogflowV2IntentMessageSimpleResponses: The collection
10249// of simple response candidates. This message in
10250// `QueryResult.fulfillment_messages` and
10251// `WebhookResponse.fulfillment_messages` should contain only one
10252// `SimpleResponse`.
10253type GoogleCloudDialogflowV2IntentMessageSimpleResponses struct {
10254	// SimpleResponses: Required. The list of simple responses.
10255	SimpleResponses []*GoogleCloudDialogflowV2IntentMessageSimpleResponse `json:"simpleResponses,omitempty"`
10256
10257	// ForceSendFields is a list of field names (e.g. "SimpleResponses") to
10258	// unconditionally include in API requests. By default, fields with
10259	// empty values are omitted from API requests. However, any non-pointer,
10260	// non-interface field appearing in ForceSendFields will be sent to the
10261	// server regardless of whether the field is empty or not. This may be
10262	// used to include empty fields in Patch requests.
10263	ForceSendFields []string `json:"-"`
10264
10265	// NullFields is a list of field names (e.g. "SimpleResponses") to
10266	// include in API requests with the JSON null value. By default, fields
10267	// with empty values are omitted from API requests. However, any field
10268	// with an empty value appearing in NullFields will be sent to the
10269	// server as null. It is an error if a field in this list has a
10270	// non-empty value. This may be used to include null fields in Patch
10271	// requests.
10272	NullFields []string `json:"-"`
10273}
10274
10275func (s *GoogleCloudDialogflowV2IntentMessageSimpleResponses) MarshalJSON() ([]byte, error) {
10276	type NoMethod GoogleCloudDialogflowV2IntentMessageSimpleResponses
10277	raw := NoMethod(*s)
10278	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10279}
10280
10281// GoogleCloudDialogflowV2IntentMessageSuggestion: The suggestion chip
10282// message that the user can tap to quickly post a reply to the
10283// conversation.
10284type GoogleCloudDialogflowV2IntentMessageSuggestion struct {
10285	// Title: Required. The text shown the in the suggestion chip.
10286	Title string `json:"title,omitempty"`
10287
10288	// ForceSendFields is a list of field names (e.g. "Title") to
10289	// unconditionally include in API requests. By default, fields with
10290	// empty values are omitted from API requests. However, any non-pointer,
10291	// non-interface field appearing in ForceSendFields will be sent to the
10292	// server regardless of whether the field is empty or not. This may be
10293	// used to include empty fields in Patch requests.
10294	ForceSendFields []string `json:"-"`
10295
10296	// NullFields is a list of field names (e.g. "Title") to include in API
10297	// requests with the JSON null value. By default, fields with empty
10298	// values are omitted from API requests. However, any field with an
10299	// empty value appearing in NullFields will be sent to the server as
10300	// null. It is an error if a field in this list has a non-empty value.
10301	// This may be used to include null fields in Patch requests.
10302	NullFields []string `json:"-"`
10303}
10304
10305func (s *GoogleCloudDialogflowV2IntentMessageSuggestion) MarshalJSON() ([]byte, error) {
10306	type NoMethod GoogleCloudDialogflowV2IntentMessageSuggestion
10307	raw := NoMethod(*s)
10308	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10309}
10310
10311// GoogleCloudDialogflowV2IntentMessageSuggestions: The collection of
10312// suggestions.
10313type GoogleCloudDialogflowV2IntentMessageSuggestions struct {
10314	// Suggestions: Required. The list of suggested replies.
10315	Suggestions []*GoogleCloudDialogflowV2IntentMessageSuggestion `json:"suggestions,omitempty"`
10316
10317	// ForceSendFields is a list of field names (e.g. "Suggestions") to
10318	// unconditionally include in API requests. By default, fields with
10319	// empty values are omitted from API requests. However, any non-pointer,
10320	// non-interface field appearing in ForceSendFields will be sent to the
10321	// server regardless of whether the field is empty or not. This may be
10322	// used to include empty fields in Patch requests.
10323	ForceSendFields []string `json:"-"`
10324
10325	// NullFields is a list of field names (e.g. "Suggestions") to include
10326	// in API requests with the JSON null value. By default, fields with
10327	// empty values are omitted from API requests. However, any field with
10328	// an empty value appearing in NullFields will be sent to the server as
10329	// null. It is an error if a field in this list has a non-empty value.
10330	// This may be used to include null fields in Patch requests.
10331	NullFields []string `json:"-"`
10332}
10333
10334func (s *GoogleCloudDialogflowV2IntentMessageSuggestions) MarshalJSON() ([]byte, error) {
10335	type NoMethod GoogleCloudDialogflowV2IntentMessageSuggestions
10336	raw := NoMethod(*s)
10337	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10338}
10339
10340// GoogleCloudDialogflowV2IntentMessageTableCard: Table card for Actions
10341// on Google.
10342type GoogleCloudDialogflowV2IntentMessageTableCard struct {
10343	// Buttons: Optional. List of buttons for the card.
10344	Buttons []*GoogleCloudDialogflowV2IntentMessageBasicCardButton `json:"buttons,omitempty"`
10345
10346	// ColumnProperties: Optional. Display properties for the columns in
10347	// this table.
10348	ColumnProperties []*GoogleCloudDialogflowV2IntentMessageColumnProperties `json:"columnProperties,omitempty"`
10349
10350	// Image: Optional. Image which should be displayed on the card.
10351	Image *GoogleCloudDialogflowV2IntentMessageImage `json:"image,omitempty"`
10352
10353	// Rows: Optional. Rows in this table of data.
10354	Rows []*GoogleCloudDialogflowV2IntentMessageTableCardRow `json:"rows,omitempty"`
10355
10356	// Subtitle: Optional. Subtitle to the title.
10357	Subtitle string `json:"subtitle,omitempty"`
10358
10359	// Title: Required. Title of the card.
10360	Title string `json:"title,omitempty"`
10361
10362	// ForceSendFields is a list of field names (e.g. "Buttons") to
10363	// unconditionally include in API requests. By default, fields with
10364	// empty values are omitted from API requests. However, any non-pointer,
10365	// non-interface field appearing in ForceSendFields will be sent to the
10366	// server regardless of whether the field is empty or not. This may be
10367	// used to include empty fields in Patch requests.
10368	ForceSendFields []string `json:"-"`
10369
10370	// NullFields is a list of field names (e.g. "Buttons") to include in
10371	// API requests with the JSON null value. By default, fields with empty
10372	// values are omitted from API requests. However, any field with an
10373	// empty value appearing in NullFields will be sent to the server as
10374	// null. It is an error if a field in this list has a non-empty value.
10375	// This may be used to include null fields in Patch requests.
10376	NullFields []string `json:"-"`
10377}
10378
10379func (s *GoogleCloudDialogflowV2IntentMessageTableCard) MarshalJSON() ([]byte, error) {
10380	type NoMethod GoogleCloudDialogflowV2IntentMessageTableCard
10381	raw := NoMethod(*s)
10382	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10383}
10384
10385// GoogleCloudDialogflowV2IntentMessageTableCardCell: Cell of
10386// TableCardRow.
10387type GoogleCloudDialogflowV2IntentMessageTableCardCell struct {
10388	// Text: Required. Text in this cell.
10389	Text string `json:"text,omitempty"`
10390
10391	// ForceSendFields is a list of field names (e.g. "Text") to
10392	// unconditionally include in API requests. By default, fields with
10393	// empty values are omitted from API requests. However, any non-pointer,
10394	// non-interface field appearing in ForceSendFields will be sent to the
10395	// server regardless of whether the field is empty or not. This may be
10396	// used to include empty fields in Patch requests.
10397	ForceSendFields []string `json:"-"`
10398
10399	// NullFields is a list of field names (e.g. "Text") to include in API
10400	// requests with the JSON null value. By default, fields with empty
10401	// values are omitted from API requests. However, any field with an
10402	// empty value appearing in NullFields will be sent to the server as
10403	// null. It is an error if a field in this list has a non-empty value.
10404	// This may be used to include null fields in Patch requests.
10405	NullFields []string `json:"-"`
10406}
10407
10408func (s *GoogleCloudDialogflowV2IntentMessageTableCardCell) MarshalJSON() ([]byte, error) {
10409	type NoMethod GoogleCloudDialogflowV2IntentMessageTableCardCell
10410	raw := NoMethod(*s)
10411	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10412}
10413
10414// GoogleCloudDialogflowV2IntentMessageTableCardRow: Row of TableCard.
10415type GoogleCloudDialogflowV2IntentMessageTableCardRow struct {
10416	// Cells: Optional. List of cells that make up this row.
10417	Cells []*GoogleCloudDialogflowV2IntentMessageTableCardCell `json:"cells,omitempty"`
10418
10419	// DividerAfter: Optional. Whether to add a visual divider after this
10420	// row.
10421	DividerAfter bool `json:"dividerAfter,omitempty"`
10422
10423	// ForceSendFields is a list of field names (e.g. "Cells") to
10424	// unconditionally include in API requests. By default, fields with
10425	// empty values are omitted from API requests. However, any non-pointer,
10426	// non-interface field appearing in ForceSendFields will be sent to the
10427	// server regardless of whether the field is empty or not. This may be
10428	// used to include empty fields in Patch requests.
10429	ForceSendFields []string `json:"-"`
10430
10431	// NullFields is a list of field names (e.g. "Cells") to include in API
10432	// requests with the JSON null value. By default, fields with empty
10433	// values are omitted from API requests. However, any field with an
10434	// empty value appearing in NullFields will be sent to the server as
10435	// null. It is an error if a field in this list has a non-empty value.
10436	// This may be used to include null fields in Patch requests.
10437	NullFields []string `json:"-"`
10438}
10439
10440func (s *GoogleCloudDialogflowV2IntentMessageTableCardRow) MarshalJSON() ([]byte, error) {
10441	type NoMethod GoogleCloudDialogflowV2IntentMessageTableCardRow
10442	raw := NoMethod(*s)
10443	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10444}
10445
10446// GoogleCloudDialogflowV2IntentMessageText: The text response message.
10447type GoogleCloudDialogflowV2IntentMessageText struct {
10448	// Text: Optional. The collection of the agent's responses.
10449	Text []string `json:"text,omitempty"`
10450
10451	// ForceSendFields is a list of field names (e.g. "Text") to
10452	// unconditionally include in API requests. By default, fields with
10453	// empty values are omitted from API requests. However, any non-pointer,
10454	// non-interface field appearing in ForceSendFields will be sent to the
10455	// server regardless of whether the field is empty or not. This may be
10456	// used to include empty fields in Patch requests.
10457	ForceSendFields []string `json:"-"`
10458
10459	// NullFields is a list of field names (e.g. "Text") to include in API
10460	// requests with the JSON null value. By default, fields with empty
10461	// values are omitted from API requests. However, any field with an
10462	// empty value appearing in NullFields will be sent to the server as
10463	// null. It is an error if a field in this list has a non-empty value.
10464	// This may be used to include null fields in Patch requests.
10465	NullFields []string `json:"-"`
10466}
10467
10468func (s *GoogleCloudDialogflowV2IntentMessageText) MarshalJSON() ([]byte, error) {
10469	type NoMethod GoogleCloudDialogflowV2IntentMessageText
10470	raw := NoMethod(*s)
10471	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10472}
10473
10474// GoogleCloudDialogflowV2IntentParameter: Represents intent parameters.
10475type GoogleCloudDialogflowV2IntentParameter struct {
10476	// DefaultValue: Optional. The default value to use when the `value`
10477	// yields an empty result. Default values can be extracted from contexts
10478	// by using the following syntax: `#context_name.parameter_name`.
10479	DefaultValue string `json:"defaultValue,omitempty"`
10480
10481	// DisplayName: Required. The name of the parameter.
10482	DisplayName string `json:"displayName,omitempty"`
10483
10484	// EntityTypeDisplayName: Optional. The name of the entity type,
10485	// prefixed with `@`, that describes values of the parameter. If the
10486	// parameter is required, this must be provided.
10487	EntityTypeDisplayName string `json:"entityTypeDisplayName,omitempty"`
10488
10489	// IsList: Optional. Indicates whether the parameter represents a list
10490	// of values.
10491	IsList bool `json:"isList,omitempty"`
10492
10493	// Mandatory: Optional. Indicates whether the parameter is required.
10494	// That is, whether the intent cannot be completed without collecting
10495	// the parameter value.
10496	Mandatory bool `json:"mandatory,omitempty"`
10497
10498	// Name: The unique identifier of this parameter.
10499	Name string `json:"name,omitempty"`
10500
10501	// Prompts: Optional. The collection of prompts that the agent can
10502	// present to the user in order to collect a value for the parameter.
10503	Prompts []string `json:"prompts,omitempty"`
10504
10505	// Value: Optional. The definition of the parameter value. It can be: -
10506	// a constant string, - a parameter value defined as `$parameter_name`,
10507	// - an original parameter value defined as `$parameter_name.original`,
10508	// - a parameter value from some context defined as
10509	// `#context_name.parameter_name`.
10510	Value string `json:"value,omitempty"`
10511
10512	// ForceSendFields is a list of field names (e.g. "DefaultValue") to
10513	// unconditionally include in API requests. By default, fields with
10514	// empty values are omitted from API requests. However, any non-pointer,
10515	// non-interface field appearing in ForceSendFields will be sent to the
10516	// server regardless of whether the field is empty or not. This may be
10517	// used to include empty fields in Patch requests.
10518	ForceSendFields []string `json:"-"`
10519
10520	// NullFields is a list of field names (e.g. "DefaultValue") to include
10521	// in API requests with the JSON null value. By default, fields with
10522	// empty values are omitted from API requests. However, any field with
10523	// an empty value appearing in NullFields will be sent to the server as
10524	// null. It is an error if a field in this list has a non-empty value.
10525	// This may be used to include null fields in Patch requests.
10526	NullFields []string `json:"-"`
10527}
10528
10529func (s *GoogleCloudDialogflowV2IntentParameter) MarshalJSON() ([]byte, error) {
10530	type NoMethod GoogleCloudDialogflowV2IntentParameter
10531	raw := NoMethod(*s)
10532	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10533}
10534
10535// GoogleCloudDialogflowV2IntentTrainingPhrase: Represents an example
10536// that the agent is trained on.
10537type GoogleCloudDialogflowV2IntentTrainingPhrase struct {
10538	// Name: Output only. The unique identifier of this training phrase.
10539	Name string `json:"name,omitempty"`
10540
10541	// Parts: Required. The ordered list of training phrase parts. The parts
10542	// are concatenated in order to form the training phrase. Note: The API
10543	// does not automatically annotate training phrases like the Dialogflow
10544	// Console does. Note: Do not forget to include whitespace at part
10545	// boundaries, so the training phrase is well formatted when the parts
10546	// are concatenated. If the training phrase does not need to be
10547	// annotated with parameters, you just need a single part with only the
10548	// Part.text field set. If you want to annotate the training phrase, you
10549	// must create multiple parts, where the fields of each part are
10550	// populated in one of two ways: - `Part.text` is set to a part of the
10551	// phrase that has no parameters. - `Part.text` is set to a part of the
10552	// phrase that you want to annotate, and the `entity_type`, `alias`, and
10553	// `user_defined` fields are all set.
10554	Parts []*GoogleCloudDialogflowV2IntentTrainingPhrasePart `json:"parts,omitempty"`
10555
10556	// TimesAddedCount: Optional. Indicates how many times this example was
10557	// added to the intent. Each time a developer adds an existing sample by
10558	// editing an intent or training, this counter is increased.
10559	TimesAddedCount int64 `json:"timesAddedCount,omitempty"`
10560
10561	// Type: Required. The type of the training phrase.
10562	//
10563	// Possible values:
10564	//   "TYPE_UNSPECIFIED" - Not specified. This value should never be
10565	// used.
10566	//   "EXAMPLE" - Examples do not contain @-prefixed entity type names,
10567	// but example parts can be annotated with entity types.
10568	//   "TEMPLATE" - Templates are not annotated with entity types, but
10569	// they can contain @-prefixed entity type names as substrings. Template
10570	// mode has been deprecated. Example mode is the only supported way to
10571	// create new training phrases. If you have existing training phrases
10572	// that you've created in template mode, those will continue to work.
10573	Type string `json:"type,omitempty"`
10574
10575	// ForceSendFields is a list of field names (e.g. "Name") to
10576	// unconditionally include in API requests. By default, fields with
10577	// empty values are omitted from API requests. However, any non-pointer,
10578	// non-interface field appearing in ForceSendFields will be sent to the
10579	// server regardless of whether the field is empty or not. This may be
10580	// used to include empty fields in Patch requests.
10581	ForceSendFields []string `json:"-"`
10582
10583	// NullFields is a list of field names (e.g. "Name") to include in API
10584	// requests with the JSON null value. By default, fields with empty
10585	// values are omitted from API requests. However, any field with an
10586	// empty value appearing in NullFields will be sent to the server as
10587	// null. It is an error if a field in this list has a non-empty value.
10588	// This may be used to include null fields in Patch requests.
10589	NullFields []string `json:"-"`
10590}
10591
10592func (s *GoogleCloudDialogflowV2IntentTrainingPhrase) MarshalJSON() ([]byte, error) {
10593	type NoMethod GoogleCloudDialogflowV2IntentTrainingPhrase
10594	raw := NoMethod(*s)
10595	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10596}
10597
10598// GoogleCloudDialogflowV2IntentTrainingPhrasePart: Represents a part of
10599// a training phrase.
10600type GoogleCloudDialogflowV2IntentTrainingPhrasePart struct {
10601	// Alias: Optional. The parameter name for the value extracted from the
10602	// annotated part of the example. This field is required for annotated
10603	// parts of the training phrase.
10604	Alias string `json:"alias,omitempty"`
10605
10606	// EntityType: Optional. The entity type name prefixed with `@`. This
10607	// field is required for annotated parts of the training phrase.
10608	EntityType string `json:"entityType,omitempty"`
10609
10610	// Text: Required. The text for this part.
10611	Text string `json:"text,omitempty"`
10612
10613	// UserDefined: Optional. Indicates whether the text was manually
10614	// annotated. This field is set to true when the Dialogflow Console is
10615	// used to manually annotate the part. When creating an annotated part
10616	// with the API, you must set this to true.
10617	UserDefined bool `json:"userDefined,omitempty"`
10618
10619	// ForceSendFields is a list of field names (e.g. "Alias") to
10620	// unconditionally include in API requests. By default, fields with
10621	// empty values are omitted from API requests. However, any non-pointer,
10622	// non-interface field appearing in ForceSendFields will be sent to the
10623	// server regardless of whether the field is empty or not. This may be
10624	// used to include empty fields in Patch requests.
10625	ForceSendFields []string `json:"-"`
10626
10627	// NullFields is a list of field names (e.g. "Alias") to include in API
10628	// requests with the JSON null value. By default, fields with empty
10629	// values are omitted from API requests. However, any field with an
10630	// empty value appearing in NullFields will be sent to the server as
10631	// null. It is an error if a field in this list has a non-empty value.
10632	// This may be used to include null fields in Patch requests.
10633	NullFields []string `json:"-"`
10634}
10635
10636func (s *GoogleCloudDialogflowV2IntentTrainingPhrasePart) MarshalJSON() ([]byte, error) {
10637	type NoMethod GoogleCloudDialogflowV2IntentTrainingPhrasePart
10638	raw := NoMethod(*s)
10639	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10640}
10641
10642// GoogleCloudDialogflowV2KnowledgeBase: A knowledge base represents a
10643// collection of knowledge documents that you provide to Dialogflow.
10644// Your knowledge documents contain information that may be useful
10645// during conversations with end-users. Some Dialogflow features use
10646// knowledge bases when looking for a response to an end-user input. For
10647// more information, see the knowledge base guide
10648// (https://cloud.google.com/dialogflow/docs/how/knowledge-bases). Note:
10649// The `projects.agent.knowledgeBases` resource is deprecated; only use
10650// `projects.knowledgeBases`.
10651type GoogleCloudDialogflowV2KnowledgeBase struct {
10652	// DisplayName: Required. The display name of the knowledge base. The
10653	// name must be 1024 bytes or less; otherwise, the creation request
10654	// fails.
10655	DisplayName string `json:"displayName,omitempty"`
10656
10657	// LanguageCode: Language which represents the KnowledgeBase. When the
10658	// KnowledgeBase is created/updated, expect this to be present for non
10659	// en-us languages. When unspecified, the default language code en-us
10660	// applies.
10661	LanguageCode string `json:"languageCode,omitempty"`
10662
10663	// Name: The knowledge base resource name. The name must be empty when
10664	// creating a knowledge base. Format:
10665	// `projects//locations//knowledgeBases/`.
10666	Name string `json:"name,omitempty"`
10667
10668	// ServerResponse contains the HTTP response code and headers from the
10669	// server.
10670	googleapi.ServerResponse `json:"-"`
10671
10672	// ForceSendFields is a list of field names (e.g. "DisplayName") to
10673	// unconditionally include in API requests. By default, fields with
10674	// empty values are omitted from API requests. However, any non-pointer,
10675	// non-interface field appearing in ForceSendFields will be sent to the
10676	// server regardless of whether the field is empty or not. This may be
10677	// used to include empty fields in Patch requests.
10678	ForceSendFields []string `json:"-"`
10679
10680	// NullFields is a list of field names (e.g. "DisplayName") to include
10681	// in API requests with the JSON null value. By default, fields with
10682	// empty values are omitted from API requests. However, any field with
10683	// an empty value appearing in NullFields will be sent to the server as
10684	// null. It is an error if a field in this list has a non-empty value.
10685	// This may be used to include null fields in Patch requests.
10686	NullFields []string `json:"-"`
10687}
10688
10689func (s *GoogleCloudDialogflowV2KnowledgeBase) MarshalJSON() ([]byte, error) {
10690	type NoMethod GoogleCloudDialogflowV2KnowledgeBase
10691	raw := NoMethod(*s)
10692	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10693}
10694
10695// GoogleCloudDialogflowV2KnowledgeOperationMetadata: Metadata in
10696// google::longrunning::Operation for Knowledge operations.
10697type GoogleCloudDialogflowV2KnowledgeOperationMetadata struct {
10698	// State: Output only. The current state of this operation.
10699	//
10700	// Possible values:
10701	//   "STATE_UNSPECIFIED" - State unspecified.
10702	//   "PENDING" - The operation has been created.
10703	//   "RUNNING" - The operation is currently running.
10704	//   "DONE" - The operation is done, either cancelled or completed.
10705	State string `json:"state,omitempty"`
10706
10707	// ForceSendFields is a list of field names (e.g. "State") to
10708	// unconditionally include in API requests. By default, fields with
10709	// empty values are omitted from API requests. However, any non-pointer,
10710	// non-interface field appearing in ForceSendFields will be sent to the
10711	// server regardless of whether the field is empty or not. This may be
10712	// used to include empty fields in Patch requests.
10713	ForceSendFields []string `json:"-"`
10714
10715	// NullFields is a list of field names (e.g. "State") to include in API
10716	// requests with the JSON null value. By default, fields with empty
10717	// values are omitted from API requests. However, any field with an
10718	// empty value appearing in NullFields will be sent to the server as
10719	// null. It is an error if a field in this list has a non-empty value.
10720	// This may be used to include null fields in Patch requests.
10721	NullFields []string `json:"-"`
10722}
10723
10724func (s *GoogleCloudDialogflowV2KnowledgeOperationMetadata) MarshalJSON() ([]byte, error) {
10725	type NoMethod GoogleCloudDialogflowV2KnowledgeOperationMetadata
10726	raw := NoMethod(*s)
10727	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10728}
10729
10730// GoogleCloudDialogflowV2ListAnswerRecordsResponse: Response message
10731// for AnswerRecords.ListAnswerRecords.
10732type GoogleCloudDialogflowV2ListAnswerRecordsResponse struct {
10733	// AnswerRecords: The list of answer records.
10734	AnswerRecords []*GoogleCloudDialogflowV2AnswerRecord `json:"answerRecords,omitempty"`
10735
10736	// NextPageToken: A token to retrieve next page of results. Or empty if
10737	// there are no more results. Pass this value in the
10738	// ListAnswerRecordsRequest.page_token field in the subsequent call to
10739	// `ListAnswerRecords` method to retrieve the next page of results.
10740	NextPageToken string `json:"nextPageToken,omitempty"`
10741
10742	// ServerResponse contains the HTTP response code and headers from the
10743	// server.
10744	googleapi.ServerResponse `json:"-"`
10745
10746	// ForceSendFields is a list of field names (e.g. "AnswerRecords") to
10747	// unconditionally include in API requests. By default, fields with
10748	// empty values are omitted from API requests. However, any non-pointer,
10749	// non-interface field appearing in ForceSendFields will be sent to the
10750	// server regardless of whether the field is empty or not. This may be
10751	// used to include empty fields in Patch requests.
10752	ForceSendFields []string `json:"-"`
10753
10754	// NullFields is a list of field names (e.g. "AnswerRecords") to include
10755	// in API requests with the JSON null value. By default, fields with
10756	// empty values are omitted from API requests. However, any field with
10757	// an empty value appearing in NullFields will be sent to the server as
10758	// null. It is an error if a field in this list has a non-empty value.
10759	// This may be used to include null fields in Patch requests.
10760	NullFields []string `json:"-"`
10761}
10762
10763func (s *GoogleCloudDialogflowV2ListAnswerRecordsResponse) MarshalJSON() ([]byte, error) {
10764	type NoMethod GoogleCloudDialogflowV2ListAnswerRecordsResponse
10765	raw := NoMethod(*s)
10766	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10767}
10768
10769// GoogleCloudDialogflowV2ListContextsResponse: The response message for
10770// Contexts.ListContexts.
10771type GoogleCloudDialogflowV2ListContextsResponse struct {
10772	// Contexts: The list of contexts. There will be a maximum number of
10773	// items returned based on the page_size field in the request.
10774	Contexts []*GoogleCloudDialogflowV2Context `json:"contexts,omitempty"`
10775
10776	// NextPageToken: Token to retrieve the next page of results, or empty
10777	// if there are no more results in the list.
10778	NextPageToken string `json:"nextPageToken,omitempty"`
10779
10780	// ServerResponse contains the HTTP response code and headers from the
10781	// server.
10782	googleapi.ServerResponse `json:"-"`
10783
10784	// ForceSendFields is a list of field names (e.g. "Contexts") to
10785	// unconditionally include in API requests. By default, fields with
10786	// empty values are omitted from API requests. However, any non-pointer,
10787	// non-interface field appearing in ForceSendFields will be sent to the
10788	// server regardless of whether the field is empty or not. This may be
10789	// used to include empty fields in Patch requests.
10790	ForceSendFields []string `json:"-"`
10791
10792	// NullFields is a list of field names (e.g. "Contexts") to include in
10793	// API requests with the JSON null value. By default, fields with empty
10794	// values are omitted from API requests. However, any field with an
10795	// empty value appearing in NullFields will be sent to the server as
10796	// null. It is an error if a field in this list has a non-empty value.
10797	// This may be used to include null fields in Patch requests.
10798	NullFields []string `json:"-"`
10799}
10800
10801func (s *GoogleCloudDialogflowV2ListContextsResponse) MarshalJSON() ([]byte, error) {
10802	type NoMethod GoogleCloudDialogflowV2ListContextsResponse
10803	raw := NoMethod(*s)
10804	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10805}
10806
10807// GoogleCloudDialogflowV2ListConversationProfilesResponse: The response
10808// message for ConversationProfiles.ListConversationProfiles.
10809type GoogleCloudDialogflowV2ListConversationProfilesResponse struct {
10810	// ConversationProfiles: The list of project conversation profiles.
10811	// There is a maximum number of items returned based on the page_size
10812	// field in the request.
10813	ConversationProfiles []*GoogleCloudDialogflowV2ConversationProfile `json:"conversationProfiles,omitempty"`
10814
10815	// NextPageToken: Token to retrieve the next page of results, or empty
10816	// if there are no more results in the list.
10817	NextPageToken string `json:"nextPageToken,omitempty"`
10818
10819	// ServerResponse contains the HTTP response code and headers from the
10820	// server.
10821	googleapi.ServerResponse `json:"-"`
10822
10823	// ForceSendFields is a list of field names (e.g.
10824	// "ConversationProfiles") to unconditionally include in API requests.
10825	// By default, fields with empty values are omitted from API requests.
10826	// However, any non-pointer, non-interface field appearing in
10827	// ForceSendFields will be sent to the server regardless of whether the
10828	// field is empty or not. This may be used to include empty fields in
10829	// Patch requests.
10830	ForceSendFields []string `json:"-"`
10831
10832	// NullFields is a list of field names (e.g. "ConversationProfiles") to
10833	// include in API requests with the JSON null value. By default, fields
10834	// with empty values are omitted from API requests. However, any field
10835	// with an empty value appearing in NullFields will be sent to the
10836	// server as null. It is an error if a field in this list has a
10837	// non-empty value. This may be used to include null fields in Patch
10838	// requests.
10839	NullFields []string `json:"-"`
10840}
10841
10842func (s *GoogleCloudDialogflowV2ListConversationProfilesResponse) MarshalJSON() ([]byte, error) {
10843	type NoMethod GoogleCloudDialogflowV2ListConversationProfilesResponse
10844	raw := NoMethod(*s)
10845	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10846}
10847
10848// GoogleCloudDialogflowV2ListConversationsResponse: The response
10849// message for Conversations.ListConversations.
10850type GoogleCloudDialogflowV2ListConversationsResponse struct {
10851	// Conversations: The list of conversations. There will be a maximum
10852	// number of items returned based on the page_size field in the request.
10853	Conversations []*GoogleCloudDialogflowV2Conversation `json:"conversations,omitempty"`
10854
10855	// NextPageToken: Token to retrieve the next page of results, or empty
10856	// if there are no more results in the list.
10857	NextPageToken string `json:"nextPageToken,omitempty"`
10858
10859	// ServerResponse contains the HTTP response code and headers from the
10860	// server.
10861	googleapi.ServerResponse `json:"-"`
10862
10863	// ForceSendFields is a list of field names (e.g. "Conversations") to
10864	// unconditionally include in API requests. By default, fields with
10865	// empty values are omitted from API requests. However, any non-pointer,
10866	// non-interface field appearing in ForceSendFields will be sent to the
10867	// server regardless of whether the field is empty or not. This may be
10868	// used to include empty fields in Patch requests.
10869	ForceSendFields []string `json:"-"`
10870
10871	// NullFields is a list of field names (e.g. "Conversations") to include
10872	// in API requests with the JSON null value. By default, fields with
10873	// empty values are omitted from API requests. However, any field with
10874	// an empty value appearing in NullFields will be sent to the server as
10875	// null. It is an error if a field in this list has a non-empty value.
10876	// This may be used to include null fields in Patch requests.
10877	NullFields []string `json:"-"`
10878}
10879
10880func (s *GoogleCloudDialogflowV2ListConversationsResponse) MarshalJSON() ([]byte, error) {
10881	type NoMethod GoogleCloudDialogflowV2ListConversationsResponse
10882	raw := NoMethod(*s)
10883	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10884}
10885
10886// GoogleCloudDialogflowV2ListDocumentsResponse: Response message for
10887// Documents.ListDocuments.
10888type GoogleCloudDialogflowV2ListDocumentsResponse struct {
10889	// Documents: The list of documents.
10890	Documents []*GoogleCloudDialogflowV2Document `json:"documents,omitempty"`
10891
10892	// NextPageToken: Token to retrieve the next page of results, or empty
10893	// if there are no more results in the list.
10894	NextPageToken string `json:"nextPageToken,omitempty"`
10895
10896	// ServerResponse contains the HTTP response code and headers from the
10897	// server.
10898	googleapi.ServerResponse `json:"-"`
10899
10900	// ForceSendFields is a list of field names (e.g. "Documents") to
10901	// unconditionally include in API requests. By default, fields with
10902	// empty values are omitted from API requests. However, any non-pointer,
10903	// non-interface field appearing in ForceSendFields will be sent to the
10904	// server regardless of whether the field is empty or not. This may be
10905	// used to include empty fields in Patch requests.
10906	ForceSendFields []string `json:"-"`
10907
10908	// NullFields is a list of field names (e.g. "Documents") to include in
10909	// API requests with the JSON null value. By default, fields with empty
10910	// values are omitted from API requests. However, any field with an
10911	// empty value appearing in NullFields will be sent to the server as
10912	// null. It is an error if a field in this list has a non-empty value.
10913	// This may be used to include null fields in Patch requests.
10914	NullFields []string `json:"-"`
10915}
10916
10917func (s *GoogleCloudDialogflowV2ListDocumentsResponse) MarshalJSON() ([]byte, error) {
10918	type NoMethod GoogleCloudDialogflowV2ListDocumentsResponse
10919	raw := NoMethod(*s)
10920	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10921}
10922
10923// GoogleCloudDialogflowV2ListEntityTypesResponse: The response message
10924// for EntityTypes.ListEntityTypes.
10925type GoogleCloudDialogflowV2ListEntityTypesResponse struct {
10926	// EntityTypes: The list of agent entity types. There will be a maximum
10927	// number of items returned based on the page_size field in the request.
10928	EntityTypes []*GoogleCloudDialogflowV2EntityType `json:"entityTypes,omitempty"`
10929
10930	// NextPageToken: Token to retrieve the next page of results, or empty
10931	// if there are no more results in the list.
10932	NextPageToken string `json:"nextPageToken,omitempty"`
10933
10934	// ServerResponse contains the HTTP response code and headers from the
10935	// server.
10936	googleapi.ServerResponse `json:"-"`
10937
10938	// ForceSendFields is a list of field names (e.g. "EntityTypes") to
10939	// unconditionally include in API requests. By default, fields with
10940	// empty values are omitted from API requests. However, any non-pointer,
10941	// non-interface field appearing in ForceSendFields will be sent to the
10942	// server regardless of whether the field is empty or not. This may be
10943	// used to include empty fields in Patch requests.
10944	ForceSendFields []string `json:"-"`
10945
10946	// NullFields is a list of field names (e.g. "EntityTypes") to include
10947	// in API requests with the JSON null value. By default, fields with
10948	// empty values are omitted from API requests. However, any field with
10949	// an empty value appearing in NullFields will be sent to the server as
10950	// null. It is an error if a field in this list has a non-empty value.
10951	// This may be used to include null fields in Patch requests.
10952	NullFields []string `json:"-"`
10953}
10954
10955func (s *GoogleCloudDialogflowV2ListEntityTypesResponse) MarshalJSON() ([]byte, error) {
10956	type NoMethod GoogleCloudDialogflowV2ListEntityTypesResponse
10957	raw := NoMethod(*s)
10958	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10959}
10960
10961// GoogleCloudDialogflowV2ListEnvironmentsResponse: The response message
10962// for Environments.ListEnvironments.
10963type GoogleCloudDialogflowV2ListEnvironmentsResponse struct {
10964	// Environments: The list of agent environments. There will be a maximum
10965	// number of items returned based on the page_size field in the request.
10966	Environments []*GoogleCloudDialogflowV2Environment `json:"environments,omitempty"`
10967
10968	// NextPageToken: Token to retrieve the next page of results, or empty
10969	// if there are no more results in the list.
10970	NextPageToken string `json:"nextPageToken,omitempty"`
10971
10972	// ServerResponse contains the HTTP response code and headers from the
10973	// server.
10974	googleapi.ServerResponse `json:"-"`
10975
10976	// ForceSendFields is a list of field names (e.g. "Environments") to
10977	// unconditionally include in API requests. By default, fields with
10978	// empty values are omitted from API requests. However, any non-pointer,
10979	// non-interface field appearing in ForceSendFields will be sent to the
10980	// server regardless of whether the field is empty or not. This may be
10981	// used to include empty fields in Patch requests.
10982	ForceSendFields []string `json:"-"`
10983
10984	// NullFields is a list of field names (e.g. "Environments") to include
10985	// in API requests with the JSON null value. By default, fields with
10986	// empty values are omitted from API requests. However, any field with
10987	// an empty value appearing in NullFields will be sent to the server as
10988	// null. It is an error if a field in this list has a non-empty value.
10989	// This may be used to include null fields in Patch requests.
10990	NullFields []string `json:"-"`
10991}
10992
10993func (s *GoogleCloudDialogflowV2ListEnvironmentsResponse) MarshalJSON() ([]byte, error) {
10994	type NoMethod GoogleCloudDialogflowV2ListEnvironmentsResponse
10995	raw := NoMethod(*s)
10996	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10997}
10998
10999// GoogleCloudDialogflowV2ListIntentsResponse: The response message for
11000// Intents.ListIntents.
11001type GoogleCloudDialogflowV2ListIntentsResponse struct {
11002	// Intents: The list of agent intents. There will be a maximum number of
11003	// items returned based on the page_size field in the request.
11004	Intents []*GoogleCloudDialogflowV2Intent `json:"intents,omitempty"`
11005
11006	// NextPageToken: Token to retrieve the next page of results, or empty
11007	// if there are no more results in the list.
11008	NextPageToken string `json:"nextPageToken,omitempty"`
11009
11010	// ServerResponse contains the HTTP response code and headers from the
11011	// server.
11012	googleapi.ServerResponse `json:"-"`
11013
11014	// ForceSendFields is a list of field names (e.g. "Intents") to
11015	// unconditionally include in API requests. By default, fields with
11016	// empty values are omitted from API requests. However, any non-pointer,
11017	// non-interface field appearing in ForceSendFields will be sent to the
11018	// server regardless of whether the field is empty or not. This may be
11019	// used to include empty fields in Patch requests.
11020	ForceSendFields []string `json:"-"`
11021
11022	// NullFields is a list of field names (e.g. "Intents") to include in
11023	// API requests with the JSON null value. By default, fields with empty
11024	// values are omitted from API requests. However, any field with an
11025	// empty value appearing in NullFields will be sent to the server as
11026	// null. It is an error if a field in this list has a non-empty value.
11027	// This may be used to include null fields in Patch requests.
11028	NullFields []string `json:"-"`
11029}
11030
11031func (s *GoogleCloudDialogflowV2ListIntentsResponse) MarshalJSON() ([]byte, error) {
11032	type NoMethod GoogleCloudDialogflowV2ListIntentsResponse
11033	raw := NoMethod(*s)
11034	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11035}
11036
11037// GoogleCloudDialogflowV2ListKnowledgeBasesResponse: Response message
11038// for KnowledgeBases.ListKnowledgeBases.
11039type GoogleCloudDialogflowV2ListKnowledgeBasesResponse struct {
11040	// KnowledgeBases: The list of knowledge bases.
11041	KnowledgeBases []*GoogleCloudDialogflowV2KnowledgeBase `json:"knowledgeBases,omitempty"`
11042
11043	// NextPageToken: Token to retrieve the next page of results, or empty
11044	// if there are no more results in the list.
11045	NextPageToken string `json:"nextPageToken,omitempty"`
11046
11047	// ServerResponse contains the HTTP response code and headers from the
11048	// server.
11049	googleapi.ServerResponse `json:"-"`
11050
11051	// ForceSendFields is a list of field names (e.g. "KnowledgeBases") to
11052	// unconditionally include in API requests. By default, fields with
11053	// empty values are omitted from API requests. However, any non-pointer,
11054	// non-interface field appearing in ForceSendFields will be sent to the
11055	// server regardless of whether the field is empty or not. This may be
11056	// used to include empty fields in Patch requests.
11057	ForceSendFields []string `json:"-"`
11058
11059	// NullFields is a list of field names (e.g. "KnowledgeBases") to
11060	// include in API requests with the JSON null value. By default, fields
11061	// with empty values are omitted from API requests. However, any field
11062	// with an empty value appearing in NullFields will be sent to the
11063	// server as null. It is an error if a field in this list has a
11064	// non-empty value. This may be used to include null fields in Patch
11065	// requests.
11066	NullFields []string `json:"-"`
11067}
11068
11069func (s *GoogleCloudDialogflowV2ListKnowledgeBasesResponse) MarshalJSON() ([]byte, error) {
11070	type NoMethod GoogleCloudDialogflowV2ListKnowledgeBasesResponse
11071	raw := NoMethod(*s)
11072	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11073}
11074
11075// GoogleCloudDialogflowV2ListMessagesResponse: The response message for
11076// Conversations.ListMessages.
11077type GoogleCloudDialogflowV2ListMessagesResponse struct {
11078	// Messages: The list of messages. There will be a maximum number of
11079	// items returned based on the page_size field in the request.
11080	// `messages` is sorted by `create_time` in descending order.
11081	Messages []*GoogleCloudDialogflowV2Message `json:"messages,omitempty"`
11082
11083	// NextPageToken: Token to retrieve the next page of results, or empty
11084	// if there are no more results in the list.
11085	NextPageToken string `json:"nextPageToken,omitempty"`
11086
11087	// ServerResponse contains the HTTP response code and headers from the
11088	// server.
11089	googleapi.ServerResponse `json:"-"`
11090
11091	// ForceSendFields is a list of field names (e.g. "Messages") to
11092	// unconditionally include in API requests. By default, fields with
11093	// empty values are omitted from API requests. However, any non-pointer,
11094	// non-interface field appearing in ForceSendFields will be sent to the
11095	// server regardless of whether the field is empty or not. This may be
11096	// used to include empty fields in Patch requests.
11097	ForceSendFields []string `json:"-"`
11098
11099	// NullFields is a list of field names (e.g. "Messages") to include in
11100	// API requests with the JSON null value. By default, fields with empty
11101	// values are omitted from API requests. However, any field with an
11102	// empty value appearing in NullFields will be sent to the server as
11103	// null. It is an error if a field in this list has a non-empty value.
11104	// This may be used to include null fields in Patch requests.
11105	NullFields []string `json:"-"`
11106}
11107
11108func (s *GoogleCloudDialogflowV2ListMessagesResponse) MarshalJSON() ([]byte, error) {
11109	type NoMethod GoogleCloudDialogflowV2ListMessagesResponse
11110	raw := NoMethod(*s)
11111	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11112}
11113
11114// GoogleCloudDialogflowV2ListParticipantsResponse: The response message
11115// for Participants.ListParticipants.
11116type GoogleCloudDialogflowV2ListParticipantsResponse struct {
11117	// NextPageToken: Token to retrieve the next page of results or empty if
11118	// there are no more results in the list.
11119	NextPageToken string `json:"nextPageToken,omitempty"`
11120
11121	// Participants: The list of participants. There is a maximum number of
11122	// items returned based on the page_size field in the request.
11123	Participants []*GoogleCloudDialogflowV2Participant `json:"participants,omitempty"`
11124
11125	// ServerResponse contains the HTTP response code and headers from the
11126	// server.
11127	googleapi.ServerResponse `json:"-"`
11128
11129	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
11130	// unconditionally include in API requests. By default, fields with
11131	// empty values are omitted from API requests. However, any non-pointer,
11132	// non-interface field appearing in ForceSendFields will be sent to the
11133	// server regardless of whether the field is empty or not. This may be
11134	// used to include empty fields in Patch requests.
11135	ForceSendFields []string `json:"-"`
11136
11137	// NullFields is a list of field names (e.g. "NextPageToken") to include
11138	// in API requests with the JSON null value. By default, fields with
11139	// empty values are omitted from API requests. However, any field with
11140	// an empty value appearing in NullFields will be sent to the server as
11141	// null. It is an error if a field in this list has a non-empty value.
11142	// This may be used to include null fields in Patch requests.
11143	NullFields []string `json:"-"`
11144}
11145
11146func (s *GoogleCloudDialogflowV2ListParticipantsResponse) MarshalJSON() ([]byte, error) {
11147	type NoMethod GoogleCloudDialogflowV2ListParticipantsResponse
11148	raw := NoMethod(*s)
11149	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11150}
11151
11152// GoogleCloudDialogflowV2ListSessionEntityTypesResponse: The response
11153// message for SessionEntityTypes.ListSessionEntityTypes.
11154type GoogleCloudDialogflowV2ListSessionEntityTypesResponse struct {
11155	// NextPageToken: Token to retrieve the next page of results, or empty
11156	// if there are no more results in the list.
11157	NextPageToken string `json:"nextPageToken,omitempty"`
11158
11159	// SessionEntityTypes: The list of session entity types. There will be a
11160	// maximum number of items returned based on the page_size field in the
11161	// request.
11162	SessionEntityTypes []*GoogleCloudDialogflowV2SessionEntityType `json:"sessionEntityTypes,omitempty"`
11163
11164	// ServerResponse contains the HTTP response code and headers from the
11165	// server.
11166	googleapi.ServerResponse `json:"-"`
11167
11168	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
11169	// unconditionally include in API requests. By default, fields with
11170	// empty values are omitted from API requests. However, any non-pointer,
11171	// non-interface field appearing in ForceSendFields will be sent to the
11172	// server regardless of whether the field is empty or not. This may be
11173	// used to include empty fields in Patch requests.
11174	ForceSendFields []string `json:"-"`
11175
11176	// NullFields is a list of field names (e.g. "NextPageToken") to include
11177	// in API requests with the JSON null value. By default, fields with
11178	// empty values are omitted from API requests. However, any field with
11179	// an empty value appearing in NullFields will be sent to the server as
11180	// null. It is an error if a field in this list has a non-empty value.
11181	// This may be used to include null fields in Patch requests.
11182	NullFields []string `json:"-"`
11183}
11184
11185func (s *GoogleCloudDialogflowV2ListSessionEntityTypesResponse) MarshalJSON() ([]byte, error) {
11186	type NoMethod GoogleCloudDialogflowV2ListSessionEntityTypesResponse
11187	raw := NoMethod(*s)
11188	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11189}
11190
11191// GoogleCloudDialogflowV2LoggingConfig: Defines logging behavior for
11192// conversation lifecycle events.
11193type GoogleCloudDialogflowV2LoggingConfig struct {
11194	// EnableStackdriverLogging: Whether to log conversation events like
11195	// CONVERSATION_STARTED to Stackdriver in the conversation project as
11196	// JSON format ConversationEvent protos.
11197	EnableStackdriverLogging bool `json:"enableStackdriverLogging,omitempty"`
11198
11199	// ForceSendFields is a list of field names (e.g.
11200	// "EnableStackdriverLogging") to unconditionally include in API
11201	// requests. By default, fields with empty values are omitted from API
11202	// requests. However, any non-pointer, non-interface field appearing in
11203	// ForceSendFields will be sent to the server regardless of whether the
11204	// field is empty or not. This may be used to include empty fields in
11205	// Patch requests.
11206	ForceSendFields []string `json:"-"`
11207
11208	// NullFields is a list of field names (e.g. "EnableStackdriverLogging")
11209	// to include in API requests with the JSON null value. By default,
11210	// fields with empty values are omitted from API requests. However, any
11211	// field with an empty value appearing in NullFields will be sent to the
11212	// server as null. It is an error if a field in this list has a
11213	// non-empty value. This may be used to include null fields in Patch
11214	// requests.
11215	NullFields []string `json:"-"`
11216}
11217
11218func (s *GoogleCloudDialogflowV2LoggingConfig) MarshalJSON() ([]byte, error) {
11219	type NoMethod GoogleCloudDialogflowV2LoggingConfig
11220	raw := NoMethod(*s)
11221	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11222}
11223
11224// GoogleCloudDialogflowV2Message: Represents a message posted into a
11225// conversation.
11226type GoogleCloudDialogflowV2Message struct {
11227	// Content: Required. The message content.
11228	Content string `json:"content,omitempty"`
11229
11230	// CreateTime: Output only. The time when the message was created.
11231	CreateTime string `json:"createTime,omitempty"`
11232
11233	// LanguageCode: Optional. The message language. This should be a BCP-47
11234	// (https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. Example:
11235	// "en-US".
11236	LanguageCode string `json:"languageCode,omitempty"`
11237
11238	// MessageAnnotation: Output only. The annotation for the message.
11239	MessageAnnotation *GoogleCloudDialogflowV2MessageAnnotation `json:"messageAnnotation,omitempty"`
11240
11241	// Name: The unique identifier of the message. Format:
11242	// `projects//locations//conversations//messages/`.
11243	Name string `json:"name,omitempty"`
11244
11245	// Participant: Output only. The participant that sends this message.
11246	Participant string `json:"participant,omitempty"`
11247
11248	// ParticipantRole: Output only. The role of the participant.
11249	//
11250	// Possible values:
11251	//   "ROLE_UNSPECIFIED" - Participant role not set.
11252	//   "HUMAN_AGENT" - Participant is a human agent.
11253	//   "AUTOMATED_AGENT" - Participant is an automated agent, such as a
11254	// Dialogflow agent.
11255	//   "END_USER" - Participant is an end user that has called or chatted
11256	// with Dialogflow services.
11257	ParticipantRole string `json:"participantRole,omitempty"`
11258
11259	// ForceSendFields is a list of field names (e.g. "Content") to
11260	// unconditionally include in API requests. By default, fields with
11261	// empty values are omitted from API requests. However, any non-pointer,
11262	// non-interface field appearing in ForceSendFields will be sent to the
11263	// server regardless of whether the field is empty or not. This may be
11264	// used to include empty fields in Patch requests.
11265	ForceSendFields []string `json:"-"`
11266
11267	// NullFields is a list of field names (e.g. "Content") to include in
11268	// API requests with the JSON null value. By default, fields with empty
11269	// values are omitted from API requests. However, any field with an
11270	// empty value appearing in NullFields will be sent to the server as
11271	// null. It is an error if a field in this list has a non-empty value.
11272	// This may be used to include null fields in Patch requests.
11273	NullFields []string `json:"-"`
11274}
11275
11276func (s *GoogleCloudDialogflowV2Message) MarshalJSON() ([]byte, error) {
11277	type NoMethod GoogleCloudDialogflowV2Message
11278	raw := NoMethod(*s)
11279	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11280}
11281
11282// GoogleCloudDialogflowV2MessageAnnotation: Represents the result of
11283// annotation for the message.
11284type GoogleCloudDialogflowV2MessageAnnotation struct {
11285	// ContainEntities: Indicates whether the text message contains
11286	// entities.
11287	ContainEntities bool `json:"containEntities,omitempty"`
11288
11289	// Parts: The collection of annotated message parts ordered by their
11290	// position in the message. You can recover the annotated message by
11291	// concatenating [AnnotatedMessagePart.text].
11292	Parts []*GoogleCloudDialogflowV2AnnotatedMessagePart `json:"parts,omitempty"`
11293
11294	// ForceSendFields is a list of field names (e.g. "ContainEntities") to
11295	// unconditionally include in API requests. By default, fields with
11296	// empty values are omitted from API requests. However, any non-pointer,
11297	// non-interface field appearing in ForceSendFields will be sent to the
11298	// server regardless of whether the field is empty or not. This may be
11299	// used to include empty fields in Patch requests.
11300	ForceSendFields []string `json:"-"`
11301
11302	// NullFields is a list of field names (e.g. "ContainEntities") to
11303	// include in API requests with the JSON null value. By default, fields
11304	// with empty values are omitted from API requests. However, any field
11305	// with an empty value appearing in NullFields will be sent to the
11306	// server as null. It is an error if a field in this list has a
11307	// non-empty value. This may be used to include null fields in Patch
11308	// requests.
11309	NullFields []string `json:"-"`
11310}
11311
11312func (s *GoogleCloudDialogflowV2MessageAnnotation) MarshalJSON() ([]byte, error) {
11313	type NoMethod GoogleCloudDialogflowV2MessageAnnotation
11314	raw := NoMethod(*s)
11315	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11316}
11317
11318// GoogleCloudDialogflowV2NotificationConfig: Defines notification
11319// behavior.
11320type GoogleCloudDialogflowV2NotificationConfig struct {
11321	// MessageFormat: Format of message.
11322	//
11323	// Possible values:
11324	//   "MESSAGE_FORMAT_UNSPECIFIED" - If it is unspeified, PROTO will be
11325	// used.
11326	//   "PROTO" - Pubsub message will be serialized proto.
11327	//   "JSON" - Pubsub message will be json.
11328	MessageFormat string `json:"messageFormat,omitempty"`
11329
11330	// Topic: Name of the Pub/Sub topic to publish conversation events like
11331	// CONVERSATION_STARTED as serialized ConversationEvent protos.
11332	// Notification works for phone calls, if this topic either is in the
11333	// same project as the conversation or you grant
11334	// `service-@gcp-sa-dialogflow.iam.gserviceaccount.com` the `Dialogflow
11335	// Service Agent` role in the topic project. Format:
11336	// `projects//locations//topics/`.
11337	Topic string `json:"topic,omitempty"`
11338
11339	// ForceSendFields is a list of field names (e.g. "MessageFormat") to
11340	// unconditionally include in API requests. By default, fields with
11341	// empty values are omitted from API requests. However, any non-pointer,
11342	// non-interface field appearing in ForceSendFields will be sent to the
11343	// server regardless of whether the field is empty or not. This may be
11344	// used to include empty fields in Patch requests.
11345	ForceSendFields []string `json:"-"`
11346
11347	// NullFields is a list of field names (e.g. "MessageFormat") to include
11348	// in API requests with the JSON null value. By default, fields with
11349	// empty values are omitted from API requests. However, any field with
11350	// an 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 *GoogleCloudDialogflowV2NotificationConfig) MarshalJSON() ([]byte, error) {
11357	type NoMethod GoogleCloudDialogflowV2NotificationConfig
11358	raw := NoMethod(*s)
11359	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11360}
11361
11362// GoogleCloudDialogflowV2OriginalDetectIntentRequest: Represents the
11363// contents of the original request that was passed to the
11364// `[Streaming]DetectIntent` call.
11365type GoogleCloudDialogflowV2OriginalDetectIntentRequest struct {
11366	// Payload: Optional. This field is set to the value of the
11367	// `QueryParameters.payload` field passed in the request. Some
11368	// integrations that query a Dialogflow agent may provide additional
11369	// information in the payload. In particular, for the Dialogflow Phone
11370	// Gateway integration, this field has the form: { "telephony": {
11371	// "caller_id": "+18558363987" } } Note: The caller ID field
11372	// (`caller_id`) will be redacted for Trial Edition agents and populated
11373	// with the caller ID in E.164 format
11374	// (https://en.wikipedia.org/wiki/E.164) for Essentials Edition agents.
11375	Payload googleapi.RawMessage `json:"payload,omitempty"`
11376
11377	// Source: The source of this request, e.g., `google`, `facebook`,
11378	// `slack`. It is set by Dialogflow-owned servers.
11379	Source string `json:"source,omitempty"`
11380
11381	// Version: Optional. The version of the protocol used for this request.
11382	// This field is AoG-specific.
11383	Version string `json:"version,omitempty"`
11384
11385	// ForceSendFields is a list of field names (e.g. "Payload") to
11386	// unconditionally include in API requests. By default, fields with
11387	// empty values are omitted from API requests. However, any non-pointer,
11388	// non-interface field appearing in ForceSendFields will be sent to the
11389	// server regardless of whether the field is empty or not. This may be
11390	// used to include empty fields in Patch requests.
11391	ForceSendFields []string `json:"-"`
11392
11393	// NullFields is a list of field names (e.g. "Payload") to include in
11394	// API requests with the JSON null value. By default, fields with empty
11395	// values are omitted from API requests. However, any field with an
11396	// empty value appearing in NullFields will be sent to the server as
11397	// null. It is an error if a field in this list has a non-empty value.
11398	// This may be used to include null fields in Patch requests.
11399	NullFields []string `json:"-"`
11400}
11401
11402func (s *GoogleCloudDialogflowV2OriginalDetectIntentRequest) MarshalJSON() ([]byte, error) {
11403	type NoMethod GoogleCloudDialogflowV2OriginalDetectIntentRequest
11404	raw := NoMethod(*s)
11405	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11406}
11407
11408// GoogleCloudDialogflowV2OutputAudio: Represents the natural language
11409// speech audio to be played to the end user.
11410type GoogleCloudDialogflowV2OutputAudio struct {
11411	// Audio: The natural language speech audio.
11412	Audio string `json:"audio,omitempty"`
11413
11414	// Config: Instructs the speech synthesizer how to generate the speech
11415	// audio.
11416	Config *GoogleCloudDialogflowV2OutputAudioConfig `json:"config,omitempty"`
11417
11418	// ForceSendFields is a list of field names (e.g. "Audio") to
11419	// unconditionally include in API requests. By default, fields with
11420	// empty values are omitted from API requests. However, any non-pointer,
11421	// non-interface field appearing in ForceSendFields will be sent to the
11422	// server regardless of whether the field is empty or not. This may be
11423	// used to include empty fields in Patch requests.
11424	ForceSendFields []string `json:"-"`
11425
11426	// NullFields is a list of field names (e.g. "Audio") to include in API
11427	// requests with the JSON null value. By default, fields with empty
11428	// values are omitted from API requests. However, any field with an
11429	// empty value appearing in NullFields will be sent to the server as
11430	// null. It is an error if a field in this list has a non-empty value.
11431	// This may be used to include null fields in Patch requests.
11432	NullFields []string `json:"-"`
11433}
11434
11435func (s *GoogleCloudDialogflowV2OutputAudio) MarshalJSON() ([]byte, error) {
11436	type NoMethod GoogleCloudDialogflowV2OutputAudio
11437	raw := NoMethod(*s)
11438	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11439}
11440
11441// GoogleCloudDialogflowV2OutputAudioConfig: Instructs the speech
11442// synthesizer on how to generate the output audio content. If this
11443// audio config is supplied in a request, it overrides all existing
11444// text-to-speech settings applied to the agent.
11445type GoogleCloudDialogflowV2OutputAudioConfig struct {
11446	// AudioEncoding: Required. Audio encoding of the synthesized audio
11447	// content.
11448	//
11449	// Possible values:
11450	//   "OUTPUT_AUDIO_ENCODING_UNSPECIFIED" - Not specified.
11451	//   "OUTPUT_AUDIO_ENCODING_LINEAR_16" - Uncompressed 16-bit signed
11452	// little-endian samples (Linear PCM). Audio content returned as
11453	// LINEAR16 also contains a WAV header.
11454	//   "OUTPUT_AUDIO_ENCODING_MP3" - MP3 audio at 32kbps.
11455	//   "OUTPUT_AUDIO_ENCODING_MP3_64_KBPS" - MP3 audio at 64kbps.
11456	//   "OUTPUT_AUDIO_ENCODING_OGG_OPUS" - Opus encoded audio wrapped in an
11457	// ogg container. The result will be a file which can be played natively
11458	// on Android, and in browsers (at least Chrome and Firefox). The
11459	// quality of the encoding is considerably higher than MP3 while using
11460	// approximately the same bitrate.
11461	//   "OUTPUT_AUDIO_ENCODING_MULAW" - 8-bit samples that compand 14-bit
11462	// audio samples using G.711 PCMU/mu-law.
11463	AudioEncoding string `json:"audioEncoding,omitempty"`
11464
11465	// SampleRateHertz: The synthesis sample rate (in hertz) for this audio.
11466	// If not provided, then the synthesizer will use the default sample
11467	// rate based on the audio encoding. If this is different from the
11468	// voice's natural sample rate, then the synthesizer will honor this
11469	// request by converting to the desired sample rate (which might result
11470	// in worse audio quality).
11471	SampleRateHertz int64 `json:"sampleRateHertz,omitempty"`
11472
11473	// SynthesizeSpeechConfig: Configuration of how speech should be
11474	// synthesized.
11475	SynthesizeSpeechConfig *GoogleCloudDialogflowV2SynthesizeSpeechConfig `json:"synthesizeSpeechConfig,omitempty"`
11476
11477	// ForceSendFields is a list of field names (e.g. "AudioEncoding") to
11478	// unconditionally include in API requests. By default, fields with
11479	// empty values are omitted from API requests. However, any non-pointer,
11480	// non-interface field appearing in ForceSendFields will be sent to the
11481	// server regardless of whether the field is empty or not. This may be
11482	// used to include empty fields in Patch requests.
11483	ForceSendFields []string `json:"-"`
11484
11485	// NullFields is a list of field names (e.g. "AudioEncoding") to include
11486	// in API requests with the JSON null value. By default, fields with
11487	// empty values are omitted from API requests. However, any field with
11488	// an empty value appearing in NullFields will be sent to the server as
11489	// null. It is an error if a field in this list has a non-empty value.
11490	// This may be used to include null fields in Patch requests.
11491	NullFields []string `json:"-"`
11492}
11493
11494func (s *GoogleCloudDialogflowV2OutputAudioConfig) MarshalJSON() ([]byte, error) {
11495	type NoMethod GoogleCloudDialogflowV2OutputAudioConfig
11496	raw := NoMethod(*s)
11497	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11498}
11499
11500// GoogleCloudDialogflowV2Participant: Represents a conversation
11501// participant (human agent, virtual agent, end-user).
11502type GoogleCloudDialogflowV2Participant struct {
11503	// Name: Optional. The unique identifier of this participant. Format:
11504	// `projects//locations//conversations//participants/`.
11505	Name string `json:"name,omitempty"`
11506
11507	// Role: Immutable. The role this participant plays in the conversation.
11508	// This field must be set during participant creation and is then
11509	// immutable.
11510	//
11511	// Possible values:
11512	//   "ROLE_UNSPECIFIED" - Participant role not set.
11513	//   "HUMAN_AGENT" - Participant is a human agent.
11514	//   "AUTOMATED_AGENT" - Participant is an automated agent, such as a
11515	// Dialogflow agent.
11516	//   "END_USER" - Participant is an end user that has called or chatted
11517	// with Dialogflow services.
11518	Role string `json:"role,omitempty"`
11519
11520	// SipRecordingMediaLabel: Optional. Label applied to streams
11521	// representing this participant in SIPREC XML metadata and SDP. This is
11522	// used to assign transcriptions from that media stream to this
11523	// participant. This field can be updated.
11524	SipRecordingMediaLabel string `json:"sipRecordingMediaLabel,omitempty"`
11525
11526	// ServerResponse contains the HTTP response code and headers from the
11527	// server.
11528	googleapi.ServerResponse `json:"-"`
11529
11530	// ForceSendFields is a list of field names (e.g. "Name") to
11531	// unconditionally include in API requests. By default, fields with
11532	// empty values are omitted from API requests. However, any non-pointer,
11533	// non-interface field appearing in ForceSendFields will be sent to the
11534	// server regardless of whether the field is empty or not. This may be
11535	// used to include empty fields in Patch requests.
11536	ForceSendFields []string `json:"-"`
11537
11538	// NullFields is a list of field names (e.g. "Name") to include in API
11539	// requests with the JSON null value. By default, fields with empty
11540	// values are omitted from API requests. However, any field with an
11541	// empty value appearing in NullFields will be sent to the server as
11542	// null. It is an error if a field in this list has a non-empty value.
11543	// This may be used to include null fields in Patch requests.
11544	NullFields []string `json:"-"`
11545}
11546
11547func (s *GoogleCloudDialogflowV2Participant) MarshalJSON() ([]byte, error) {
11548	type NoMethod GoogleCloudDialogflowV2Participant
11549	raw := NoMethod(*s)
11550	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11551}
11552
11553// GoogleCloudDialogflowV2QueryInput: Represents the query input. It can
11554// contain either: 1. An audio config which instructs the speech
11555// recognizer how to process the speech audio. 2. A conversational query
11556// in the form of text,. 3. An event that specifies which intent to
11557// trigger.
11558type GoogleCloudDialogflowV2QueryInput struct {
11559	// AudioConfig: Instructs the speech recognizer how to process the
11560	// speech audio.
11561	AudioConfig *GoogleCloudDialogflowV2InputAudioConfig `json:"audioConfig,omitempty"`
11562
11563	// Event: The event to be processed.
11564	Event *GoogleCloudDialogflowV2EventInput `json:"event,omitempty"`
11565
11566	// Text: The natural language text to be processed.
11567	Text *GoogleCloudDialogflowV2TextInput `json:"text,omitempty"`
11568
11569	// ForceSendFields is a list of field names (e.g. "AudioConfig") to
11570	// unconditionally include in API requests. By default, fields with
11571	// empty values are omitted from API requests. However, any non-pointer,
11572	// non-interface field appearing in ForceSendFields will be sent to the
11573	// server regardless of whether the field is empty or not. This may be
11574	// used to include empty fields in Patch requests.
11575	ForceSendFields []string `json:"-"`
11576
11577	// NullFields is a list of field names (e.g. "AudioConfig") to include
11578	// in API requests with the JSON null value. By default, fields with
11579	// empty values are omitted from API requests. However, any field with
11580	// an empty value appearing in NullFields will be sent to the server as
11581	// null. It is an error if a field in this list has a non-empty value.
11582	// This may be used to include null fields in Patch requests.
11583	NullFields []string `json:"-"`
11584}
11585
11586func (s *GoogleCloudDialogflowV2QueryInput) MarshalJSON() ([]byte, error) {
11587	type NoMethod GoogleCloudDialogflowV2QueryInput
11588	raw := NoMethod(*s)
11589	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11590}
11591
11592// GoogleCloudDialogflowV2QueryParameters: Represents the parameters of
11593// the conversational query.
11594type GoogleCloudDialogflowV2QueryParameters struct {
11595	// Contexts: The collection of contexts to be activated before this
11596	// query is executed.
11597	Contexts []*GoogleCloudDialogflowV2Context `json:"contexts,omitempty"`
11598
11599	// GeoLocation: The geo location of this conversational query.
11600	GeoLocation *GoogleTypeLatLng `json:"geoLocation,omitempty"`
11601
11602	// Payload: This field can be used to pass custom data to your webhook.
11603	// Arbitrary JSON objects are supported. If supplied, the value is used
11604	// to populate the
11605	// `WebhookRequest.original_detect_intent_request.payload` field sent to
11606	// your webhook.
11607	Payload googleapi.RawMessage `json:"payload,omitempty"`
11608
11609	// ResetContexts: Specifies whether to delete all contexts in the
11610	// current session before the new ones are activated.
11611	ResetContexts bool `json:"resetContexts,omitempty"`
11612
11613	// SentimentAnalysisRequestConfig: Configures the type of sentiment
11614	// analysis to perform. If not provided, sentiment analysis is not
11615	// performed.
11616	SentimentAnalysisRequestConfig *GoogleCloudDialogflowV2SentimentAnalysisRequestConfig `json:"sentimentAnalysisRequestConfig,omitempty"`
11617
11618	// SessionEntityTypes: Additional session entity types to replace or
11619	// extend developer entity types with. The entity synonyms apply to all
11620	// languages and persist for the session of this query.
11621	SessionEntityTypes []*GoogleCloudDialogflowV2SessionEntityType `json:"sessionEntityTypes,omitempty"`
11622
11623	// TimeZone: The time zone of this conversational query from the time
11624	// zone database (https://www.iana.org/time-zones), e.g.,
11625	// America/New_York, Europe/Paris. If not provided, the time zone
11626	// specified in agent settings is used.
11627	TimeZone string `json:"timeZone,omitempty"`
11628
11629	// WebhookHeaders: This field can be used to pass HTTP headers for a
11630	// webhook call. These headers will be sent to webhook along with the
11631	// headers that have been configured through the Dialogflow web console.
11632	// The headers defined within this field will overwrite the headers
11633	// configured through the Dialogflow console if there is a conflict.
11634	// Header names are case-insensitive. Google's specified headers are not
11635	// allowed. Including: "Host", "Content-Length", "Connection", "From",
11636	// "User-Agent", "Accept-Encoding", "If-Modified-Since",
11637	// "If-None-Match", "X-Forwarded-For", etc.
11638	WebhookHeaders map[string]string `json:"webhookHeaders,omitempty"`
11639
11640	// ForceSendFields is a list of field names (e.g. "Contexts") to
11641	// unconditionally include in API requests. By default, fields with
11642	// empty values are omitted from API requests. However, any non-pointer,
11643	// non-interface field appearing in ForceSendFields will be sent to the
11644	// server regardless of whether the field is empty or not. This may be
11645	// used to include empty fields in Patch requests.
11646	ForceSendFields []string `json:"-"`
11647
11648	// NullFields is a list of field names (e.g. "Contexts") to include in
11649	// API requests with the JSON null value. By default, fields with empty
11650	// values are omitted from API requests. However, any field with an
11651	// empty value appearing in NullFields will be sent to the server as
11652	// null. It is an error if a field in this list has a non-empty value.
11653	// This may be used to include null fields in Patch requests.
11654	NullFields []string `json:"-"`
11655}
11656
11657func (s *GoogleCloudDialogflowV2QueryParameters) MarshalJSON() ([]byte, error) {
11658	type NoMethod GoogleCloudDialogflowV2QueryParameters
11659	raw := NoMethod(*s)
11660	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11661}
11662
11663// GoogleCloudDialogflowV2QueryResult: Represents the result of
11664// conversational query or event processing.
11665type GoogleCloudDialogflowV2QueryResult struct {
11666	// Action: The action name from the matched intent.
11667	Action string `json:"action,omitempty"`
11668
11669	// AllRequiredParamsPresent: This field is set to: - `false` if the
11670	// matched intent has required parameters and not all of the required
11671	// parameter values have been collected. - `true` if all required
11672	// parameter values have been collected, or if the matched intent
11673	// doesn't contain any required parameters.
11674	AllRequiredParamsPresent bool `json:"allRequiredParamsPresent,omitempty"`
11675
11676	// DiagnosticInfo: Free-form diagnostic information for the associated
11677	// detect intent request. The fields of this data can change without
11678	// notice, so you should not write code that depends on its structure.
11679	// The data may contain: - webhook call latency - webhook errors
11680	DiagnosticInfo googleapi.RawMessage `json:"diagnosticInfo,omitempty"`
11681
11682	// FulfillmentMessages: The collection of rich messages to present to
11683	// the user.
11684	FulfillmentMessages []*GoogleCloudDialogflowV2IntentMessage `json:"fulfillmentMessages,omitempty"`
11685
11686	// FulfillmentText: The text to be pronounced to the user or shown on
11687	// the screen. Note: This is a legacy field, `fulfillment_messages`
11688	// should be preferred.
11689	FulfillmentText string `json:"fulfillmentText,omitempty"`
11690
11691	// Intent: The intent that matched the conversational query. Some, not
11692	// all fields are filled in this message, including but not limited to:
11693	// `name`, `display_name`, `end_interaction` and `is_fallback`.
11694	Intent *GoogleCloudDialogflowV2Intent `json:"intent,omitempty"`
11695
11696	// IntentDetectionConfidence: The intent detection confidence. Values
11697	// range from 0.0 (completely uncertain) to 1.0 (completely certain).
11698	// This value is for informational purpose only and is only used to help
11699	// match the best intent within the classification threshold. This value
11700	// may change for the same end-user expression at any time due to a
11701	// model retraining or change in implementation. If there are `multiple
11702	// knowledge_answers` messages, this value is set to the greatest
11703	// `knowledgeAnswers.match_confidence` value in the list.
11704	IntentDetectionConfidence float64 `json:"intentDetectionConfidence,omitempty"`
11705
11706	// LanguageCode: The language that was triggered during intent
11707	// detection. See Language Support
11708	// (https://cloud.google.com/dialogflow/docs/reference/language) for a
11709	// list of the currently supported language codes.
11710	LanguageCode string `json:"languageCode,omitempty"`
11711
11712	// OutputContexts: The collection of output contexts. If applicable,
11713	// `output_contexts.parameters` contains entries with name `.original`
11714	// containing the original parameter values before the query.
11715	OutputContexts []*GoogleCloudDialogflowV2Context `json:"outputContexts,omitempty"`
11716
11717	// Parameters: The collection of extracted parameters. Depending on your
11718	// protocol or client library language, this is a map, associative
11719	// array, symbol table, dictionary, or JSON object composed of a
11720	// collection of (MapKey, MapValue) pairs: - MapKey type: string -
11721	// MapKey value: parameter name - MapValue type: - If parameter's entity
11722	// type is a composite entity: map - Else: depending on parameter value
11723	// type, could be one of string, number, boolean, null, list or map -
11724	// MapValue value: - If parameter's entity type is a composite entity:
11725	// map from composite entity property names to property values - Else:
11726	// parameter value
11727	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
11728
11729	// QueryText: The original conversational query text: - If natural
11730	// language text was provided as input, `query_text` contains a copy of
11731	// the input. - If natural language speech audio was provided as input,
11732	// `query_text` contains the speech recognition result. If speech
11733	// recognizer produced multiple alternatives, a particular one is
11734	// picked. - If automatic spell correction is enabled, `query_text` will
11735	// contain the corrected user input.
11736	QueryText string `json:"queryText,omitempty"`
11737
11738	// SentimentAnalysisResult: The sentiment analysis result, which depends
11739	// on the `sentiment_analysis_request_config` specified in the request.
11740	SentimentAnalysisResult *GoogleCloudDialogflowV2SentimentAnalysisResult `json:"sentimentAnalysisResult,omitempty"`
11741
11742	// SpeechRecognitionConfidence: The Speech recognition confidence
11743	// between 0.0 and 1.0. A higher number indicates an estimated greater
11744	// likelihood that the recognized words are correct. The default of 0.0
11745	// is a sentinel value indicating that confidence was not set. This
11746	// field is not guaranteed to be accurate or set. In particular this
11747	// field isn't set for StreamingDetectIntent since the streaming
11748	// endpoint has separate confidence estimates per portion of the audio
11749	// in StreamingRecognitionResult.
11750	SpeechRecognitionConfidence float64 `json:"speechRecognitionConfidence,omitempty"`
11751
11752	// WebhookPayload: If the query was fulfilled by a webhook call, this
11753	// field is set to the value of the `payload` field returned in the
11754	// webhook response.
11755	WebhookPayload googleapi.RawMessage `json:"webhookPayload,omitempty"`
11756
11757	// WebhookSource: If the query was fulfilled by a webhook call, this
11758	// field is set to the value of the `source` field returned in the
11759	// webhook response.
11760	WebhookSource string `json:"webhookSource,omitempty"`
11761
11762	// ForceSendFields is a list of field names (e.g. "Action") to
11763	// unconditionally include in API requests. By default, fields with
11764	// empty values are omitted from API requests. However, any non-pointer,
11765	// non-interface field appearing in ForceSendFields will be sent to the
11766	// server regardless of whether the field is empty or not. This may be
11767	// used to include empty fields in Patch requests.
11768	ForceSendFields []string `json:"-"`
11769
11770	// NullFields is a list of field names (e.g. "Action") to include in API
11771	// requests with the JSON null value. By default, fields with empty
11772	// values are omitted from API requests. However, any field with an
11773	// empty value appearing in NullFields will be sent to the server as
11774	// null. It is an error if a field in this list has a non-empty value.
11775	// This may be used to include null fields in Patch requests.
11776	NullFields []string `json:"-"`
11777}
11778
11779func (s *GoogleCloudDialogflowV2QueryResult) MarshalJSON() ([]byte, error) {
11780	type NoMethod GoogleCloudDialogflowV2QueryResult
11781	raw := NoMethod(*s)
11782	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11783}
11784
11785func (s *GoogleCloudDialogflowV2QueryResult) UnmarshalJSON(data []byte) error {
11786	type NoMethod GoogleCloudDialogflowV2QueryResult
11787	var s1 struct {
11788		IntentDetectionConfidence   gensupport.JSONFloat64 `json:"intentDetectionConfidence"`
11789		SpeechRecognitionConfidence gensupport.JSONFloat64 `json:"speechRecognitionConfidence"`
11790		*NoMethod
11791	}
11792	s1.NoMethod = (*NoMethod)(s)
11793	if err := json.Unmarshal(data, &s1); err != nil {
11794		return err
11795	}
11796	s.IntentDetectionConfidence = float64(s1.IntentDetectionConfidence)
11797	s.SpeechRecognitionConfidence = float64(s1.SpeechRecognitionConfidence)
11798	return nil
11799}
11800
11801// GoogleCloudDialogflowV2ReloadDocumentRequest: Request message for
11802// Documents.ReloadDocument.
11803type GoogleCloudDialogflowV2ReloadDocumentRequest struct {
11804	// ContentUri: Optional. The path of gcs source file for reloading
11805	// document content. For now, only gcs uri is supported. For documents
11806	// stored in Google Cloud Storage, these URIs must have the form
11807	// `gs:///`.
11808	ContentUri string `json:"contentUri,omitempty"`
11809
11810	// ForceSendFields is a list of field names (e.g. "ContentUri") to
11811	// unconditionally include in API requests. By default, fields with
11812	// empty values are omitted from API requests. However, any non-pointer,
11813	// non-interface field appearing in ForceSendFields will be sent to the
11814	// server regardless of whether the field is empty or not. This may be
11815	// used to include empty fields in Patch requests.
11816	ForceSendFields []string `json:"-"`
11817
11818	// NullFields is a list of field names (e.g. "ContentUri") to include in
11819	// API requests with the JSON null value. By default, fields with empty
11820	// values are omitted from API requests. However, any field with an
11821	// empty value appearing in NullFields will be sent to the server as
11822	// null. It is an error if a field in this list has a non-empty value.
11823	// This may be used to include null fields in Patch requests.
11824	NullFields []string `json:"-"`
11825}
11826
11827func (s *GoogleCloudDialogflowV2ReloadDocumentRequest) MarshalJSON() ([]byte, error) {
11828	type NoMethod GoogleCloudDialogflowV2ReloadDocumentRequest
11829	raw := NoMethod(*s)
11830	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11831}
11832
11833// GoogleCloudDialogflowV2RestoreAgentRequest: The request message for
11834// Agents.RestoreAgent.
11835type GoogleCloudDialogflowV2RestoreAgentRequest struct {
11836	// AgentContent: Zip compressed raw byte content for agent.
11837	AgentContent string `json:"agentContent,omitempty"`
11838
11839	// AgentUri: The URI to a Google Cloud Storage file containing the agent
11840	// to restore. Note: The URI must start with "gs://".
11841	AgentUri string `json:"agentUri,omitempty"`
11842
11843	// ForceSendFields is a list of field names (e.g. "AgentContent") to
11844	// unconditionally include in API requests. By default, fields with
11845	// empty values are omitted from API requests. However, any non-pointer,
11846	// non-interface field appearing in ForceSendFields will be sent to the
11847	// server regardless of whether the field is empty or not. This may be
11848	// used to include empty fields in Patch requests.
11849	ForceSendFields []string `json:"-"`
11850
11851	// NullFields is a list of field names (e.g. "AgentContent") to include
11852	// in API requests with the JSON null value. By default, fields with
11853	// empty values are omitted from API requests. However, any field with
11854	// an empty value appearing in NullFields will be sent to the server as
11855	// null. It is an error if a field in this list has a non-empty value.
11856	// This may be used to include null fields in Patch requests.
11857	NullFields []string `json:"-"`
11858}
11859
11860func (s *GoogleCloudDialogflowV2RestoreAgentRequest) MarshalJSON() ([]byte, error) {
11861	type NoMethod GoogleCloudDialogflowV2RestoreAgentRequest
11862	raw := NoMethod(*s)
11863	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11864}
11865
11866// GoogleCloudDialogflowV2SearchAgentsResponse: The response message for
11867// Agents.SearchAgents.
11868type GoogleCloudDialogflowV2SearchAgentsResponse struct {
11869	// Agents: The list of agents. There will be a maximum number of items
11870	// returned based on the page_size field in the request.
11871	Agents []*GoogleCloudDialogflowV2Agent `json:"agents,omitempty"`
11872
11873	// NextPageToken: Token to retrieve the next page of results, or empty
11874	// if there are no more results in the list.
11875	NextPageToken string `json:"nextPageToken,omitempty"`
11876
11877	// ServerResponse contains the HTTP response code and headers from the
11878	// server.
11879	googleapi.ServerResponse `json:"-"`
11880
11881	// ForceSendFields is a list of field names (e.g. "Agents") to
11882	// unconditionally include in API requests. By default, fields with
11883	// empty values are omitted from API requests. However, any non-pointer,
11884	// non-interface field appearing in ForceSendFields will be sent to the
11885	// server regardless of whether the field is empty or not. This may be
11886	// used to include empty fields in Patch requests.
11887	ForceSendFields []string `json:"-"`
11888
11889	// NullFields is a list of field names (e.g. "Agents") to include in API
11890	// requests with the JSON null value. By default, fields with empty
11891	// values are omitted from API requests. However, any field with an
11892	// empty value appearing in NullFields will be sent to the server as
11893	// null. It is an error if a field in this list has a non-empty value.
11894	// This may be used to include null fields in Patch requests.
11895	NullFields []string `json:"-"`
11896}
11897
11898func (s *GoogleCloudDialogflowV2SearchAgentsResponse) MarshalJSON() ([]byte, error) {
11899	type NoMethod GoogleCloudDialogflowV2SearchAgentsResponse
11900	raw := NoMethod(*s)
11901	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11902}
11903
11904// GoogleCloudDialogflowV2Sentiment: The sentiment, such as
11905// positive/negative feeling or association, for a unit of analysis,
11906// such as the query text.
11907type GoogleCloudDialogflowV2Sentiment struct {
11908	// Magnitude: A non-negative number in the [0, +inf) range, which
11909	// represents the absolute magnitude of sentiment, regardless of score
11910	// (positive or negative).
11911	Magnitude float64 `json:"magnitude,omitempty"`
11912
11913	// Score: Sentiment score between -1.0 (negative sentiment) and 1.0
11914	// (positive sentiment).
11915	Score float64 `json:"score,omitempty"`
11916
11917	// ForceSendFields is a list of field names (e.g. "Magnitude") to
11918	// unconditionally include in API requests. By default, fields with
11919	// empty values are omitted from API requests. However, any non-pointer,
11920	// non-interface field appearing in ForceSendFields will be sent to the
11921	// server regardless of whether the field is empty or not. This may be
11922	// used to include empty fields in Patch requests.
11923	ForceSendFields []string `json:"-"`
11924
11925	// NullFields is a list of field names (e.g. "Magnitude") to include in
11926	// API requests with the JSON null value. By default, fields with empty
11927	// values are omitted from API requests. However, any field with an
11928	// empty value appearing in NullFields will be sent to the server as
11929	// null. It is an error if a field in this list has a non-empty value.
11930	// This may be used to include null fields in Patch requests.
11931	NullFields []string `json:"-"`
11932}
11933
11934func (s *GoogleCloudDialogflowV2Sentiment) MarshalJSON() ([]byte, error) {
11935	type NoMethod GoogleCloudDialogflowV2Sentiment
11936	raw := NoMethod(*s)
11937	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11938}
11939
11940func (s *GoogleCloudDialogflowV2Sentiment) UnmarshalJSON(data []byte) error {
11941	type NoMethod GoogleCloudDialogflowV2Sentiment
11942	var s1 struct {
11943		Magnitude gensupport.JSONFloat64 `json:"magnitude"`
11944		Score     gensupport.JSONFloat64 `json:"score"`
11945		*NoMethod
11946	}
11947	s1.NoMethod = (*NoMethod)(s)
11948	if err := json.Unmarshal(data, &s1); err != nil {
11949		return err
11950	}
11951	s.Magnitude = float64(s1.Magnitude)
11952	s.Score = float64(s1.Score)
11953	return nil
11954}
11955
11956// GoogleCloudDialogflowV2SentimentAnalysisRequestConfig: Configures the
11957// types of sentiment analysis to perform.
11958type GoogleCloudDialogflowV2SentimentAnalysisRequestConfig struct {
11959	// AnalyzeQueryTextSentiment: Instructs the service to perform sentiment
11960	// analysis on `query_text`. If not provided, sentiment analysis is not
11961	// performed on `query_text`.
11962	AnalyzeQueryTextSentiment bool `json:"analyzeQueryTextSentiment,omitempty"`
11963
11964	// ForceSendFields is a list of field names (e.g.
11965	// "AnalyzeQueryTextSentiment") to unconditionally include in API
11966	// requests. By default, fields with empty values are omitted from API
11967	// requests. However, any non-pointer, non-interface field appearing in
11968	// ForceSendFields will be sent to the server regardless of whether the
11969	// field is empty or not. This may be used to include empty fields in
11970	// Patch requests.
11971	ForceSendFields []string `json:"-"`
11972
11973	// NullFields is a list of field names (e.g.
11974	// "AnalyzeQueryTextSentiment") to include in API requests with the JSON
11975	// null value. By default, fields with empty values are omitted from API
11976	// requests. However, any field with an empty value appearing in
11977	// NullFields will be sent to the server as null. It is an error if a
11978	// field in this list has a non-empty value. This may be used to include
11979	// null fields in Patch requests.
11980	NullFields []string `json:"-"`
11981}
11982
11983func (s *GoogleCloudDialogflowV2SentimentAnalysisRequestConfig) MarshalJSON() ([]byte, error) {
11984	type NoMethod GoogleCloudDialogflowV2SentimentAnalysisRequestConfig
11985	raw := NoMethod(*s)
11986	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11987}
11988
11989// GoogleCloudDialogflowV2SentimentAnalysisResult: The result of
11990// sentiment analysis. Sentiment analysis inspects user input and
11991// identifies the prevailing subjective opinion, especially to determine
11992// a user's attitude as positive, negative, or neutral. For
11993// Participants.DetectIntent, it needs to be configured in
11994// DetectIntentRequest.query_params. For
11995// Participants.StreamingDetectIntent, it needs to be configured in
11996// StreamingDetectIntentRequest.query_params. And for
11997// Participants.AnalyzeContent and Participants.StreamingAnalyzeContent,
11998// it needs to be configured in
11999// ConversationProfile.human_agent_assistant_config
12000type GoogleCloudDialogflowV2SentimentAnalysisResult struct {
12001	// QueryTextSentiment: The sentiment analysis result for `query_text`.
12002	QueryTextSentiment *GoogleCloudDialogflowV2Sentiment `json:"queryTextSentiment,omitempty"`
12003
12004	// ForceSendFields is a list of field names (e.g. "QueryTextSentiment")
12005	// to unconditionally include in API requests. By default, fields with
12006	// empty values are omitted from API requests. However, any non-pointer,
12007	// non-interface field appearing in ForceSendFields will be sent to the
12008	// server regardless of whether the field is empty or not. This may be
12009	// used to include empty fields in Patch requests.
12010	ForceSendFields []string `json:"-"`
12011
12012	// NullFields is a list of field names (e.g. "QueryTextSentiment") to
12013	// include in API requests with the JSON null value. By default, fields
12014	// with empty values are omitted from API requests. However, any field
12015	// with an empty value appearing in NullFields will be sent to the
12016	// server as null. It is an error if a field in this list has a
12017	// non-empty value. This may be used to include null fields in Patch
12018	// requests.
12019	NullFields []string `json:"-"`
12020}
12021
12022func (s *GoogleCloudDialogflowV2SentimentAnalysisResult) MarshalJSON() ([]byte, error) {
12023	type NoMethod GoogleCloudDialogflowV2SentimentAnalysisResult
12024	raw := NoMethod(*s)
12025	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12026}
12027
12028// GoogleCloudDialogflowV2SessionEntityType: A session represents a
12029// conversation between a Dialogflow agent and an end-user. You can
12030// create special entities, called session entities, during a session.
12031// Session entities can extend or replace custom entity types and only
12032// exist during the session that they were created for. All session
12033// data, including session entities, is stored by Dialogflow for 20
12034// minutes. For more information, see the session entity guide
12035// (https://cloud.google.com/dialogflow/docs/entities-session).
12036type GoogleCloudDialogflowV2SessionEntityType struct {
12037	// Entities: Required. The collection of entities associated with this
12038	// session entity type.
12039	Entities []*GoogleCloudDialogflowV2EntityTypeEntity `json:"entities,omitempty"`
12040
12041	// EntityOverrideMode: Required. Indicates whether the additional data
12042	// should override or supplement the custom entity type definition.
12043	//
12044	// Possible values:
12045	//   "ENTITY_OVERRIDE_MODE_UNSPECIFIED" - Not specified. This value
12046	// should be never used.
12047	//   "ENTITY_OVERRIDE_MODE_OVERRIDE" - The collection of session
12048	// entities overrides the collection of entities in the corresponding
12049	// custom entity type.
12050	//   "ENTITY_OVERRIDE_MODE_SUPPLEMENT" - The collection of session
12051	// entities extends the collection of entities in the corresponding
12052	// custom entity type. Note: Even in this override mode calls to
12053	// `ListSessionEntityTypes`, `GetSessionEntityType`,
12054	// `CreateSessionEntityType` and `UpdateSessionEntityType` only return
12055	// the additional entities added in this session entity type. If you
12056	// want to get the supplemented list, please call
12057	// EntityTypes.GetEntityType on the custom entity type and merge.
12058	EntityOverrideMode string `json:"entityOverrideMode,omitempty"`
12059
12060	// Name: Required. The unique identifier of this session entity type.
12061	// Format: `projects//agent/sessions//entityTypes/`, or
12062	// `projects//agent/environments//users//sessions//entityTypes/`. If
12063	// `Environment ID` is not specified, we assume default 'draft'
12064	// environment. If `User ID` is not specified, we assume default '-'
12065	// user. `` must be the display name of an existing entity type in the
12066	// same agent that will be overridden or supplemented.
12067	Name string `json:"name,omitempty"`
12068
12069	// ServerResponse contains the HTTP response code and headers from the
12070	// server.
12071	googleapi.ServerResponse `json:"-"`
12072
12073	// ForceSendFields is a list of field names (e.g. "Entities") to
12074	// unconditionally include in API requests. By default, fields with
12075	// empty values are omitted from API requests. However, any non-pointer,
12076	// non-interface field appearing in ForceSendFields will be sent to the
12077	// server regardless of whether the field is empty or not. This may be
12078	// used to include empty fields in Patch requests.
12079	ForceSendFields []string `json:"-"`
12080
12081	// NullFields is a list of field names (e.g. "Entities") to include in
12082	// API requests with the JSON null value. By default, fields with empty
12083	// values are omitted from API requests. However, any field with an
12084	// empty value appearing in NullFields will be sent to the server as
12085	// null. It is an error if a field in this list has a non-empty value.
12086	// This may be used to include null fields in Patch requests.
12087	NullFields []string `json:"-"`
12088}
12089
12090func (s *GoogleCloudDialogflowV2SessionEntityType) MarshalJSON() ([]byte, error) {
12091	type NoMethod GoogleCloudDialogflowV2SessionEntityType
12092	raw := NoMethod(*s)
12093	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12094}
12095
12096// GoogleCloudDialogflowV2SpeechContext: Hints for the speech recognizer
12097// to help with recognition in a specific conversation state.
12098type GoogleCloudDialogflowV2SpeechContext struct {
12099	// Boost: Optional. Boost for this context compared to other contexts: *
12100	// If the boost is positive, Dialogflow will increase the probability
12101	// that the phrases in this context are recognized over similar sounding
12102	// phrases. * If the boost is unspecified or non-positive, Dialogflow
12103	// will not apply any boost. Dialogflow recommends that you use boosts
12104	// in the range (0, 20] and that you find a value that fits your use
12105	// case with binary search.
12106	Boost float64 `json:"boost,omitempty"`
12107
12108	// Phrases: Optional. A list of strings containing words and phrases
12109	// that the speech recognizer should recognize with higher likelihood.
12110	// This list can be used to: * improve accuracy for words and phrases
12111	// you expect the user to say, e.g. typical commands for your Dialogflow
12112	// agent * add additional words to the speech recognizer vocabulary *
12113	// ... See the Cloud Speech documentation
12114	// (https://cloud.google.com/speech-to-text/quotas) for usage limits.
12115	Phrases []string `json:"phrases,omitempty"`
12116
12117	// ForceSendFields is a list of field names (e.g. "Boost") to
12118	// unconditionally include in API requests. By default, fields with
12119	// empty values are omitted from API requests. However, any non-pointer,
12120	// non-interface field appearing in ForceSendFields will be sent to the
12121	// server regardless of whether the field is empty or not. This may be
12122	// used to include empty fields in Patch requests.
12123	ForceSendFields []string `json:"-"`
12124
12125	// NullFields is a list of field names (e.g. "Boost") to include in API
12126	// requests with the JSON null value. By default, fields with empty
12127	// values are omitted from API requests. However, any field with an
12128	// empty value appearing in NullFields will be sent to the server as
12129	// null. It is an error if a field in this list has a non-empty value.
12130	// This may be used to include null fields in Patch requests.
12131	NullFields []string `json:"-"`
12132}
12133
12134func (s *GoogleCloudDialogflowV2SpeechContext) MarshalJSON() ([]byte, error) {
12135	type NoMethod GoogleCloudDialogflowV2SpeechContext
12136	raw := NoMethod(*s)
12137	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12138}
12139
12140func (s *GoogleCloudDialogflowV2SpeechContext) UnmarshalJSON(data []byte) error {
12141	type NoMethod GoogleCloudDialogflowV2SpeechContext
12142	var s1 struct {
12143		Boost gensupport.JSONFloat64 `json:"boost"`
12144		*NoMethod
12145	}
12146	s1.NoMethod = (*NoMethod)(s)
12147	if err := json.Unmarshal(data, &s1); err != nil {
12148		return err
12149	}
12150	s.Boost = float64(s1.Boost)
12151	return nil
12152}
12153
12154// GoogleCloudDialogflowV2SpeechToTextConfig: Configures speech
12155// transcription for ConversationProfile.
12156type GoogleCloudDialogflowV2SpeechToTextConfig struct {
12157	// SpeechModelVariant: Optional. The speech model used in speech to
12158	// text. `SPEECH_MODEL_VARIANT_UNSPECIFIED`, `USE_BEST_AVAILABLE` will
12159	// be treated as `USE_ENHANCED`. It can be overridden in
12160	// AnalyzeContentRequest and StreamingAnalyzeContentRequest request.
12161	//
12162	// Possible values:
12163	//   "SPEECH_MODEL_VARIANT_UNSPECIFIED" - No model variant specified. In
12164	// this case Dialogflow defaults to USE_BEST_AVAILABLE.
12165	//   "USE_BEST_AVAILABLE" - Use the best available variant of the Speech
12166	// model that the caller is eligible for. Please see the [Dialogflow
12167	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
12168	// to make your project eligible for enhanced models.
12169	//   "USE_STANDARD" - Use standard model variant even if an enhanced
12170	// model is available. See the [Cloud Speech
12171	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
12172	// odels) for details about enhanced models.
12173	//   "USE_ENHANCED" - Use an enhanced model variant: * If an enhanced
12174	// variant does not exist for the given model and request language,
12175	// Dialogflow falls back to the standard variant. The [Cloud Speech
12176	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
12177	// odels) describes which models have enhanced variants. * If the API
12178	// caller isn't eligible for enhanced models, Dialogflow returns an
12179	// error. Please see the [Dialogflow
12180	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
12181	// to make your project eligible.
12182	SpeechModelVariant string `json:"speechModelVariant,omitempty"`
12183
12184	// ForceSendFields is a list of field names (e.g. "SpeechModelVariant")
12185	// to unconditionally include in API requests. By default, fields with
12186	// empty values are omitted from API requests. However, any non-pointer,
12187	// non-interface field appearing in ForceSendFields will be sent to the
12188	// server regardless of whether the field is empty or not. This may be
12189	// used to include empty fields in Patch requests.
12190	ForceSendFields []string `json:"-"`
12191
12192	// NullFields is a list of field names (e.g. "SpeechModelVariant") to
12193	// include in API requests with the JSON null value. By default, fields
12194	// with empty values are omitted from API requests. However, any field
12195	// with an empty value appearing in NullFields will be sent to the
12196	// server as null. It is an error if a field in this list has a
12197	// non-empty value. This may be used to include null fields in Patch
12198	// requests.
12199	NullFields []string `json:"-"`
12200}
12201
12202func (s *GoogleCloudDialogflowV2SpeechToTextConfig) MarshalJSON() ([]byte, error) {
12203	type NoMethod GoogleCloudDialogflowV2SpeechToTextConfig
12204	raw := NoMethod(*s)
12205	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12206}
12207
12208// GoogleCloudDialogflowV2SuggestArticlesRequest: The request message
12209// for Participants.SuggestArticles.
12210type GoogleCloudDialogflowV2SuggestArticlesRequest struct {
12211	// ContextSize: Max number of messages prior to and including
12212	// latest_message to use as context when compiling the suggestion. By
12213	// default 20 and at most 50.
12214	ContextSize int64 `json:"contextSize,omitempty"`
12215
12216	// LatestMessage: The name of the latest conversation message to compile
12217	// suggestion for. If empty, it will be the latest message of the
12218	// conversation. Format:
12219	// `projects//locations//conversations//messages/`.
12220	LatestMessage string `json:"latestMessage,omitempty"`
12221
12222	// ForceSendFields is a list of field names (e.g. "ContextSize") to
12223	// unconditionally include in API requests. By default, fields with
12224	// empty values are omitted from API requests. However, any non-pointer,
12225	// non-interface field appearing in ForceSendFields will be sent to the
12226	// server regardless of whether the field is empty or not. This may be
12227	// used to include empty fields in Patch requests.
12228	ForceSendFields []string `json:"-"`
12229
12230	// NullFields is a list of field names (e.g. "ContextSize") to include
12231	// in API requests with the JSON null value. By default, fields with
12232	// empty values are omitted from API requests. However, any field with
12233	// an empty value appearing in NullFields will be sent to the server as
12234	// null. It is an error if a field in this list has a non-empty value.
12235	// This may be used to include null fields in Patch requests.
12236	NullFields []string `json:"-"`
12237}
12238
12239func (s *GoogleCloudDialogflowV2SuggestArticlesRequest) MarshalJSON() ([]byte, error) {
12240	type NoMethod GoogleCloudDialogflowV2SuggestArticlesRequest
12241	raw := NoMethod(*s)
12242	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12243}
12244
12245// GoogleCloudDialogflowV2SuggestArticlesResponse: The response message
12246// for Participants.SuggestArticles.
12247type GoogleCloudDialogflowV2SuggestArticlesResponse struct {
12248	// ArticleAnswers: Articles ordered by score in descending order.
12249	ArticleAnswers []*GoogleCloudDialogflowV2ArticleAnswer `json:"articleAnswers,omitempty"`
12250
12251	// ContextSize: Number of messages prior to and including latest_message
12252	// to compile the suggestion. It may be smaller than the
12253	// SuggestArticlesRequest.context_size field in the request if there
12254	// aren't that many messages in the conversation.
12255	ContextSize int64 `json:"contextSize,omitempty"`
12256
12257	// LatestMessage: The name of the latest conversation message used to
12258	// compile suggestion for. Format:
12259	// `projects//locations//conversations//messages/`.
12260	LatestMessage string `json:"latestMessage,omitempty"`
12261
12262	// ServerResponse contains the HTTP response code and headers from the
12263	// server.
12264	googleapi.ServerResponse `json:"-"`
12265
12266	// ForceSendFields is a list of field names (e.g. "ArticleAnswers") to
12267	// unconditionally include in API requests. By default, fields with
12268	// empty values are omitted from API requests. However, any non-pointer,
12269	// non-interface field appearing in ForceSendFields will be sent to the
12270	// server regardless of whether the field is empty or not. This may be
12271	// used to include empty fields in Patch requests.
12272	ForceSendFields []string `json:"-"`
12273
12274	// NullFields is a list of field names (e.g. "ArticleAnswers") to
12275	// include in API requests with the JSON null value. By default, fields
12276	// with empty values are omitted from API requests. However, any field
12277	// with an empty value appearing in NullFields will be sent to the
12278	// server as null. It is an error if a field in this list has a
12279	// non-empty value. This may be used to include null fields in Patch
12280	// requests.
12281	NullFields []string `json:"-"`
12282}
12283
12284func (s *GoogleCloudDialogflowV2SuggestArticlesResponse) MarshalJSON() ([]byte, error) {
12285	type NoMethod GoogleCloudDialogflowV2SuggestArticlesResponse
12286	raw := NoMethod(*s)
12287	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12288}
12289
12290// GoogleCloudDialogflowV2SuggestFaqAnswersRequest: The request message
12291// for Participants.SuggestFaqAnswers.
12292type GoogleCloudDialogflowV2SuggestFaqAnswersRequest struct {
12293	// ContextSize: Max number of messages prior to and including
12294	// [latest_message] to use as context when compiling the suggestion. By
12295	// default 20 and at most 50.
12296	ContextSize int64 `json:"contextSize,omitempty"`
12297
12298	// LatestMessage: The name of the latest conversation message to compile
12299	// suggestion for. If empty, it will be the latest message of the
12300	// conversation. Format:
12301	// `projects//locations//conversations//messages/`.
12302	LatestMessage string `json:"latestMessage,omitempty"`
12303
12304	// ForceSendFields is a list of field names (e.g. "ContextSize") to
12305	// unconditionally include in API requests. By default, fields with
12306	// empty values are omitted from API requests. However, any non-pointer,
12307	// non-interface field appearing in ForceSendFields will be sent to the
12308	// server regardless of whether the field is empty or not. This may be
12309	// used to include empty fields in Patch requests.
12310	ForceSendFields []string `json:"-"`
12311
12312	// NullFields is a list of field names (e.g. "ContextSize") to include
12313	// in API requests with the JSON null value. By default, fields with
12314	// empty values are omitted from API requests. However, any field with
12315	// an empty value appearing in NullFields will be sent to the server as
12316	// null. It is an error if a field in this list has a non-empty value.
12317	// This may be used to include null fields in Patch requests.
12318	NullFields []string `json:"-"`
12319}
12320
12321func (s *GoogleCloudDialogflowV2SuggestFaqAnswersRequest) MarshalJSON() ([]byte, error) {
12322	type NoMethod GoogleCloudDialogflowV2SuggestFaqAnswersRequest
12323	raw := NoMethod(*s)
12324	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12325}
12326
12327// GoogleCloudDialogflowV2SuggestFaqAnswersResponse: The request message
12328// for Participants.SuggestFaqAnswers.
12329type GoogleCloudDialogflowV2SuggestFaqAnswersResponse struct {
12330	// ContextSize: Number of messages prior to and including latest_message
12331	// to compile the suggestion. It may be smaller than the
12332	// SuggestFaqAnswersRequest.context_size field in the request if there
12333	// aren't that many messages in the conversation.
12334	ContextSize int64 `json:"contextSize,omitempty"`
12335
12336	// FaqAnswers: Answers extracted from FAQ documents.
12337	FaqAnswers []*GoogleCloudDialogflowV2FaqAnswer `json:"faqAnswers,omitempty"`
12338
12339	// LatestMessage: The name of the latest conversation message used to
12340	// compile suggestion for. Format:
12341	// `projects//locations//conversations//messages/`.
12342	LatestMessage string `json:"latestMessage,omitempty"`
12343
12344	// ServerResponse contains the HTTP response code and headers from the
12345	// server.
12346	googleapi.ServerResponse `json:"-"`
12347
12348	// ForceSendFields is a list of field names (e.g. "ContextSize") to
12349	// unconditionally include in API requests. By default, fields with
12350	// empty values are omitted from API requests. However, any non-pointer,
12351	// non-interface field appearing in ForceSendFields will be sent to the
12352	// server regardless of whether the field is empty or not. This may be
12353	// used to include empty fields in Patch requests.
12354	ForceSendFields []string `json:"-"`
12355
12356	// NullFields is a list of field names (e.g. "ContextSize") to include
12357	// in API requests with the JSON null value. By default, fields with
12358	// empty values are omitted from API requests. However, any field with
12359	// an empty value appearing in NullFields will be sent to the server as
12360	// null. It is an error if a field in this list has a non-empty value.
12361	// This may be used to include null fields in Patch requests.
12362	NullFields []string `json:"-"`
12363}
12364
12365func (s *GoogleCloudDialogflowV2SuggestFaqAnswersResponse) MarshalJSON() ([]byte, error) {
12366	type NoMethod GoogleCloudDialogflowV2SuggestFaqAnswersResponse
12367	raw := NoMethod(*s)
12368	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12369}
12370
12371// GoogleCloudDialogflowV2SuggestionFeature: The type of Human Agent
12372// Assistant API suggestion to perform, and the maximum number of
12373// results to return for that type. Multiple `Feature` objects can be
12374// specified in the `features` list.
12375type GoogleCloudDialogflowV2SuggestionFeature struct {
12376	// Type: Type of Human Agent Assistant API feature to request.
12377	//
12378	// Possible values:
12379	//   "TYPE_UNSPECIFIED" - Unspecified feature type.
12380	//   "ARTICLE_SUGGESTION" - Run article suggestion model.
12381	//   "FAQ" - Run FAQ model.
12382	Type string `json:"type,omitempty"`
12383
12384	// ForceSendFields is a list of field names (e.g. "Type") to
12385	// unconditionally include in API requests. By default, fields with
12386	// empty values are omitted from API requests. However, any non-pointer,
12387	// non-interface field appearing in ForceSendFields will be sent to the
12388	// server regardless of whether the field is empty or not. This may be
12389	// used to include empty fields in Patch requests.
12390	ForceSendFields []string `json:"-"`
12391
12392	// NullFields is a list of field names (e.g. "Type") to include in API
12393	// requests with the JSON null value. By default, fields with empty
12394	// values are omitted from API requests. However, any field with an
12395	// empty value appearing in NullFields will be sent to the server as
12396	// null. It is an error if a field in this list has a non-empty value.
12397	// This may be used to include null fields in Patch requests.
12398	NullFields []string `json:"-"`
12399}
12400
12401func (s *GoogleCloudDialogflowV2SuggestionFeature) MarshalJSON() ([]byte, error) {
12402	type NoMethod GoogleCloudDialogflowV2SuggestionFeature
12403	raw := NoMethod(*s)
12404	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12405}
12406
12407// GoogleCloudDialogflowV2SuggestionResult: One response of different
12408// type of suggestion response which is used in the response of
12409// Participants.AnalyzeContent and Participants.AnalyzeContent, as well
12410// as HumanAgentAssistantEvent.
12411type GoogleCloudDialogflowV2SuggestionResult struct {
12412	// Error: Error status if the request failed.
12413	Error *GoogleRpcStatus `json:"error,omitempty"`
12414
12415	// SuggestArticlesResponse: SuggestArticlesResponse if request is for
12416	// ARTICLE_SUGGESTION.
12417	SuggestArticlesResponse *GoogleCloudDialogflowV2SuggestArticlesResponse `json:"suggestArticlesResponse,omitempty"`
12418
12419	// SuggestFaqAnswersResponse: SuggestFaqAnswersResponse if request is
12420	// for FAQ_ANSWER.
12421	SuggestFaqAnswersResponse *GoogleCloudDialogflowV2SuggestFaqAnswersResponse `json:"suggestFaqAnswersResponse,omitempty"`
12422
12423	// ForceSendFields is a list of field names (e.g. "Error") to
12424	// unconditionally include in API requests. By default, fields with
12425	// empty values are omitted from API requests. However, any non-pointer,
12426	// non-interface field appearing in ForceSendFields will be sent to the
12427	// server regardless of whether the field is empty or not. This may be
12428	// used to include empty fields in Patch requests.
12429	ForceSendFields []string `json:"-"`
12430
12431	// NullFields is a list of field names (e.g. "Error") to include in API
12432	// requests with the JSON null value. By default, fields with empty
12433	// values are omitted from API requests. However, any field with an
12434	// empty value appearing in NullFields will be sent to the server as
12435	// null. It is an error if a field in this list has a non-empty value.
12436	// This may be used to include null fields in Patch requests.
12437	NullFields []string `json:"-"`
12438}
12439
12440func (s *GoogleCloudDialogflowV2SuggestionResult) MarshalJSON() ([]byte, error) {
12441	type NoMethod GoogleCloudDialogflowV2SuggestionResult
12442	raw := NoMethod(*s)
12443	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12444}
12445
12446// GoogleCloudDialogflowV2SynthesizeSpeechConfig: Configuration of how
12447// speech should be synthesized.
12448type GoogleCloudDialogflowV2SynthesizeSpeechConfig struct {
12449	// EffectsProfileId: Optional. An identifier which selects 'audio
12450	// effects' profiles that are applied on (post synthesized) text to
12451	// speech. Effects are applied on top of each other in the order they
12452	// are given.
12453	EffectsProfileId []string `json:"effectsProfileId,omitempty"`
12454
12455	// Pitch: Optional. Speaking pitch, in the range [-20.0, 20.0]. 20 means
12456	// increase 20 semitones from the original pitch. -20 means decrease 20
12457	// semitones from the original pitch.
12458	Pitch float64 `json:"pitch,omitempty"`
12459
12460	// SpeakingRate: Optional. Speaking rate/speed, in the range [0.25,
12461	// 4.0]. 1.0 is the normal native speed supported by the specific voice.
12462	// 2.0 is twice as fast, and 0.5 is half as fast. If unset(0.0),
12463	// defaults to the native 1.0 speed. Any other values < 0.25 or > 4.0
12464	// will return an error.
12465	SpeakingRate float64 `json:"speakingRate,omitempty"`
12466
12467	// Voice: Optional. The desired voice of the synthesized audio.
12468	Voice *GoogleCloudDialogflowV2VoiceSelectionParams `json:"voice,omitempty"`
12469
12470	// VolumeGainDb: Optional. Volume gain (in dB) of the normal native
12471	// volume supported by the specific voice, in the range [-96.0, 16.0].
12472	// If unset, or set to a value of 0.0 (dB), will play at normal native
12473	// signal amplitude. A value of -6.0 (dB) will play at approximately
12474	// half the amplitude of the normal native signal amplitude. A value of
12475	// +6.0 (dB) will play at approximately twice the amplitude of the
12476	// normal native signal amplitude. We strongly recommend not to exceed
12477	// +10 (dB) as there's usually no effective increase in loudness for any
12478	// value greater than that.
12479	VolumeGainDb float64 `json:"volumeGainDb,omitempty"`
12480
12481	// ForceSendFields is a list of field names (e.g. "EffectsProfileId") to
12482	// unconditionally include in API requests. By default, fields with
12483	// empty values are omitted from API requests. However, any non-pointer,
12484	// non-interface field appearing in ForceSendFields will be sent to the
12485	// server regardless of whether the field is empty or not. This may be
12486	// used to include empty fields in Patch requests.
12487	ForceSendFields []string `json:"-"`
12488
12489	// NullFields is a list of field names (e.g. "EffectsProfileId") to
12490	// include in API requests with the JSON null value. By default, fields
12491	// with empty values are omitted from API requests. However, any field
12492	// with an empty value appearing in NullFields will be sent to the
12493	// server as null. It is an error if a field in this list has a
12494	// non-empty value. This may be used to include null fields in Patch
12495	// requests.
12496	NullFields []string `json:"-"`
12497}
12498
12499func (s *GoogleCloudDialogflowV2SynthesizeSpeechConfig) MarshalJSON() ([]byte, error) {
12500	type NoMethod GoogleCloudDialogflowV2SynthesizeSpeechConfig
12501	raw := NoMethod(*s)
12502	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12503}
12504
12505func (s *GoogleCloudDialogflowV2SynthesizeSpeechConfig) UnmarshalJSON(data []byte) error {
12506	type NoMethod GoogleCloudDialogflowV2SynthesizeSpeechConfig
12507	var s1 struct {
12508		Pitch        gensupport.JSONFloat64 `json:"pitch"`
12509		SpeakingRate gensupport.JSONFloat64 `json:"speakingRate"`
12510		VolumeGainDb gensupport.JSONFloat64 `json:"volumeGainDb"`
12511		*NoMethod
12512	}
12513	s1.NoMethod = (*NoMethod)(s)
12514	if err := json.Unmarshal(data, &s1); err != nil {
12515		return err
12516	}
12517	s.Pitch = float64(s1.Pitch)
12518	s.SpeakingRate = float64(s1.SpeakingRate)
12519	s.VolumeGainDb = float64(s1.VolumeGainDb)
12520	return nil
12521}
12522
12523// GoogleCloudDialogflowV2TextInput: Represents the natural language
12524// text to be processed.
12525type GoogleCloudDialogflowV2TextInput struct {
12526	// LanguageCode: Required. The language of this conversational query.
12527	// See Language Support
12528	// (https://cloud.google.com/dialogflow/docs/reference/language) for a
12529	// list of the currently supported language codes. Note that queries in
12530	// the same session do not necessarily need to specify the same
12531	// language.
12532	LanguageCode string `json:"languageCode,omitempty"`
12533
12534	// Text: Required. The UTF-8 encoded natural language text to be
12535	// processed. Text length must not exceed 256 characters.
12536	Text string `json:"text,omitempty"`
12537
12538	// ForceSendFields is a list of field names (e.g. "LanguageCode") to
12539	// unconditionally include in API requests. By default, fields with
12540	// empty values are omitted from API requests. However, any non-pointer,
12541	// non-interface field appearing in ForceSendFields will be sent to the
12542	// server regardless of whether the field is empty or not. This may be
12543	// used to include empty fields in Patch requests.
12544	ForceSendFields []string `json:"-"`
12545
12546	// NullFields is a list of field names (e.g. "LanguageCode") to include
12547	// in API requests with the JSON null value. By default, fields with
12548	// empty values are omitted from API requests. However, any field with
12549	// an empty value appearing in NullFields will be sent to the server as
12550	// null. It is an error if a field in this list has a non-empty value.
12551	// This may be used to include null fields in Patch requests.
12552	NullFields []string `json:"-"`
12553}
12554
12555func (s *GoogleCloudDialogflowV2TextInput) MarshalJSON() ([]byte, error) {
12556	type NoMethod GoogleCloudDialogflowV2TextInput
12557	raw := NoMethod(*s)
12558	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12559}
12560
12561// GoogleCloudDialogflowV2TrainAgentRequest: The request message for
12562// Agents.TrainAgent.
12563type GoogleCloudDialogflowV2TrainAgentRequest struct {
12564}
12565
12566// GoogleCloudDialogflowV2ValidationError: Represents a single
12567// validation error.
12568type GoogleCloudDialogflowV2ValidationError struct {
12569	// Entries: The names of the entries that the error is associated with.
12570	// Format: - "projects//agent", if the error is associated with the
12571	// entire agent. - "projects//agent/intents/", if the error is
12572	// associated with certain intents. -
12573	// "projects//agent/intents//trainingPhrases/", if the error is
12574	// associated with certain intent training phrases. -
12575	// "projects//agent/intents//parameters/", if the error is associated
12576	// with certain intent parameters. - "projects//agent/entities/", if the
12577	// error is associated with certain entities.
12578	Entries []string `json:"entries,omitempty"`
12579
12580	// ErrorMessage: The detailed error messsage.
12581	ErrorMessage string `json:"errorMessage,omitempty"`
12582
12583	// Severity: The severity of the error.
12584	//
12585	// Possible values:
12586	//   "SEVERITY_UNSPECIFIED" - Not specified. This value should never be
12587	// used.
12588	//   "INFO" - The agent doesn't follow Dialogflow best practices.
12589	//   "WARNING" - The agent may not behave as expected.
12590	//   "ERROR" - The agent may experience partial failures.
12591	//   "CRITICAL" - The agent may completely fail.
12592	Severity string `json:"severity,omitempty"`
12593
12594	// ForceSendFields is a list of field names (e.g. "Entries") to
12595	// unconditionally include in API requests. By default, fields with
12596	// empty values are omitted from API requests. However, any non-pointer,
12597	// non-interface field appearing in ForceSendFields will be sent to the
12598	// server regardless of whether the field is empty or not. This may be
12599	// used to include empty fields in Patch requests.
12600	ForceSendFields []string `json:"-"`
12601
12602	// NullFields is a list of field names (e.g. "Entries") 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 *GoogleCloudDialogflowV2ValidationError) MarshalJSON() ([]byte, error) {
12612	type NoMethod GoogleCloudDialogflowV2ValidationError
12613	raw := NoMethod(*s)
12614	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12615}
12616
12617// GoogleCloudDialogflowV2ValidationResult: Represents the output of
12618// agent validation.
12619type GoogleCloudDialogflowV2ValidationResult struct {
12620	// ValidationErrors: Contains all validation errors.
12621	ValidationErrors []*GoogleCloudDialogflowV2ValidationError `json:"validationErrors,omitempty"`
12622
12623	// ServerResponse contains the HTTP response code and headers from the
12624	// server.
12625	googleapi.ServerResponse `json:"-"`
12626
12627	// ForceSendFields is a list of field names (e.g. "ValidationErrors") to
12628	// unconditionally include in API requests. By default, fields with
12629	// empty values are omitted from API requests. However, any non-pointer,
12630	// non-interface field appearing in ForceSendFields will be sent to the
12631	// server regardless of whether the field is empty or not. This may be
12632	// used to include empty fields in Patch requests.
12633	ForceSendFields []string `json:"-"`
12634
12635	// NullFields is a list of field names (e.g. "ValidationErrors") to
12636	// include in API requests with the JSON null value. By default, fields
12637	// with empty values are omitted from API requests. However, any field
12638	// with an empty value appearing in NullFields will be sent to the
12639	// server as null. It is an error if a field in this list has a
12640	// non-empty value. This may be used to include null fields in Patch
12641	// requests.
12642	NullFields []string `json:"-"`
12643}
12644
12645func (s *GoogleCloudDialogflowV2ValidationResult) MarshalJSON() ([]byte, error) {
12646	type NoMethod GoogleCloudDialogflowV2ValidationResult
12647	raw := NoMethod(*s)
12648	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12649}
12650
12651// GoogleCloudDialogflowV2VoiceSelectionParams: Description of which
12652// voice to use for speech synthesis.
12653type GoogleCloudDialogflowV2VoiceSelectionParams struct {
12654	// Name: Optional. The name of the voice. If not set, the service will
12655	// choose a voice based on the other parameters such as language_code
12656	// and ssml_gender.
12657	Name string `json:"name,omitempty"`
12658
12659	// SsmlGender: Optional. The preferred gender of the voice. If not set,
12660	// the service will choose a voice based on the other parameters such as
12661	// language_code and name. Note that this is only a preference, not
12662	// requirement. If a voice of the appropriate gender is not available,
12663	// the synthesizer should substitute a voice with a different gender
12664	// rather than failing the request.
12665	//
12666	// Possible values:
12667	//   "SSML_VOICE_GENDER_UNSPECIFIED" - An unspecified gender, which
12668	// means that the client doesn't care which gender the selected voice
12669	// will have.
12670	//   "SSML_VOICE_GENDER_MALE" - A male voice.
12671	//   "SSML_VOICE_GENDER_FEMALE" - A female voice.
12672	//   "SSML_VOICE_GENDER_NEUTRAL" - A gender-neutral voice.
12673	SsmlGender string `json:"ssmlGender,omitempty"`
12674
12675	// ForceSendFields is a list of field names (e.g. "Name") to
12676	// unconditionally include in API requests. By default, fields with
12677	// empty values are omitted from API requests. However, any non-pointer,
12678	// non-interface field appearing in ForceSendFields will be sent to the
12679	// server regardless of whether the field is empty or not. This may be
12680	// used to include empty fields in Patch requests.
12681	ForceSendFields []string `json:"-"`
12682
12683	// NullFields is a list of field names (e.g. "Name") to include in API
12684	// requests with the JSON null value. By default, fields with empty
12685	// values are omitted from API requests. However, any field with an
12686	// empty value appearing in NullFields will be sent to the server as
12687	// null. It is an error if a field in this list has a non-empty value.
12688	// This may be used to include null fields in Patch requests.
12689	NullFields []string `json:"-"`
12690}
12691
12692func (s *GoogleCloudDialogflowV2VoiceSelectionParams) MarshalJSON() ([]byte, error) {
12693	type NoMethod GoogleCloudDialogflowV2VoiceSelectionParams
12694	raw := NoMethod(*s)
12695	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12696}
12697
12698// GoogleCloudDialogflowV2WebhookRequest: The request message for a
12699// webhook call.
12700type GoogleCloudDialogflowV2WebhookRequest struct {
12701	// OriginalDetectIntentRequest: Optional. The contents of the original
12702	// request that was passed to `[Streaming]DetectIntent` call.
12703	OriginalDetectIntentRequest *GoogleCloudDialogflowV2OriginalDetectIntentRequest `json:"originalDetectIntentRequest,omitempty"`
12704
12705	// QueryResult: The result of the conversational query or event
12706	// processing. Contains the same value as
12707	// `[Streaming]DetectIntentResponse.query_result`.
12708	QueryResult *GoogleCloudDialogflowV2QueryResult `json:"queryResult,omitempty"`
12709
12710	// ResponseId: The unique identifier of the response. Contains the same
12711	// value as `[Streaming]DetectIntentResponse.response_id`.
12712	ResponseId string `json:"responseId,omitempty"`
12713
12714	// Session: The unique identifier of detectIntent request session. Can
12715	// be used to identify end-user inside webhook implementation. Format:
12716	// `projects//agent/sessions/`, or
12717	// `projects//agent/environments//users//sessions/`.
12718	Session string `json:"session,omitempty"`
12719
12720	// ForceSendFields is a list of field names (e.g.
12721	// "OriginalDetectIntentRequest") to unconditionally include in API
12722	// requests. By default, fields with empty values are omitted from API
12723	// requests. However, any non-pointer, non-interface field appearing in
12724	// ForceSendFields will be sent to the server regardless of whether the
12725	// field is empty or not. This may be used to include empty fields in
12726	// Patch requests.
12727	ForceSendFields []string `json:"-"`
12728
12729	// NullFields is a list of field names (e.g.
12730	// "OriginalDetectIntentRequest") to include in API requests with the
12731	// JSON null value. By default, fields with empty values are omitted
12732	// from API requests. However, any field with an empty value appearing
12733	// in NullFields will be sent to the server as null. It is an error if a
12734	// field in this list has a non-empty value. This may be used to include
12735	// null fields in Patch requests.
12736	NullFields []string `json:"-"`
12737}
12738
12739func (s *GoogleCloudDialogflowV2WebhookRequest) MarshalJSON() ([]byte, error) {
12740	type NoMethod GoogleCloudDialogflowV2WebhookRequest
12741	raw := NoMethod(*s)
12742	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12743}
12744
12745// GoogleCloudDialogflowV2WebhookResponse: The response message for a
12746// webhook call. This response is validated by the Dialogflow server. If
12747// validation fails, an error will be returned in the
12748// QueryResult.diagnostic_info field. Setting JSON fields to an empty
12749// value with the wrong type is a common error. To avoid this error: -
12750// Use "" for empty strings - Use `{}` or `null` for empty objects -
12751// Use `[]` or `null` for empty arrays For more information, see the
12752// Protocol Buffers Language Guide
12753// (https://developers.google.com/protocol-buffers/docs/proto3#json).
12754type GoogleCloudDialogflowV2WebhookResponse struct {
12755	// FollowupEventInput: Optional. Invokes the supplied events. When this
12756	// field is set, Dialogflow ignores the `fulfillment_text`,
12757	// `fulfillment_messages`, and `payload` fields.
12758	FollowupEventInput *GoogleCloudDialogflowV2EventInput `json:"followupEventInput,omitempty"`
12759
12760	// FulfillmentMessages: Optional. The rich response messages intended
12761	// for the end-user. When provided, Dialogflow uses this field to
12762	// populate QueryResult.fulfillment_messages sent to the integration or
12763	// API caller.
12764	FulfillmentMessages []*GoogleCloudDialogflowV2IntentMessage `json:"fulfillmentMessages,omitempty"`
12765
12766	// FulfillmentText: Optional. The text response message intended for the
12767	// end-user. It is recommended to use
12768	// `fulfillment_messages.text.text[0]` instead. When provided,
12769	// Dialogflow uses this field to populate QueryResult.fulfillment_text
12770	// sent to the integration or API caller.
12771	FulfillmentText string `json:"fulfillmentText,omitempty"`
12772
12773	// OutputContexts: Optional. The collection of output contexts that will
12774	// overwrite currently active contexts for the session and reset their
12775	// lifespans. When provided, Dialogflow uses this field to populate
12776	// QueryResult.output_contexts sent to the integration or API caller.
12777	OutputContexts []*GoogleCloudDialogflowV2Context `json:"outputContexts,omitempty"`
12778
12779	// Payload: Optional. This field can be used to pass custom data from
12780	// your webhook to the integration or API caller. Arbitrary JSON objects
12781	// are supported. When provided, Dialogflow uses this field to populate
12782	// QueryResult.webhook_payload sent to the integration or API caller.
12783	// This field is also used by the Google Assistant integration
12784	// (https://cloud.google.com/dialogflow/docs/integrations/aog) for rich
12785	// response messages. See the format definition at Google Assistant
12786	// Dialogflow webhook format
12787	// (https://developers.google.com/assistant/actions/build/json/dialogflow-webhook-json)
12788	Payload googleapi.RawMessage `json:"payload,omitempty"`
12789
12790	// SessionEntityTypes: Optional. Additional session entity types to
12791	// replace or extend developer entity types with. The entity synonyms
12792	// apply to all languages and persist for the session. Setting this data
12793	// from a webhook overwrites the session entity types that have been set
12794	// using `detectIntent`, `streamingDetectIntent` or SessionEntityType
12795	// management methods.
12796	SessionEntityTypes []*GoogleCloudDialogflowV2SessionEntityType `json:"sessionEntityTypes,omitempty"`
12797
12798	// Source: Optional. A custom field used to identify the webhook source.
12799	// Arbitrary strings are supported. When provided, Dialogflow uses this
12800	// field to populate QueryResult.webhook_source sent to the integration
12801	// or API caller.
12802	Source string `json:"source,omitempty"`
12803
12804	// ForceSendFields is a list of field names (e.g. "FollowupEventInput")
12805	// to unconditionally include in API requests. By default, fields with
12806	// empty values are omitted from API requests. However, any non-pointer,
12807	// non-interface field appearing in ForceSendFields will be sent to the
12808	// server regardless of whether the field is empty or not. This may be
12809	// used to include empty fields in Patch requests.
12810	ForceSendFields []string `json:"-"`
12811
12812	// NullFields is a list of field names (e.g. "FollowupEventInput") to
12813	// include in API requests with the JSON null value. By default, fields
12814	// with empty values are omitted from API requests. However, any field
12815	// with an empty value appearing in NullFields will be sent to the
12816	// server as null. It is an error if a field in this list has a
12817	// non-empty value. This may be used to include null fields in Patch
12818	// requests.
12819	NullFields []string `json:"-"`
12820}
12821
12822func (s *GoogleCloudDialogflowV2WebhookResponse) MarshalJSON() ([]byte, error) {
12823	type NoMethod GoogleCloudDialogflowV2WebhookResponse
12824	raw := NoMethod(*s)
12825	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12826}
12827
12828// GoogleCloudDialogflowV2beta1AnnotatedMessagePart: Represents a part
12829// of a message possibly annotated with an entity. The part can be an
12830// entity or purely a part of the message between two entities or
12831// message start/end.
12832type GoogleCloudDialogflowV2beta1AnnotatedMessagePart struct {
12833	// EntityType: Optional. The Dialogflow system entity type
12834	// (https://cloud.google.com/dialogflow/docs/reference/system-entities)
12835	// of this message part. If this is empty, Dialogflow could not annotate
12836	// the phrase part with a system entity.
12837	EntityType string `json:"entityType,omitempty"`
12838
12839	// FormattedValue: Optional. The Dialogflow system entity formatted
12840	// value
12841	// (https://cloud.google.com/dialogflow/docs/reference/system-entities)
12842	// of this message part. For example for a system entity of type
12843	// `@sys.unit-currency`, this may contain: { "amount": 5, "currency":
12844	// "USD" }
12845	FormattedValue interface{} `json:"formattedValue,omitempty"`
12846
12847	// Text: Required. A part of a message possibly annotated with an
12848	// entity.
12849	Text string `json:"text,omitempty"`
12850
12851	// ForceSendFields is a list of field names (e.g. "EntityType") to
12852	// unconditionally include in API requests. By default, fields with
12853	// empty values are omitted from API requests. However, any non-pointer,
12854	// non-interface field appearing in ForceSendFields will be sent to the
12855	// server regardless of whether the field is empty or not. This may be
12856	// used to include empty fields in Patch requests.
12857	ForceSendFields []string `json:"-"`
12858
12859	// NullFields is a list of field names (e.g. "EntityType") to include in
12860	// API requests with the JSON null value. By default, fields with empty
12861	// values are omitted from API requests. However, any field with an
12862	// empty value appearing in NullFields will be sent to the server as
12863	// null. It is an error if a field in this list has a non-empty value.
12864	// This may be used to include null fields in Patch requests.
12865	NullFields []string `json:"-"`
12866}
12867
12868func (s *GoogleCloudDialogflowV2beta1AnnotatedMessagePart) MarshalJSON() ([]byte, error) {
12869	type NoMethod GoogleCloudDialogflowV2beta1AnnotatedMessagePart
12870	raw := NoMethod(*s)
12871	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12872}
12873
12874// GoogleCloudDialogflowV2beta1ArticleAnswer: Represents article answer.
12875type GoogleCloudDialogflowV2beta1ArticleAnswer struct {
12876	// AnswerRecord: The name of answer record, in the format of
12877	// "projects//locations//answerRecords/"
12878	AnswerRecord string `json:"answerRecord,omitempty"`
12879
12880	// Metadata: A map that contains metadata about the answer and the
12881	// document from which it originates.
12882	Metadata map[string]string `json:"metadata,omitempty"`
12883
12884	// Snippets: Output only. Article snippets.
12885	Snippets []string `json:"snippets,omitempty"`
12886
12887	// Title: The article title.
12888	Title string `json:"title,omitempty"`
12889
12890	// Uri: The article URI.
12891	Uri string `json:"uri,omitempty"`
12892
12893	// ForceSendFields is a list of field names (e.g. "AnswerRecord") to
12894	// unconditionally include in API requests. By default, fields with
12895	// empty values are omitted from API requests. However, any non-pointer,
12896	// non-interface field appearing in ForceSendFields will be sent to the
12897	// server regardless of whether the field is empty or not. This may be
12898	// used to include empty fields in Patch requests.
12899	ForceSendFields []string `json:"-"`
12900
12901	// NullFields is a list of field names (e.g. "AnswerRecord") to include
12902	// in API requests with the JSON null value. By default, fields with
12903	// empty values are omitted from API requests. However, any field with
12904	// an empty value appearing in NullFields will be sent to the server as
12905	// null. It is an error if a field in this list has a non-empty value.
12906	// This may be used to include null fields in Patch requests.
12907	NullFields []string `json:"-"`
12908}
12909
12910func (s *GoogleCloudDialogflowV2beta1ArticleAnswer) MarshalJSON() ([]byte, error) {
12911	type NoMethod GoogleCloudDialogflowV2beta1ArticleAnswer
12912	raw := NoMethod(*s)
12913	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12914}
12915
12916// GoogleCloudDialogflowV2beta1BatchUpdateEntityTypesResponse: The
12917// response message for EntityTypes.BatchUpdateEntityTypes.
12918type GoogleCloudDialogflowV2beta1BatchUpdateEntityTypesResponse struct {
12919	// EntityTypes: The collection of updated or created entity types.
12920	EntityTypes []*GoogleCloudDialogflowV2beta1EntityType `json:"entityTypes,omitempty"`
12921
12922	// ForceSendFields is a list of field names (e.g. "EntityTypes") to
12923	// unconditionally include in API requests. By default, fields with
12924	// empty values are omitted from API requests. However, any non-pointer,
12925	// non-interface field appearing in ForceSendFields will be sent to the
12926	// server regardless of whether the field is empty or not. This may be
12927	// used to include empty fields in Patch requests.
12928	ForceSendFields []string `json:"-"`
12929
12930	// NullFields is a list of field names (e.g. "EntityTypes") to include
12931	// in API requests with the JSON null value. By default, fields with
12932	// empty values are omitted from API requests. However, any field with
12933	// an empty value appearing in NullFields will be sent to the server as
12934	// null. It is an error if a field in this list has a non-empty value.
12935	// This may be used to include null fields in Patch requests.
12936	NullFields []string `json:"-"`
12937}
12938
12939func (s *GoogleCloudDialogflowV2beta1BatchUpdateEntityTypesResponse) MarshalJSON() ([]byte, error) {
12940	type NoMethod GoogleCloudDialogflowV2beta1BatchUpdateEntityTypesResponse
12941	raw := NoMethod(*s)
12942	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12943}
12944
12945// GoogleCloudDialogflowV2beta1BatchUpdateIntentsResponse: The response
12946// message for Intents.BatchUpdateIntents.
12947type GoogleCloudDialogflowV2beta1BatchUpdateIntentsResponse struct {
12948	// Intents: The collection of updated or created intents.
12949	Intents []*GoogleCloudDialogflowV2beta1Intent `json:"intents,omitempty"`
12950
12951	// ForceSendFields is a list of field names (e.g. "Intents") to
12952	// unconditionally include in API requests. By default, fields with
12953	// empty values are omitted from API requests. However, any non-pointer,
12954	// non-interface field appearing in ForceSendFields will be sent to the
12955	// server regardless of whether the field is empty or not. This may be
12956	// used to include empty fields in Patch requests.
12957	ForceSendFields []string `json:"-"`
12958
12959	// NullFields is a list of field names (e.g. "Intents") to include in
12960	// API requests with the JSON null value. By default, fields with empty
12961	// values are omitted from API requests. However, any field with an
12962	// empty value appearing in NullFields will be sent to the server as
12963	// null. It is an error if a field in this list has a non-empty value.
12964	// This may be used to include null fields in Patch requests.
12965	NullFields []string `json:"-"`
12966}
12967
12968func (s *GoogleCloudDialogflowV2beta1BatchUpdateIntentsResponse) MarshalJSON() ([]byte, error) {
12969	type NoMethod GoogleCloudDialogflowV2beta1BatchUpdateIntentsResponse
12970	raw := NoMethod(*s)
12971	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12972}
12973
12974// GoogleCloudDialogflowV2beta1Context: Dialogflow contexts are similar
12975// to natural language context. If a person says to you "they are
12976// orange", you need context in order to understand what "they" is
12977// referring to. Similarly, for Dialogflow to handle an end-user
12978// expression like that, it needs to be provided with context in order
12979// to correctly match an intent. Using contexts, you can control the
12980// flow of a conversation. You can configure contexts for an intent by
12981// setting input and output contexts, which are identified by string
12982// names. When an intent is matched, any configured output contexts for
12983// that intent become active. While any contexts are active, Dialogflow
12984// is more likely to match intents that are configured with input
12985// contexts that correspond to the currently active contexts. For more
12986// information about context, see the Contexts guide
12987// (https://cloud.google.com/dialogflow/docs/contexts-overview).
12988type GoogleCloudDialogflowV2beta1Context struct {
12989	// LifespanCount: Optional. The number of conversational query requests
12990	// after which the context expires. The default is `0`. If set to `0`,
12991	// the context expires immediately. Contexts expire automatically after
12992	// 20 minutes if there are no matching queries.
12993	LifespanCount int64 `json:"lifespanCount,omitempty"`
12994
12995	// Name: Required. The unique identifier of the context. Supported
12996	// formats: - `projects//agent/sessions//contexts/`, -
12997	// `projects//locations//agent/sessions//contexts/`, -
12998	// `projects//agent/environments//users//sessions//contexts/`, -
12999	// `projects//locations//agent/environments//users//sessions//contexts/`,
13000	//  The `Context ID` is always converted to lowercase, may only contain
13001	// characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If
13002	// `Environment ID` is not specified, we assume default 'draft'
13003	// environment. If `User ID` is not specified, we assume default '-'
13004	// user. The following context names are reserved for internal use by
13005	// Dialogflow. You should not use these contexts or create contexts with
13006	// these names: * `__system_counters__` * `*_id_dialog_context` *
13007	// `*_dialog_params_size`
13008	Name string `json:"name,omitempty"`
13009
13010	// Parameters: Optional. The collection of parameters associated with
13011	// this context. Depending on your protocol or client library language,
13012	// this is a map, associative array, symbol table, dictionary, or JSON
13013	// object composed of a collection of (MapKey, MapValue) pairs: - MapKey
13014	// type: string - MapKey value: parameter name - MapValue type: - If
13015	// parameter's entity type is a composite entity: map - Else: depending
13016	// on parameter value type, could be one of string, number, boolean,
13017	// null, list or map - MapValue value: - If parameter's entity type is a
13018	// composite entity: map from composite entity property names to
13019	// property values - Else: parameter value
13020	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
13021
13022	// ForceSendFields is a list of field names (e.g. "LifespanCount") to
13023	// unconditionally include in API requests. By default, fields with
13024	// empty values are omitted from API requests. However, any non-pointer,
13025	// non-interface field appearing in ForceSendFields will be sent to the
13026	// server regardless of whether the field is empty or not. This may be
13027	// used to include empty fields in Patch requests.
13028	ForceSendFields []string `json:"-"`
13029
13030	// NullFields is a list of field names (e.g. "LifespanCount") to include
13031	// in API requests with the JSON null value. By default, fields with
13032	// empty values are omitted from API requests. However, any field with
13033	// an empty value appearing in NullFields will be sent to the server as
13034	// null. It is an error if a field in this list has a non-empty value.
13035	// This may be used to include null fields in Patch requests.
13036	NullFields []string `json:"-"`
13037}
13038
13039func (s *GoogleCloudDialogflowV2beta1Context) MarshalJSON() ([]byte, error) {
13040	type NoMethod GoogleCloudDialogflowV2beta1Context
13041	raw := NoMethod(*s)
13042	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13043}
13044
13045// GoogleCloudDialogflowV2beta1ConversationEvent: Represents a
13046// notification sent to Pub/Sub subscribers for conversation lifecycle
13047// events.
13048type GoogleCloudDialogflowV2beta1ConversationEvent struct {
13049	// Conversation: Required. The unique identifier of the conversation
13050	// this notification refers to. Format: `projects//conversations/`.
13051	Conversation string `json:"conversation,omitempty"`
13052
13053	// ErrorStatus: Optional. More detailed information about an error. Only
13054	// set for type UNRECOVERABLE_ERROR_IN_PHONE_CALL.
13055	ErrorStatus *GoogleRpcStatus `json:"errorStatus,omitempty"`
13056
13057	// NewMessagePayload: Payload of NEW_MESSAGE event.
13058	NewMessagePayload *GoogleCloudDialogflowV2beta1Message `json:"newMessagePayload,omitempty"`
13059
13060	// Type: Required. The type of the event that this notification refers
13061	// to.
13062	//
13063	// Possible values:
13064	//   "TYPE_UNSPECIFIED" - Type not set.
13065	//   "CONVERSATION_STARTED" - A new conversation has been opened. This
13066	// is fired when a telephone call is answered, or a conversation is
13067	// created via the API.
13068	//   "CONVERSATION_FINISHED" - An existing conversation has closed. This
13069	// is fired when a telephone call is terminated, or a conversation is
13070	// closed via the API.
13071	//   "NEW_MESSAGE" - An existing conversation has received a new
13072	// message, either from API or telephony. It is configured in
13073	// ConversationProfile.new_message_event_notification_config
13074	//   "UNRECOVERABLE_ERROR" - Unrecoverable error during a telephone
13075	// call. In general non-recoverable errors only occur if something was
13076	// misconfigured in the ConversationProfile corresponding to the call.
13077	// After a non-recoverable error, Dialogflow may stop responding. We
13078	// don't fire this event: * in an API call because we can directly
13079	// return the error, or, * when we can recover from an error.
13080	Type string `json:"type,omitempty"`
13081
13082	// ForceSendFields is a list of field names (e.g. "Conversation") to
13083	// unconditionally include in API requests. By default, fields with
13084	// empty values are omitted from API requests. However, any non-pointer,
13085	// non-interface field appearing in ForceSendFields will be sent to the
13086	// server regardless of whether the field is empty or not. This may be
13087	// used to include empty fields in Patch requests.
13088	ForceSendFields []string `json:"-"`
13089
13090	// NullFields is a list of field names (e.g. "Conversation") to include
13091	// in API requests with the JSON null value. By default, fields with
13092	// empty values are omitted from API requests. However, any field with
13093	// an empty value appearing in NullFields will be sent to the server as
13094	// null. It is an error if a field in this list has a non-empty value.
13095	// This may be used to include null fields in Patch requests.
13096	NullFields []string `json:"-"`
13097}
13098
13099func (s *GoogleCloudDialogflowV2beta1ConversationEvent) MarshalJSON() ([]byte, error) {
13100	type NoMethod GoogleCloudDialogflowV2beta1ConversationEvent
13101	raw := NoMethod(*s)
13102	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13103}
13104
13105// GoogleCloudDialogflowV2beta1EntityType: Each intent parameter has a
13106// type, called the entity type, which dictates exactly how data from an
13107// end-user expression is extracted. Dialogflow provides predefined
13108// system entities that can match many common types of data. For
13109// example, there are system entities for matching dates, times, colors,
13110// email addresses, and so on. You can also create your own custom
13111// entities for matching custom data. For example, you could define a
13112// vegetable entity that can match the types of vegetables available for
13113// purchase with a grocery store agent. For more information, see the
13114// Entity guide
13115// (https://cloud.google.com/dialogflow/docs/entities-overview).
13116type GoogleCloudDialogflowV2beta1EntityType struct {
13117	// AutoExpansionMode: Optional. Indicates whether the entity type can be
13118	// automatically expanded.
13119	//
13120	// Possible values:
13121	//   "AUTO_EXPANSION_MODE_UNSPECIFIED" - Auto expansion disabled for the
13122	// entity.
13123	//   "AUTO_EXPANSION_MODE_DEFAULT" - Allows an agent to recognize values
13124	// that have not been explicitly listed in the entity.
13125	AutoExpansionMode string `json:"autoExpansionMode,omitempty"`
13126
13127	// DisplayName: Required. The name of the entity type.
13128	DisplayName string `json:"displayName,omitempty"`
13129
13130	// EnableFuzzyExtraction: Optional. Enables fuzzy entity extraction
13131	// during classification.
13132	EnableFuzzyExtraction bool `json:"enableFuzzyExtraction,omitempty"`
13133
13134	// Entities: Optional. The collection of entity entries associated with
13135	// the entity type.
13136	Entities []*GoogleCloudDialogflowV2beta1EntityTypeEntity `json:"entities,omitempty"`
13137
13138	// Kind: Required. Indicates the kind of entity type.
13139	//
13140	// Possible values:
13141	//   "KIND_UNSPECIFIED" - Not specified. This value should be never
13142	// used.
13143	//   "KIND_MAP" - Map entity types allow mapping of a group of synonyms
13144	// to a reference value.
13145	//   "KIND_LIST" - List entity types contain a set of entries that do
13146	// not map to reference values. However, list entity types can contain
13147	// references to other entity types (with or without aliases).
13148	//   "KIND_REGEXP" - Regexp entity types allow to specify regular
13149	// expressions in entries values.
13150	Kind string `json:"kind,omitempty"`
13151
13152	// Name: The unique identifier of the entity type. Required for
13153	// EntityTypes.UpdateEntityType and EntityTypes.BatchUpdateEntityTypes
13154	// methods. Supported formats: - `projects//agent/entityTypes/` -
13155	// `projects//locations//agent/entityTypes/`
13156	Name string `json:"name,omitempty"`
13157
13158	// ForceSendFields is a list of field names (e.g. "AutoExpansionMode")
13159	// to unconditionally include in API requests. By default, fields with
13160	// empty values are omitted from API requests. However, any non-pointer,
13161	// non-interface field appearing in ForceSendFields will be sent to the
13162	// server regardless of whether the field is empty or not. This may be
13163	// used to include empty fields in Patch requests.
13164	ForceSendFields []string `json:"-"`
13165
13166	// NullFields is a list of field names (e.g. "AutoExpansionMode") to
13167	// include in API requests with the JSON null value. By default, fields
13168	// with empty values are omitted from API requests. However, any field
13169	// with an empty value appearing in NullFields will be sent to the
13170	// server as null. It is an error if a field in this list has a
13171	// non-empty value. This may be used to include null fields in Patch
13172	// requests.
13173	NullFields []string `json:"-"`
13174}
13175
13176func (s *GoogleCloudDialogflowV2beta1EntityType) MarshalJSON() ([]byte, error) {
13177	type NoMethod GoogleCloudDialogflowV2beta1EntityType
13178	raw := NoMethod(*s)
13179	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13180}
13181
13182// GoogleCloudDialogflowV2beta1EntityTypeEntity: An **entity entry** for
13183// an associated entity type.
13184type GoogleCloudDialogflowV2beta1EntityTypeEntity struct {
13185	// Synonyms: Required. A collection of value synonyms. For example, if
13186	// the entity type is *vegetable*, and `value` is *scallions*, a synonym
13187	// could be *green onions*. For `KIND_LIST` entity types: * This
13188	// collection must contain exactly one synonym equal to `value`.
13189	Synonyms []string `json:"synonyms,omitempty"`
13190
13191	// Value: Required. The primary value associated with this entity entry.
13192	// For example, if the entity type is *vegetable*, the value could be
13193	// *scallions*. For `KIND_MAP` entity types: * A reference value to be
13194	// used in place of synonyms. For `KIND_LIST` entity types: * A string
13195	// that can contain references to other entity types (with or without
13196	// aliases).
13197	Value string `json:"value,omitempty"`
13198
13199	// ForceSendFields is a list of field names (e.g. "Synonyms") to
13200	// unconditionally include in API requests. By default, fields with
13201	// empty values are omitted from API requests. However, any non-pointer,
13202	// non-interface field appearing in ForceSendFields will be sent to the
13203	// server regardless of whether the field is empty or not. This may be
13204	// used to include empty fields in Patch requests.
13205	ForceSendFields []string `json:"-"`
13206
13207	// NullFields is a list of field names (e.g. "Synonyms") to include in
13208	// API requests with the JSON null value. By default, fields with empty
13209	// values are omitted from API requests. However, any field with an
13210	// empty value appearing in NullFields will be sent to the server as
13211	// null. It is an error if a field in this list has a non-empty value.
13212	// This may be used to include null fields in Patch requests.
13213	NullFields []string `json:"-"`
13214}
13215
13216func (s *GoogleCloudDialogflowV2beta1EntityTypeEntity) MarshalJSON() ([]byte, error) {
13217	type NoMethod GoogleCloudDialogflowV2beta1EntityTypeEntity
13218	raw := NoMethod(*s)
13219	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13220}
13221
13222// GoogleCloudDialogflowV2beta1EventInput: Events allow for matching
13223// intents by event name instead of the natural language input. For
13224// instance, input `` can trigger a personalized welcome response. The
13225// parameter `name` may be used by the agent in the response: "Hello
13226// #welcome_event.name! What can I do for you today?".
13227type GoogleCloudDialogflowV2beta1EventInput struct {
13228	// LanguageCode: Required. The language of this query. See Language
13229	// Support (https://cloud.google.com/dialogflow/docs/reference/language)
13230	// for a list of the currently supported language codes. Note that
13231	// queries in the same session do not necessarily need to specify the
13232	// same language.
13233	LanguageCode string `json:"languageCode,omitempty"`
13234
13235	// Name: Required. The unique identifier of the event.
13236	Name string `json:"name,omitempty"`
13237
13238	// Parameters: The collection of parameters associated with the event.
13239	// Depending on your protocol or client library language, this is a map,
13240	// associative array, symbol table, dictionary, or JSON object composed
13241	// of a collection of (MapKey, MapValue) pairs: - MapKey type: string -
13242	// MapKey value: parameter name - MapValue type: - If parameter's entity
13243	// type is a composite entity: map - Else: depending on parameter value
13244	// type, could be one of string, number, boolean, null, list or map -
13245	// MapValue value: - If parameter's entity type is a composite entity:
13246	// map from composite entity property names to property values - Else:
13247	// parameter value
13248	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
13249
13250	// ForceSendFields is a list of field names (e.g. "LanguageCode") to
13251	// unconditionally include in API requests. By default, fields with
13252	// empty values are omitted from API requests. However, any non-pointer,
13253	// non-interface field appearing in ForceSendFields will be sent to the
13254	// server regardless of whether the field is empty or not. This may be
13255	// used to include empty fields in Patch requests.
13256	ForceSendFields []string `json:"-"`
13257
13258	// NullFields is a list of field names (e.g. "LanguageCode") to include
13259	// in API requests with the JSON null value. By default, fields with
13260	// empty values are omitted from API requests. However, any field with
13261	// an empty value appearing in NullFields will be sent to the server as
13262	// null. It is an error if a field in this list has a non-empty value.
13263	// This may be used to include null fields in Patch requests.
13264	NullFields []string `json:"-"`
13265}
13266
13267func (s *GoogleCloudDialogflowV2beta1EventInput) MarshalJSON() ([]byte, error) {
13268	type NoMethod GoogleCloudDialogflowV2beta1EventInput
13269	raw := NoMethod(*s)
13270	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13271}
13272
13273// GoogleCloudDialogflowV2beta1ExportAgentResponse: The response message
13274// for Agents.ExportAgent.
13275type GoogleCloudDialogflowV2beta1ExportAgentResponse struct {
13276	// AgentContent: Zip compressed raw byte content for agent.
13277	AgentContent string `json:"agentContent,omitempty"`
13278
13279	// AgentUri: The URI to a file containing the exported agent. This field
13280	// is populated only if `agent_uri` is specified in
13281	// `ExportAgentRequest`.
13282	AgentUri string `json:"agentUri,omitempty"`
13283
13284	// ForceSendFields is a list of field names (e.g. "AgentContent") to
13285	// unconditionally include in API requests. By default, fields with
13286	// empty values are omitted from API requests. However, any non-pointer,
13287	// non-interface field appearing in ForceSendFields will be sent to the
13288	// server regardless of whether the field is empty or not. This may be
13289	// used to include empty fields in Patch requests.
13290	ForceSendFields []string `json:"-"`
13291
13292	// NullFields is a list of field names (e.g. "AgentContent") to include
13293	// in API requests with the JSON null value. By default, fields with
13294	// empty values are omitted from API requests. However, any field with
13295	// an empty value appearing in NullFields will be sent to the server as
13296	// null. It is an error if a field in this list has a non-empty value.
13297	// This may be used to include null fields in Patch requests.
13298	NullFields []string `json:"-"`
13299}
13300
13301func (s *GoogleCloudDialogflowV2beta1ExportAgentResponse) MarshalJSON() ([]byte, error) {
13302	type NoMethod GoogleCloudDialogflowV2beta1ExportAgentResponse
13303	raw := NoMethod(*s)
13304	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13305}
13306
13307// GoogleCloudDialogflowV2beta1FaqAnswer: Represents answer from
13308// "frequently asked questions".
13309type GoogleCloudDialogflowV2beta1FaqAnswer struct {
13310	// Answer: The piece of text from the `source` knowledge base document.
13311	Answer string `json:"answer,omitempty"`
13312
13313	// AnswerRecord: The name of answer record, in the format of
13314	// "projects//locations//answerRecords/"
13315	AnswerRecord string `json:"answerRecord,omitempty"`
13316
13317	// Confidence: The system's confidence score that this Knowledge answer
13318	// is a good match for this conversational query, range from 0.0
13319	// (completely uncertain) to 1.0 (completely certain).
13320	Confidence float64 `json:"confidence,omitempty"`
13321
13322	// Metadata: A map that contains metadata about the answer and the
13323	// document from which it originates.
13324	Metadata map[string]string `json:"metadata,omitempty"`
13325
13326	// Question: The corresponding FAQ question.
13327	Question string `json:"question,omitempty"`
13328
13329	// Source: Indicates which Knowledge Document this answer was extracted
13330	// from. Format:
13331	// `projects//locations//agent/knowledgeBases//documents/`.
13332	Source string `json:"source,omitempty"`
13333
13334	// ForceSendFields is a list of field names (e.g. "Answer") to
13335	// unconditionally include in API requests. By default, fields with
13336	// empty values are omitted from API requests. However, any non-pointer,
13337	// non-interface field appearing in ForceSendFields will be sent to the
13338	// server regardless of whether the field is empty or not. This may be
13339	// used to include empty fields in Patch requests.
13340	ForceSendFields []string `json:"-"`
13341
13342	// NullFields is a list of field names (e.g. "Answer") to include in API
13343	// requests with the JSON null value. By default, fields with empty
13344	// values are omitted from API requests. However, any field with an
13345	// empty value appearing in NullFields will be sent to the server as
13346	// null. It is an error if a field in this list has a non-empty value.
13347	// This may be used to include null fields in Patch requests.
13348	NullFields []string `json:"-"`
13349}
13350
13351func (s *GoogleCloudDialogflowV2beta1FaqAnswer) MarshalJSON() ([]byte, error) {
13352	type NoMethod GoogleCloudDialogflowV2beta1FaqAnswer
13353	raw := NoMethod(*s)
13354	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13355}
13356
13357func (s *GoogleCloudDialogflowV2beta1FaqAnswer) UnmarshalJSON(data []byte) error {
13358	type NoMethod GoogleCloudDialogflowV2beta1FaqAnswer
13359	var s1 struct {
13360		Confidence gensupport.JSONFloat64 `json:"confidence"`
13361		*NoMethod
13362	}
13363	s1.NoMethod = (*NoMethod)(s)
13364	if err := json.Unmarshal(data, &s1); err != nil {
13365		return err
13366	}
13367	s.Confidence = float64(s1.Confidence)
13368	return nil
13369}
13370
13371// GoogleCloudDialogflowV2beta1HumanAgentAssistantEvent: Output only.
13372// Represents a notification sent to Pub/Sub subscribers for agent
13373// assistant events in a specific conversation.
13374type GoogleCloudDialogflowV2beta1HumanAgentAssistantEvent struct {
13375	// Conversation: The conversation this notification refers to. Format:
13376	// `projects//conversations/`.
13377	Conversation string `json:"conversation,omitempty"`
13378
13379	// Participant: The participant that the suggestion is compiled for. And
13380	// This field is used to call Participants.ListSuggestions API. Format:
13381	// `projects//conversations//participants/`. It will not be set in
13382	// legacy workflow. HumanAgentAssistantConfig.name for more information.
13383	Participant string `json:"participant,omitempty"`
13384
13385	// SuggestionResults: The suggestion results payload that this
13386	// notification refers to. It will only be set when
13387	// HumanAgentAssistantConfig.SuggestionConfig.group_suggestion_responses
13388	// sets to true.
13389	SuggestionResults []*GoogleCloudDialogflowV2beta1SuggestionResult `json:"suggestionResults,omitempty"`
13390
13391	// ForceSendFields is a list of field names (e.g. "Conversation") to
13392	// unconditionally include in API requests. By default, fields with
13393	// empty values are omitted from API requests. However, any non-pointer,
13394	// non-interface field appearing in ForceSendFields will be sent to the
13395	// server regardless of whether the field is empty or not. This may be
13396	// used to include empty fields in Patch requests.
13397	ForceSendFields []string `json:"-"`
13398
13399	// NullFields is a list of field names (e.g. "Conversation") to include
13400	// in API requests with the JSON null value. By default, fields with
13401	// empty values are omitted from API requests. However, any field with
13402	// an empty value appearing in NullFields will be sent to the server as
13403	// null. It is an error if a field in this list has a non-empty value.
13404	// This may be used to include null fields in Patch requests.
13405	NullFields []string `json:"-"`
13406}
13407
13408func (s *GoogleCloudDialogflowV2beta1HumanAgentAssistantEvent) MarshalJSON() ([]byte, error) {
13409	type NoMethod GoogleCloudDialogflowV2beta1HumanAgentAssistantEvent
13410	raw := NoMethod(*s)
13411	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13412}
13413
13414// GoogleCloudDialogflowV2beta1ImportDocumentsResponse: Response message
13415// for Documents.ImportDocuments.
13416type GoogleCloudDialogflowV2beta1ImportDocumentsResponse struct {
13417	// Warnings: Includes details about skipped documents or any other
13418	// warnings.
13419	Warnings []*GoogleRpcStatus `json:"warnings,omitempty"`
13420
13421	// ForceSendFields is a list of field names (e.g. "Warnings") to
13422	// unconditionally include in API requests. By default, fields with
13423	// empty values are omitted from API requests. However, any non-pointer,
13424	// non-interface field appearing in ForceSendFields will be sent to the
13425	// server regardless of whether the field is empty or not. This may be
13426	// used to include empty fields in Patch requests.
13427	ForceSendFields []string `json:"-"`
13428
13429	// NullFields is a list of field names (e.g. "Warnings") to include in
13430	// API requests with the JSON null value. By default, fields with empty
13431	// values are omitted from API requests. However, any field with an
13432	// empty value appearing in NullFields will be sent to the server as
13433	// null. It is an error if a field in this list has a non-empty value.
13434	// This may be used to include null fields in Patch requests.
13435	NullFields []string `json:"-"`
13436}
13437
13438func (s *GoogleCloudDialogflowV2beta1ImportDocumentsResponse) MarshalJSON() ([]byte, error) {
13439	type NoMethod GoogleCloudDialogflowV2beta1ImportDocumentsResponse
13440	raw := NoMethod(*s)
13441	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13442}
13443
13444// GoogleCloudDialogflowV2beta1Intent: An intent categorizes an
13445// end-user's intention for one conversation turn. For each agent, you
13446// define many intents, where your combined intents can handle a
13447// complete conversation. When an end-user writes or says something,
13448// referred to as an end-user expression or end-user input, Dialogflow
13449// matches the end-user input to the best intent in your agent. Matching
13450// an intent is also known as intent classification. For more
13451// information, see the intent guide
13452// (https://cloud.google.com/dialogflow/docs/intents-overview).
13453type GoogleCloudDialogflowV2beta1Intent struct {
13454	// Action: Optional. The name of the action associated with the intent.
13455	// Note: The action name must not contain whitespaces.
13456	Action string `json:"action,omitempty"`
13457
13458	// DefaultResponsePlatforms: Optional. The list of platforms for which
13459	// the first responses will be copied from the messages in
13460	// PLATFORM_UNSPECIFIED (i.e. default platform).
13461	//
13462	// Possible values:
13463	//   "PLATFORM_UNSPECIFIED" - Not specified.
13464	//   "FACEBOOK" - Facebook.
13465	//   "SLACK" - Slack.
13466	//   "TELEGRAM" - Telegram.
13467	//   "KIK" - Kik.
13468	//   "SKYPE" - Skype.
13469	//   "LINE" - Line.
13470	//   "VIBER" - Viber.
13471	//   "ACTIONS_ON_GOOGLE" - Google Assistant See [Dialogflow webhook
13472	// format](https://developers.google.com/assistant/actions/build/json/dia
13473	// logflow-webhook-json)
13474	//   "TELEPHONY" - Telephony Gateway.
13475	//   "GOOGLE_HANGOUTS" - Google Hangouts.
13476	DefaultResponsePlatforms []string `json:"defaultResponsePlatforms,omitempty"`
13477
13478	// DisplayName: Required. The name of this intent.
13479	DisplayName string `json:"displayName,omitempty"`
13480
13481	// EndInteraction: Optional. Indicates that this intent ends an
13482	// interaction. Some integrations (e.g., Actions on Google or Dialogflow
13483	// phone gateway) use this information to close interaction with an end
13484	// user. Default is false.
13485	EndInteraction bool `json:"endInteraction,omitempty"`
13486
13487	// Events: Optional. The collection of event names that trigger the
13488	// intent. If the collection of input contexts is not empty, all of the
13489	// contexts must be present in the active user session for an event to
13490	// trigger this intent. Event names are limited to 150 characters.
13491	Events []string `json:"events,omitempty"`
13492
13493	// FollowupIntentInfo: Output only. Information about all followup
13494	// intents that have this intent as a direct or indirect parent. We
13495	// populate this field only in the output.
13496	FollowupIntentInfo []*GoogleCloudDialogflowV2beta1IntentFollowupIntentInfo `json:"followupIntentInfo,omitempty"`
13497
13498	// InputContextNames: Optional. The list of context names required for
13499	// this intent to be triggered. Formats: -
13500	// `projects//agent/sessions/-/contexts/` -
13501	// `projects//locations//agent/sessions/-/contexts/`
13502	InputContextNames []string `json:"inputContextNames,omitempty"`
13503
13504	// IsFallback: Optional. Indicates whether this is a fallback intent.
13505	IsFallback bool `json:"isFallback,omitempty"`
13506
13507	// LiveAgentHandoff: Optional. Indicates that a live agent should be
13508	// brought in to handle the interaction with the user. In most cases,
13509	// when you set this flag to true, you would also want to set
13510	// end_interaction to true as well. Default is false.
13511	LiveAgentHandoff bool `json:"liveAgentHandoff,omitempty"`
13512
13513	// Messages: Optional. The collection of rich messages corresponding to
13514	// the `Response` field in the Dialogflow console.
13515	Messages []*GoogleCloudDialogflowV2beta1IntentMessage `json:"messages,omitempty"`
13516
13517	// MlDisabled: Optional. Indicates whether Machine Learning is disabled
13518	// for the intent. Note: If `ml_disabled` setting is set to true, then
13519	// this intent is not taken into account during inference in `ML ONLY`
13520	// match mode. Also, auto-markup in the UI is turned off.
13521	MlDisabled bool `json:"mlDisabled,omitempty"`
13522
13523	// MlEnabled: Optional. Indicates whether Machine Learning is enabled
13524	// for the intent. Note: If `ml_enabled` setting is set to false, then
13525	// this intent is not taken into account during inference in `ML ONLY`
13526	// match mode. Also, auto-markup in the UI is turned off. DEPRECATED!
13527	// Please use `ml_disabled` field instead. NOTE: If both `ml_enabled`
13528	// and `ml_disabled` are either not set or false, then the default value
13529	// is determined as follows: - Before April 15th, 2018 the default is:
13530	// ml_enabled = false / ml_disabled = true. - After April 15th, 2018 the
13531	// default is: ml_enabled = true / ml_disabled = false.
13532	MlEnabled bool `json:"mlEnabled,omitempty"`
13533
13534	// Name: Optional. The unique identifier of this intent. Required for
13535	// Intents.UpdateIntent and Intents.BatchUpdateIntents methods.
13536	// Supported formats: - `projects//agent/intents/` -
13537	// `projects//locations//agent/intents/`
13538	Name string `json:"name,omitempty"`
13539
13540	// OutputContexts: Optional. The collection of contexts that are
13541	// activated when the intent is matched. Context messages in this
13542	// collection should not set the parameters field. Setting the
13543	// `lifespan_count` to 0 will reset the context when the intent is
13544	// matched. Format: `projects//agent/sessions/-/contexts/`.
13545	OutputContexts []*GoogleCloudDialogflowV2beta1Context `json:"outputContexts,omitempty"`
13546
13547	// Parameters: Optional. The collection of parameters associated with
13548	// the intent.
13549	Parameters []*GoogleCloudDialogflowV2beta1IntentParameter `json:"parameters,omitempty"`
13550
13551	// ParentFollowupIntentName: Optional. The unique identifier of the
13552	// parent intent in the chain of followup intents. You can set this
13553	// field when creating an intent, for example with CreateIntent or
13554	// BatchUpdateIntents, in order to make this intent a followup intent.
13555	// It identifies the parent followup intent. Format:
13556	// `projects//agent/intents/`.
13557	ParentFollowupIntentName string `json:"parentFollowupIntentName,omitempty"`
13558
13559	// Priority: Optional. The priority of this intent. Higher numbers
13560	// represent higher priorities. - If the supplied value is unspecified
13561	// or 0, the service translates the value to 500,000, which corresponds
13562	// to the `Normal` priority in the console. - If the supplied value is
13563	// negative, the intent is ignored in runtime detect intent requests.
13564	Priority int64 `json:"priority,omitempty"`
13565
13566	// ResetContexts: Optional. Indicates whether to delete all contexts in
13567	// the current session when this intent is matched.
13568	ResetContexts bool `json:"resetContexts,omitempty"`
13569
13570	// RootFollowupIntentName: Output only. The unique identifier of the
13571	// root intent in the chain of followup intents. It identifies the
13572	// correct followup intents chain for this intent. Format:
13573	// `projects//agent/intents/`.
13574	RootFollowupIntentName string `json:"rootFollowupIntentName,omitempty"`
13575
13576	// TrainingPhrases: Optional. The collection of examples that the agent
13577	// is trained on.
13578	TrainingPhrases []*GoogleCloudDialogflowV2beta1IntentTrainingPhrase `json:"trainingPhrases,omitempty"`
13579
13580	// WebhookState: Optional. Indicates whether webhooks are enabled for
13581	// the intent.
13582	//
13583	// Possible values:
13584	//   "WEBHOOK_STATE_UNSPECIFIED" - Webhook is disabled in the agent and
13585	// in the intent.
13586	//   "WEBHOOK_STATE_ENABLED" - Webhook is enabled in the agent and in
13587	// the intent.
13588	//   "WEBHOOK_STATE_ENABLED_FOR_SLOT_FILLING" - Webhook is enabled in
13589	// the agent and in the intent. Also, each slot filling prompt is
13590	// forwarded to the webhook.
13591	WebhookState string `json:"webhookState,omitempty"`
13592
13593	// ForceSendFields is a list of field names (e.g. "Action") to
13594	// unconditionally include in API requests. By default, fields with
13595	// empty values are omitted from API requests. However, any non-pointer,
13596	// non-interface field appearing in ForceSendFields will be sent to the
13597	// server regardless of whether the field is empty or not. This may be
13598	// used to include empty fields in Patch requests.
13599	ForceSendFields []string `json:"-"`
13600
13601	// NullFields is a list of field names (e.g. "Action") to include in API
13602	// requests with the JSON null value. By default, fields with empty
13603	// values are omitted from API requests. However, any field with an
13604	// empty value appearing in NullFields will be sent to the server as
13605	// null. It is an error if a field in this list has a non-empty value.
13606	// This may be used to include null fields in Patch requests.
13607	NullFields []string `json:"-"`
13608}
13609
13610func (s *GoogleCloudDialogflowV2beta1Intent) MarshalJSON() ([]byte, error) {
13611	type NoMethod GoogleCloudDialogflowV2beta1Intent
13612	raw := NoMethod(*s)
13613	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13614}
13615
13616// GoogleCloudDialogflowV2beta1IntentFollowupIntentInfo: Represents a
13617// single followup intent in the chain.
13618type GoogleCloudDialogflowV2beta1IntentFollowupIntentInfo struct {
13619	// FollowupIntentName: The unique identifier of the followup intent.
13620	// Format: `projects//agent/intents/`.
13621	FollowupIntentName string `json:"followupIntentName,omitempty"`
13622
13623	// ParentFollowupIntentName: The unique identifier of the followup
13624	// intent's parent. Format: `projects//agent/intents/`.
13625	ParentFollowupIntentName string `json:"parentFollowupIntentName,omitempty"`
13626
13627	// ForceSendFields is a list of field names (e.g. "FollowupIntentName")
13628	// to unconditionally include in API requests. By default, fields with
13629	// empty values are omitted from API requests. However, any non-pointer,
13630	// non-interface field appearing in ForceSendFields will be sent to the
13631	// server regardless of whether the field is empty or not. This may be
13632	// used to include empty fields in Patch requests.
13633	ForceSendFields []string `json:"-"`
13634
13635	// NullFields is a list of field names (e.g. "FollowupIntentName") to
13636	// include in API requests with the JSON null value. By default, fields
13637	// with empty values are omitted from API requests. However, any field
13638	// with an empty value appearing in NullFields will be sent to the
13639	// server as null. It is an error if a field in this list has a
13640	// non-empty value. This may be used to include null fields in Patch
13641	// requests.
13642	NullFields []string `json:"-"`
13643}
13644
13645func (s *GoogleCloudDialogflowV2beta1IntentFollowupIntentInfo) MarshalJSON() ([]byte, error) {
13646	type NoMethod GoogleCloudDialogflowV2beta1IntentFollowupIntentInfo
13647	raw := NoMethod(*s)
13648	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13649}
13650
13651// GoogleCloudDialogflowV2beta1IntentMessage: Corresponds to the
13652// `Response` field in the Dialogflow console.
13653type GoogleCloudDialogflowV2beta1IntentMessage struct {
13654	// BasicCard: Displays a basic card for Actions on Google.
13655	BasicCard *GoogleCloudDialogflowV2beta1IntentMessageBasicCard `json:"basicCard,omitempty"`
13656
13657	// BrowseCarouselCard: Browse carousel card for Actions on Google.
13658	BrowseCarouselCard *GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCard `json:"browseCarouselCard,omitempty"`
13659
13660	// Card: Displays a card.
13661	Card *GoogleCloudDialogflowV2beta1IntentMessageCard `json:"card,omitempty"`
13662
13663	// CarouselSelect: Displays a carousel card for Actions on Google.
13664	CarouselSelect *GoogleCloudDialogflowV2beta1IntentMessageCarouselSelect `json:"carouselSelect,omitempty"`
13665
13666	// Image: Displays an image.
13667	Image *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"image,omitempty"`
13668
13669	// LinkOutSuggestion: Displays a link out suggestion chip for Actions on
13670	// Google.
13671	LinkOutSuggestion *GoogleCloudDialogflowV2beta1IntentMessageLinkOutSuggestion `json:"linkOutSuggestion,omitempty"`
13672
13673	// ListSelect: Displays a list card for Actions on Google.
13674	ListSelect *GoogleCloudDialogflowV2beta1IntentMessageListSelect `json:"listSelect,omitempty"`
13675
13676	// MediaContent: The media content card for Actions on Google.
13677	MediaContent *GoogleCloudDialogflowV2beta1IntentMessageMediaContent `json:"mediaContent,omitempty"`
13678
13679	// Payload: A custom platform-specific response.
13680	Payload googleapi.RawMessage `json:"payload,omitempty"`
13681
13682	// Platform: Optional. The platform that this message is intended for.
13683	//
13684	// Possible values:
13685	//   "PLATFORM_UNSPECIFIED" - Not specified.
13686	//   "FACEBOOK" - Facebook.
13687	//   "SLACK" - Slack.
13688	//   "TELEGRAM" - Telegram.
13689	//   "KIK" - Kik.
13690	//   "SKYPE" - Skype.
13691	//   "LINE" - Line.
13692	//   "VIBER" - Viber.
13693	//   "ACTIONS_ON_GOOGLE" - Google Assistant See [Dialogflow webhook
13694	// format](https://developers.google.com/assistant/actions/build/json/dia
13695	// logflow-webhook-json)
13696	//   "TELEPHONY" - Telephony Gateway.
13697	//   "GOOGLE_HANGOUTS" - Google Hangouts.
13698	Platform string `json:"platform,omitempty"`
13699
13700	// QuickReplies: Displays quick replies.
13701	QuickReplies *GoogleCloudDialogflowV2beta1IntentMessageQuickReplies `json:"quickReplies,omitempty"`
13702
13703	// RbmCarouselRichCard: Rich Business Messaging (RBM) carousel rich card
13704	// response.
13705	RbmCarouselRichCard *GoogleCloudDialogflowV2beta1IntentMessageRbmCarouselCard `json:"rbmCarouselRichCard,omitempty"`
13706
13707	// RbmStandaloneRichCard: Standalone Rich Business Messaging (RBM) rich
13708	// card response.
13709	RbmStandaloneRichCard *GoogleCloudDialogflowV2beta1IntentMessageRbmStandaloneCard `json:"rbmStandaloneRichCard,omitempty"`
13710
13711	// RbmText: Rich Business Messaging (RBM) text response. RBM allows
13712	// businesses to send enriched and branded versions of SMS. See
13713	// https://jibe.google.com/business-messaging.
13714	RbmText *GoogleCloudDialogflowV2beta1IntentMessageRbmText `json:"rbmText,omitempty"`
13715
13716	// SimpleResponses: Returns a voice or text-only response for Actions on
13717	// Google.
13718	SimpleResponses *GoogleCloudDialogflowV2beta1IntentMessageSimpleResponses `json:"simpleResponses,omitempty"`
13719
13720	// Suggestions: Displays suggestion chips for Actions on Google.
13721	Suggestions *GoogleCloudDialogflowV2beta1IntentMessageSuggestions `json:"suggestions,omitempty"`
13722
13723	// TableCard: Table card for Actions on Google.
13724	TableCard *GoogleCloudDialogflowV2beta1IntentMessageTableCard `json:"tableCard,omitempty"`
13725
13726	// TelephonyPlayAudio: Plays audio from a file in Telephony Gateway.
13727	TelephonyPlayAudio *GoogleCloudDialogflowV2beta1IntentMessageTelephonyPlayAudio `json:"telephonyPlayAudio,omitempty"`
13728
13729	// TelephonySynthesizeSpeech: Synthesizes speech in Telephony Gateway.
13730	TelephonySynthesizeSpeech *GoogleCloudDialogflowV2beta1IntentMessageTelephonySynthesizeSpeech `json:"telephonySynthesizeSpeech,omitempty"`
13731
13732	// TelephonyTransferCall: Transfers the call in Telephony Gateway.
13733	TelephonyTransferCall *GoogleCloudDialogflowV2beta1IntentMessageTelephonyTransferCall `json:"telephonyTransferCall,omitempty"`
13734
13735	// Text: Returns a text response.
13736	Text *GoogleCloudDialogflowV2beta1IntentMessageText `json:"text,omitempty"`
13737
13738	// ForceSendFields is a list of field names (e.g. "BasicCard") to
13739	// unconditionally include in API requests. By default, fields with
13740	// empty values are omitted from API requests. However, any non-pointer,
13741	// non-interface field appearing in ForceSendFields will be sent to the
13742	// server regardless of whether the field is empty or not. This may be
13743	// used to include empty fields in Patch requests.
13744	ForceSendFields []string `json:"-"`
13745
13746	// NullFields is a list of field names (e.g. "BasicCard") to include in
13747	// API requests with the JSON null value. By default, fields with empty
13748	// values are omitted from API requests. However, any field with an
13749	// empty value appearing in NullFields will be sent to the server as
13750	// null. It is an error if a field in this list has a non-empty value.
13751	// This may be used to include null fields in Patch requests.
13752	NullFields []string `json:"-"`
13753}
13754
13755func (s *GoogleCloudDialogflowV2beta1IntentMessage) MarshalJSON() ([]byte, error) {
13756	type NoMethod GoogleCloudDialogflowV2beta1IntentMessage
13757	raw := NoMethod(*s)
13758	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13759}
13760
13761// GoogleCloudDialogflowV2beta1IntentMessageBasicCard: The basic card
13762// message. Useful for displaying information.
13763type GoogleCloudDialogflowV2beta1IntentMessageBasicCard struct {
13764	// Buttons: Optional. The collection of card buttons.
13765	Buttons []*GoogleCloudDialogflowV2beta1IntentMessageBasicCardButton `json:"buttons,omitempty"`
13766
13767	// FormattedText: Required, unless image is present. The body text of
13768	// the card.
13769	FormattedText string `json:"formattedText,omitempty"`
13770
13771	// Image: Optional. The image for the card.
13772	Image *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"image,omitempty"`
13773
13774	// Subtitle: Optional. The subtitle of the card.
13775	Subtitle string `json:"subtitle,omitempty"`
13776
13777	// Title: Optional. The title of the card.
13778	Title string `json:"title,omitempty"`
13779
13780	// ForceSendFields is a list of field names (e.g. "Buttons") to
13781	// unconditionally include in API requests. By default, fields with
13782	// empty values are omitted from API requests. However, any non-pointer,
13783	// non-interface field appearing in ForceSendFields will be sent to the
13784	// server regardless of whether the field is empty or not. This may be
13785	// used to include empty fields in Patch requests.
13786	ForceSendFields []string `json:"-"`
13787
13788	// NullFields is a list of field names (e.g. "Buttons") to include in
13789	// API requests with the JSON null value. By default, fields with empty
13790	// values are omitted from API requests. However, any field with an
13791	// empty value appearing in NullFields will be sent to the server as
13792	// null. It is an error if a field in this list has a non-empty value.
13793	// This may be used to include null fields in Patch requests.
13794	NullFields []string `json:"-"`
13795}
13796
13797func (s *GoogleCloudDialogflowV2beta1IntentMessageBasicCard) MarshalJSON() ([]byte, error) {
13798	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageBasicCard
13799	raw := NoMethod(*s)
13800	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13801}
13802
13803// GoogleCloudDialogflowV2beta1IntentMessageBasicCardButton: The button
13804// object that appears at the bottom of a card.
13805type GoogleCloudDialogflowV2beta1IntentMessageBasicCardButton struct {
13806	// OpenUriAction: Required. Action to take when a user taps on the
13807	// button.
13808	OpenUriAction *GoogleCloudDialogflowV2beta1IntentMessageBasicCardButtonOpenUriAction `json:"openUriAction,omitempty"`
13809
13810	// Title: Required. The title of the button.
13811	Title string `json:"title,omitempty"`
13812
13813	// ForceSendFields is a list of field names (e.g. "OpenUriAction") to
13814	// unconditionally include in API requests. By default, fields with
13815	// empty values are omitted from API requests. However, any non-pointer,
13816	// non-interface field appearing in ForceSendFields will be sent to the
13817	// server regardless of whether the field is empty or not. This may be
13818	// used to include empty fields in Patch requests.
13819	ForceSendFields []string `json:"-"`
13820
13821	// NullFields is a list of field names (e.g. "OpenUriAction") to include
13822	// in API requests with the JSON null value. By default, fields with
13823	// empty values are omitted from API requests. However, any field with
13824	// an empty value appearing in NullFields will be sent to the server as
13825	// null. It is an error if a field in this list has a non-empty value.
13826	// This may be used to include null fields in Patch requests.
13827	NullFields []string `json:"-"`
13828}
13829
13830func (s *GoogleCloudDialogflowV2beta1IntentMessageBasicCardButton) MarshalJSON() ([]byte, error) {
13831	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageBasicCardButton
13832	raw := NoMethod(*s)
13833	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13834}
13835
13836// GoogleCloudDialogflowV2beta1IntentMessageBasicCardButtonOpenUriAction:
13837//  Opens the given URI.
13838type GoogleCloudDialogflowV2beta1IntentMessageBasicCardButtonOpenUriAction struct {
13839	// Uri: Required. The HTTP or HTTPS scheme URI.
13840	Uri string `json:"uri,omitempty"`
13841
13842	// ForceSendFields is a list of field names (e.g. "Uri") to
13843	// unconditionally include in API requests. By default, fields with
13844	// empty values are omitted from API requests. However, any non-pointer,
13845	// non-interface field appearing in ForceSendFields will be sent to the
13846	// server regardless of whether the field is empty or not. This may be
13847	// used to include empty fields in Patch requests.
13848	ForceSendFields []string `json:"-"`
13849
13850	// NullFields is a list of field names (e.g. "Uri") to include in API
13851	// requests with the JSON null value. By default, fields with empty
13852	// values are omitted from API requests. However, any field with an
13853	// empty value appearing in NullFields will be sent to the server as
13854	// null. It is an error if a field in this list has a non-empty value.
13855	// This may be used to include null fields in Patch requests.
13856	NullFields []string `json:"-"`
13857}
13858
13859func (s *GoogleCloudDialogflowV2beta1IntentMessageBasicCardButtonOpenUriAction) MarshalJSON() ([]byte, error) {
13860	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageBasicCardButtonOpenUriAction
13861	raw := NoMethod(*s)
13862	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13863}
13864
13865// GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCard: Browse
13866// Carousel Card for Actions on Google.
13867// https://developers.google.com/actions/assistant/responses#browsing_carousel
13868type GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCard struct {
13869	// ImageDisplayOptions: Optional. Settings for displaying the image.
13870	// Applies to every image in items.
13871	//
13872	// Possible values:
13873	//   "IMAGE_DISPLAY_OPTIONS_UNSPECIFIED" - Fill the gaps between the
13874	// image and the image container with gray bars.
13875	//   "GRAY" - Fill the gaps between the image and the image container
13876	// with gray bars.
13877	//   "WHITE" - Fill the gaps between the image and the image container
13878	// with white bars.
13879	//   "CROPPED" - Image is scaled such that the image width and height
13880	// match or exceed the container dimensions. This may crop the top and
13881	// bottom of the image if the scaled image height is greater than the
13882	// container height, or crop the left and right of the image if the
13883	// scaled image width is greater than the container width. This is
13884	// similar to "Zoom Mode" on a widescreen TV when playing a 4:3 video.
13885	//   "BLURRED_BACKGROUND" - Pad the gaps between image and image frame
13886	// with a blurred copy of the same image.
13887	ImageDisplayOptions string `json:"imageDisplayOptions,omitempty"`
13888
13889	// Items: Required. List of items in the Browse Carousel Card. Minimum
13890	// of two items, maximum of ten.
13891	Items []*GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItem `json:"items,omitempty"`
13892
13893	// ForceSendFields is a list of field names (e.g. "ImageDisplayOptions")
13894	// to unconditionally include in API requests. By default, fields with
13895	// empty values are omitted from API requests. However, any non-pointer,
13896	// non-interface field appearing in ForceSendFields will be sent to the
13897	// server regardless of whether the field is empty or not. This may be
13898	// used to include empty fields in Patch requests.
13899	ForceSendFields []string `json:"-"`
13900
13901	// NullFields is a list of field names (e.g. "ImageDisplayOptions") to
13902	// include in API requests with the JSON null value. By default, fields
13903	// with empty values are omitted from API requests. However, any field
13904	// with an empty value appearing in NullFields will be sent to the
13905	// server as null. It is an error if a field in this list has a
13906	// non-empty value. This may be used to include null fields in Patch
13907	// requests.
13908	NullFields []string `json:"-"`
13909}
13910
13911func (s *GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCard) MarshalJSON() ([]byte, error) {
13912	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCard
13913	raw := NoMethod(*s)
13914	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13915}
13916
13917// GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarou
13918// selCardItem: Browsing carousel tile
13919type GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItem struct {
13920	// Description: Optional. Description of the carousel item. Maximum of
13921	// four lines of text.
13922	Description string `json:"description,omitempty"`
13923
13924	// Footer: Optional. Text that appears at the bottom of the Browse
13925	// Carousel Card. Maximum of one line of text.
13926	Footer string `json:"footer,omitempty"`
13927
13928	// Image: Optional. Hero image for the carousel item.
13929	Image *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"image,omitempty"`
13930
13931	// OpenUriAction: Required. Action to present to the user.
13932	OpenUriAction *GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction `json:"openUriAction,omitempty"`
13933
13934	// Title: Required. Title of the carousel item. Maximum of two lines of
13935	// text.
13936	Title string `json:"title,omitempty"`
13937
13938	// ForceSendFields is a list of field names (e.g. "Description") to
13939	// unconditionally include in API requests. By default, fields with
13940	// empty values are omitted from API requests. However, any non-pointer,
13941	// non-interface field appearing in ForceSendFields will be sent to the
13942	// server regardless of whether the field is empty or not. This may be
13943	// used to include empty fields in Patch requests.
13944	ForceSendFields []string `json:"-"`
13945
13946	// NullFields is a list of field names (e.g. "Description") to include
13947	// in API requests with the JSON null value. By default, fields with
13948	// empty values are omitted from API requests. However, any field with
13949	// an empty value appearing in NullFields will be sent to the server as
13950	// null. It is an error if a field in this list has a non-empty value.
13951	// This may be used to include null fields in Patch requests.
13952	NullFields []string `json:"-"`
13953}
13954
13955func (s *GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItem) MarshalJSON() ([]byte, error) {
13956	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItem
13957	raw := NoMethod(*s)
13958	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13959}
13960
13961// GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarou
13962// selCardItemOpenUrlAction: Actions on Google action to open a given
13963// url.
13964type GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction struct {
13965	// Url: Required. URL
13966	Url string `json:"url,omitempty"`
13967
13968	// UrlTypeHint: Optional. Specifies the type of viewer that is used when
13969	// opening the URL. Defaults to opening via web browser.
13970	//
13971	// Possible values:
13972	//   "URL_TYPE_HINT_UNSPECIFIED" - Unspecified
13973	//   "AMP_ACTION" - Url would be an amp action
13974	//   "AMP_CONTENT" - URL that points directly to AMP content, or to a
13975	// canonical URL which refers to AMP content via .
13976	UrlTypeHint string `json:"urlTypeHint,omitempty"`
13977
13978	// ForceSendFields is a list of field names (e.g. "Url") to
13979	// unconditionally include in API requests. By default, fields with
13980	// empty values are omitted from API requests. However, any non-pointer,
13981	// non-interface field appearing in ForceSendFields will be sent to the
13982	// server regardless of whether the field is empty or not. This may be
13983	// used to include empty fields in Patch requests.
13984	ForceSendFields []string `json:"-"`
13985
13986	// NullFields is a list of field names (e.g. "Url") to include in API
13987	// requests with the JSON null value. By default, fields with empty
13988	// values are omitted from API requests. However, any field with an
13989	// empty value appearing in NullFields will be sent to the server as
13990	// null. It is an error if a field in this list has a non-empty value.
13991	// This may be used to include null fields in Patch requests.
13992	NullFields []string `json:"-"`
13993}
13994
13995func (s *GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction) MarshalJSON() ([]byte, error) {
13996	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction
13997	raw := NoMethod(*s)
13998	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13999}
14000
14001// GoogleCloudDialogflowV2beta1IntentMessageCard: The card response
14002// message.
14003type GoogleCloudDialogflowV2beta1IntentMessageCard struct {
14004	// Buttons: Optional. The collection of card buttons.
14005	Buttons []*GoogleCloudDialogflowV2beta1IntentMessageCardButton `json:"buttons,omitempty"`
14006
14007	// ImageUri: Optional. The public URI to an image file for the card.
14008	ImageUri string `json:"imageUri,omitempty"`
14009
14010	// Subtitle: Optional. The subtitle of the card.
14011	Subtitle string `json:"subtitle,omitempty"`
14012
14013	// Title: Optional. The title of the card.
14014	Title string `json:"title,omitempty"`
14015
14016	// ForceSendFields is a list of field names (e.g. "Buttons") to
14017	// unconditionally include in API requests. By default, fields with
14018	// empty values are omitted from API requests. However, any non-pointer,
14019	// non-interface field appearing in ForceSendFields will be sent to the
14020	// server regardless of whether the field is empty or not. This may be
14021	// used to include empty fields in Patch requests.
14022	ForceSendFields []string `json:"-"`
14023
14024	// NullFields is a list of field names (e.g. "Buttons") to include in
14025	// API requests with the JSON null value. By default, fields with empty
14026	// values are omitted from API requests. However, any field with an
14027	// empty value appearing in NullFields will be sent to the server as
14028	// null. It is an error if a field in this list has a non-empty value.
14029	// This may be used to include null fields in Patch requests.
14030	NullFields []string `json:"-"`
14031}
14032
14033func (s *GoogleCloudDialogflowV2beta1IntentMessageCard) MarshalJSON() ([]byte, error) {
14034	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageCard
14035	raw := NoMethod(*s)
14036	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14037}
14038
14039// GoogleCloudDialogflowV2beta1IntentMessageCardButton: Optional.
14040// Contains information about a button.
14041type GoogleCloudDialogflowV2beta1IntentMessageCardButton struct {
14042	// Postback: Optional. The text to send back to the Dialogflow API or a
14043	// URI to open.
14044	Postback string `json:"postback,omitempty"`
14045
14046	// Text: Optional. The text to show on the button.
14047	Text string `json:"text,omitempty"`
14048
14049	// ForceSendFields is a list of field names (e.g. "Postback") to
14050	// unconditionally include in API requests. By default, fields with
14051	// empty values are omitted from API requests. However, any non-pointer,
14052	// non-interface field appearing in ForceSendFields will be sent to the
14053	// server regardless of whether the field is empty or not. This may be
14054	// used to include empty fields in Patch requests.
14055	ForceSendFields []string `json:"-"`
14056
14057	// NullFields is a list of field names (e.g. "Postback") to include in
14058	// API requests with the JSON null value. By default, fields with empty
14059	// values are omitted from API requests. However, any field with an
14060	// empty value appearing in NullFields will be sent to the server as
14061	// null. It is an error if a field in this list has a non-empty value.
14062	// This may be used to include null fields in Patch requests.
14063	NullFields []string `json:"-"`
14064}
14065
14066func (s *GoogleCloudDialogflowV2beta1IntentMessageCardButton) MarshalJSON() ([]byte, error) {
14067	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageCardButton
14068	raw := NoMethod(*s)
14069	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14070}
14071
14072// GoogleCloudDialogflowV2beta1IntentMessageCarouselSelect: The card for
14073// presenting a carousel of options to select from.
14074type GoogleCloudDialogflowV2beta1IntentMessageCarouselSelect struct {
14075	// Items: Required. Carousel items.
14076	Items []*GoogleCloudDialogflowV2beta1IntentMessageCarouselSelectItem `json:"items,omitempty"`
14077
14078	// ForceSendFields is a list of field names (e.g. "Items") to
14079	// unconditionally include in API requests. By default, fields with
14080	// empty values are omitted from API requests. However, any non-pointer,
14081	// non-interface field appearing in ForceSendFields will be sent to the
14082	// server regardless of whether the field is empty or not. This may be
14083	// used to include empty fields in Patch requests.
14084	ForceSendFields []string `json:"-"`
14085
14086	// NullFields is a list of field names (e.g. "Items") to include in API
14087	// requests with the JSON null value. By default, fields with empty
14088	// values are omitted from API requests. However, any field with an
14089	// empty value appearing in NullFields will be sent to the server as
14090	// null. It is an error if a field in this list has a non-empty value.
14091	// This may be used to include null fields in Patch requests.
14092	NullFields []string `json:"-"`
14093}
14094
14095func (s *GoogleCloudDialogflowV2beta1IntentMessageCarouselSelect) MarshalJSON() ([]byte, error) {
14096	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageCarouselSelect
14097	raw := NoMethod(*s)
14098	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14099}
14100
14101// GoogleCloudDialogflowV2beta1IntentMessageCarouselSelectItem: An item
14102// in the carousel.
14103type GoogleCloudDialogflowV2beta1IntentMessageCarouselSelectItem struct {
14104	// Description: Optional. The body text of the card.
14105	Description string `json:"description,omitempty"`
14106
14107	// Image: Optional. The image to display.
14108	Image *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"image,omitempty"`
14109
14110	// Info: Required. Additional info about the option item.
14111	Info *GoogleCloudDialogflowV2beta1IntentMessageSelectItemInfo `json:"info,omitempty"`
14112
14113	// Title: Required. Title of the carousel item.
14114	Title string `json:"title,omitempty"`
14115
14116	// ForceSendFields is a list of field names (e.g. "Description") to
14117	// unconditionally include in API requests. By default, fields with
14118	// empty values are omitted from API requests. However, any non-pointer,
14119	// non-interface field appearing in ForceSendFields will be sent to the
14120	// server regardless of whether the field is empty or not. This may be
14121	// used to include empty fields in Patch requests.
14122	ForceSendFields []string `json:"-"`
14123
14124	// NullFields is a list of field names (e.g. "Description") to include
14125	// in API requests with the JSON null value. By default, fields with
14126	// empty values are omitted from API requests. However, any field with
14127	// an empty value appearing in NullFields will be sent to the server as
14128	// null. It is an error if a field in this list has a non-empty value.
14129	// This may be used to include null fields in Patch requests.
14130	NullFields []string `json:"-"`
14131}
14132
14133func (s *GoogleCloudDialogflowV2beta1IntentMessageCarouselSelectItem) MarshalJSON() ([]byte, error) {
14134	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageCarouselSelectItem
14135	raw := NoMethod(*s)
14136	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14137}
14138
14139// GoogleCloudDialogflowV2beta1IntentMessageColumnProperties: Column
14140// properties for TableCard.
14141type GoogleCloudDialogflowV2beta1IntentMessageColumnProperties struct {
14142	// Header: Required. Column heading.
14143	Header string `json:"header,omitempty"`
14144
14145	// HorizontalAlignment: Optional. Defines text alignment for all cells
14146	// in this column.
14147	//
14148	// Possible values:
14149	//   "HORIZONTAL_ALIGNMENT_UNSPECIFIED" - Text is aligned to the leading
14150	// edge of the column.
14151	//   "LEADING" - Text is aligned to the leading edge of the column.
14152	//   "CENTER" - Text is centered in the column.
14153	//   "TRAILING" - Text is aligned to the trailing edge of the column.
14154	HorizontalAlignment string `json:"horizontalAlignment,omitempty"`
14155
14156	// ForceSendFields is a list of field names (e.g. "Header") to
14157	// unconditionally include in API requests. By default, fields with
14158	// empty values are omitted from API requests. However, any non-pointer,
14159	// non-interface field appearing in ForceSendFields will be sent to the
14160	// server regardless of whether the field is empty or not. This may be
14161	// used to include empty fields in Patch requests.
14162	ForceSendFields []string `json:"-"`
14163
14164	// NullFields is a list of field names (e.g. "Header") to include in API
14165	// requests with the JSON null value. By default, fields with empty
14166	// values are omitted from API requests. However, any field with an
14167	// empty value appearing in NullFields will be sent to the server as
14168	// null. It is an error if a field in this list has a non-empty value.
14169	// This may be used to include null fields in Patch requests.
14170	NullFields []string `json:"-"`
14171}
14172
14173func (s *GoogleCloudDialogflowV2beta1IntentMessageColumnProperties) MarshalJSON() ([]byte, error) {
14174	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageColumnProperties
14175	raw := NoMethod(*s)
14176	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14177}
14178
14179// GoogleCloudDialogflowV2beta1IntentMessageImage: The image response
14180// message.
14181type GoogleCloudDialogflowV2beta1IntentMessageImage struct {
14182	// AccessibilityText: A text description of the image to be used for
14183	// accessibility, e.g., screen readers. Required if image_uri is set for
14184	// CarouselSelect.
14185	AccessibilityText string `json:"accessibilityText,omitempty"`
14186
14187	// ImageUri: Optional. The public URI to an image file.
14188	ImageUri string `json:"imageUri,omitempty"`
14189
14190	// ForceSendFields is a list of field names (e.g. "AccessibilityText")
14191	// to unconditionally include in API requests. By default, fields with
14192	// empty values are omitted from API requests. However, any non-pointer,
14193	// non-interface field appearing in ForceSendFields will be sent to the
14194	// server regardless of whether the field is empty or not. This may be
14195	// used to include empty fields in Patch requests.
14196	ForceSendFields []string `json:"-"`
14197
14198	// NullFields is a list of field names (e.g. "AccessibilityText") to
14199	// include in API requests with the JSON null value. By default, fields
14200	// with empty values are omitted from API requests. However, any field
14201	// with an empty value appearing in NullFields will be sent to the
14202	// server as null. It is an error if a field in this list has a
14203	// non-empty value. This may be used to include null fields in Patch
14204	// requests.
14205	NullFields []string `json:"-"`
14206}
14207
14208func (s *GoogleCloudDialogflowV2beta1IntentMessageImage) MarshalJSON() ([]byte, error) {
14209	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageImage
14210	raw := NoMethod(*s)
14211	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14212}
14213
14214// GoogleCloudDialogflowV2beta1IntentMessageLinkOutSuggestion: The
14215// suggestion chip message that allows the user to jump out to the app
14216// or website associated with this agent.
14217type GoogleCloudDialogflowV2beta1IntentMessageLinkOutSuggestion struct {
14218	// DestinationName: Required. The name of the app or site this chip is
14219	// linking to.
14220	DestinationName string `json:"destinationName,omitempty"`
14221
14222	// Uri: Required. The URI of the app or site to open when the user taps
14223	// the suggestion chip.
14224	Uri string `json:"uri,omitempty"`
14225
14226	// ForceSendFields is a list of field names (e.g. "DestinationName") to
14227	// unconditionally include in API requests. By default, fields with
14228	// empty values are omitted from API requests. However, any non-pointer,
14229	// non-interface field appearing in ForceSendFields will be sent to the
14230	// server regardless of whether the field is empty or not. This may be
14231	// used to include empty fields in Patch requests.
14232	ForceSendFields []string `json:"-"`
14233
14234	// NullFields is a list of field names (e.g. "DestinationName") to
14235	// include in API requests with the JSON null value. By default, fields
14236	// with empty values are omitted from API requests. However, any field
14237	// with an empty value appearing in NullFields will be sent to the
14238	// server as null. It is an error if a field in this list has a
14239	// non-empty value. This may be used to include null fields in Patch
14240	// requests.
14241	NullFields []string `json:"-"`
14242}
14243
14244func (s *GoogleCloudDialogflowV2beta1IntentMessageLinkOutSuggestion) MarshalJSON() ([]byte, error) {
14245	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageLinkOutSuggestion
14246	raw := NoMethod(*s)
14247	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14248}
14249
14250// GoogleCloudDialogflowV2beta1IntentMessageListSelect: The card for
14251// presenting a list of options to select from.
14252type GoogleCloudDialogflowV2beta1IntentMessageListSelect struct {
14253	// Items: Required. List items.
14254	Items []*GoogleCloudDialogflowV2beta1IntentMessageListSelectItem `json:"items,omitempty"`
14255
14256	// Subtitle: Optional. Subtitle of the list.
14257	Subtitle string `json:"subtitle,omitempty"`
14258
14259	// Title: Optional. The overall title of the list.
14260	Title string `json:"title,omitempty"`
14261
14262	// ForceSendFields is a list of field names (e.g. "Items") to
14263	// unconditionally include in API requests. By default, fields with
14264	// empty values are omitted from API requests. However, any non-pointer,
14265	// non-interface field appearing in ForceSendFields will be sent to the
14266	// server regardless of whether the field is empty or not. This may be
14267	// used to include empty fields in Patch requests.
14268	ForceSendFields []string `json:"-"`
14269
14270	// NullFields is a list of field names (e.g. "Items") to include in API
14271	// requests with the JSON null value. By default, fields with empty
14272	// values are omitted from API requests. However, any field with an
14273	// empty value appearing in NullFields will be sent to the server as
14274	// null. It is an error if a field in this list has a non-empty value.
14275	// This may be used to include null fields in Patch requests.
14276	NullFields []string `json:"-"`
14277}
14278
14279func (s *GoogleCloudDialogflowV2beta1IntentMessageListSelect) MarshalJSON() ([]byte, error) {
14280	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageListSelect
14281	raw := NoMethod(*s)
14282	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14283}
14284
14285// GoogleCloudDialogflowV2beta1IntentMessageListSelectItem: An item in
14286// the list.
14287type GoogleCloudDialogflowV2beta1IntentMessageListSelectItem struct {
14288	// Description: Optional. The main text describing the item.
14289	Description string `json:"description,omitempty"`
14290
14291	// Image: Optional. The image to display.
14292	Image *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"image,omitempty"`
14293
14294	// Info: Required. Additional information about this option.
14295	Info *GoogleCloudDialogflowV2beta1IntentMessageSelectItemInfo `json:"info,omitempty"`
14296
14297	// Title: Required. The title of the list item.
14298	Title string `json:"title,omitempty"`
14299
14300	// ForceSendFields is a list of field names (e.g. "Description") to
14301	// unconditionally include in API requests. By default, fields with
14302	// empty values are omitted from API requests. However, any non-pointer,
14303	// non-interface field appearing in ForceSendFields will be sent to the
14304	// server regardless of whether the field is empty or not. This may be
14305	// used to include empty fields in Patch requests.
14306	ForceSendFields []string `json:"-"`
14307
14308	// NullFields is a list of field names (e.g. "Description") to include
14309	// in API requests with the JSON null value. By default, fields with
14310	// empty values are omitted from API requests. However, any field with
14311	// an empty value appearing in NullFields will be sent to the server as
14312	// null. It is an error if a field in this list has a non-empty value.
14313	// This may be used to include null fields in Patch requests.
14314	NullFields []string `json:"-"`
14315}
14316
14317func (s *GoogleCloudDialogflowV2beta1IntentMessageListSelectItem) MarshalJSON() ([]byte, error) {
14318	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageListSelectItem
14319	raw := NoMethod(*s)
14320	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14321}
14322
14323// GoogleCloudDialogflowV2beta1IntentMessageMediaContent: The media
14324// content card for Actions on Google.
14325type GoogleCloudDialogflowV2beta1IntentMessageMediaContent struct {
14326	// MediaObjects: Required. List of media objects.
14327	MediaObjects []*GoogleCloudDialogflowV2beta1IntentMessageMediaContentResponseMediaObject `json:"mediaObjects,omitempty"`
14328
14329	// MediaType: Optional. What type of media is the content (ie "audio").
14330	//
14331	// Possible values:
14332	//   "RESPONSE_MEDIA_TYPE_UNSPECIFIED" - Unspecified.
14333	//   "AUDIO" - Response media type is audio.
14334	MediaType string `json:"mediaType,omitempty"`
14335
14336	// ForceSendFields is a list of field names (e.g. "MediaObjects") to
14337	// unconditionally include in API requests. By default, fields with
14338	// empty values are omitted from API requests. However, any non-pointer,
14339	// non-interface field appearing in ForceSendFields will be sent to the
14340	// server regardless of whether the field is empty or not. This may be
14341	// used to include empty fields in Patch requests.
14342	ForceSendFields []string `json:"-"`
14343
14344	// NullFields is a list of field names (e.g. "MediaObjects") to include
14345	// in API requests with the JSON null value. By default, fields with
14346	// empty values are omitted from API requests. However, any field with
14347	// an empty value appearing in NullFields will be sent to the server as
14348	// null. It is an error if a field in this list has a non-empty value.
14349	// This may be used to include null fields in Patch requests.
14350	NullFields []string `json:"-"`
14351}
14352
14353func (s *GoogleCloudDialogflowV2beta1IntentMessageMediaContent) MarshalJSON() ([]byte, error) {
14354	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageMediaContent
14355	raw := NoMethod(*s)
14356	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14357}
14358
14359// GoogleCloudDialogflowV2beta1IntentMessageMediaContentResponseMediaObje
14360// ct: Response media object for media content card.
14361type GoogleCloudDialogflowV2beta1IntentMessageMediaContentResponseMediaObject struct {
14362	// ContentUrl: Required. Url where the media is stored.
14363	ContentUrl string `json:"contentUrl,omitempty"`
14364
14365	// Description: Optional. Description of media card.
14366	Description string `json:"description,omitempty"`
14367
14368	// Icon: Optional. Icon to display above media content.
14369	Icon *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"icon,omitempty"`
14370
14371	// LargeImage: Optional. Image to display above media content.
14372	LargeImage *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"largeImage,omitempty"`
14373
14374	// Name: Required. Name of media card.
14375	Name string `json:"name,omitempty"`
14376
14377	// ForceSendFields is a list of field names (e.g. "ContentUrl") to
14378	// unconditionally include in API requests. By default, fields with
14379	// empty values are omitted from API requests. However, any non-pointer,
14380	// non-interface field appearing in ForceSendFields will be sent to the
14381	// server regardless of whether the field is empty or not. This may be
14382	// used to include empty fields in Patch requests.
14383	ForceSendFields []string `json:"-"`
14384
14385	// NullFields is a list of field names (e.g. "ContentUrl") to include in
14386	// API requests with the JSON null value. By default, fields with empty
14387	// values are omitted from API requests. However, any field with an
14388	// empty value appearing in NullFields will be sent to the server as
14389	// null. It is an error if a field in this list has a non-empty value.
14390	// This may be used to include null fields in Patch requests.
14391	NullFields []string `json:"-"`
14392}
14393
14394func (s *GoogleCloudDialogflowV2beta1IntentMessageMediaContentResponseMediaObject) MarshalJSON() ([]byte, error) {
14395	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageMediaContentResponseMediaObject
14396	raw := NoMethod(*s)
14397	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14398}
14399
14400// GoogleCloudDialogflowV2beta1IntentMessageQuickReplies: The quick
14401// replies response message.
14402type GoogleCloudDialogflowV2beta1IntentMessageQuickReplies struct {
14403	// QuickReplies: Optional. The collection of quick replies.
14404	QuickReplies []string `json:"quickReplies,omitempty"`
14405
14406	// Title: Optional. The title of the collection of quick replies.
14407	Title string `json:"title,omitempty"`
14408
14409	// ForceSendFields is a list of field names (e.g. "QuickReplies") to
14410	// unconditionally include in API requests. By default, fields with
14411	// empty values are omitted from API requests. However, any non-pointer,
14412	// non-interface field appearing in ForceSendFields will be sent to the
14413	// server regardless of whether the field is empty or not. This may be
14414	// used to include empty fields in Patch requests.
14415	ForceSendFields []string `json:"-"`
14416
14417	// NullFields is a list of field names (e.g. "QuickReplies") to include
14418	// in API requests with the JSON null value. By default, fields with
14419	// empty values are omitted from API requests. However, any field with
14420	// an empty value appearing in NullFields will be sent to the server as
14421	// null. It is an error if a field in this list has a non-empty value.
14422	// This may be used to include null fields in Patch requests.
14423	NullFields []string `json:"-"`
14424}
14425
14426func (s *GoogleCloudDialogflowV2beta1IntentMessageQuickReplies) MarshalJSON() ([]byte, error) {
14427	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageQuickReplies
14428	raw := NoMethod(*s)
14429	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14430}
14431
14432// GoogleCloudDialogflowV2beta1IntentMessageRbmCardContent: Rich
14433// Business Messaging (RBM) Card content
14434type GoogleCloudDialogflowV2beta1IntentMessageRbmCardContent struct {
14435	// Description: Optional. Description of the card (at most 2000 bytes).
14436	// At least one of the title, description or media must be set.
14437	Description string `json:"description,omitempty"`
14438
14439	// Media: Optional. However at least one of the title, description or
14440	// media must be set. Media (image, GIF or a video) to include in the
14441	// card.
14442	Media *GoogleCloudDialogflowV2beta1IntentMessageRbmCardContentRbmMedia `json:"media,omitempty"`
14443
14444	// Suggestions: Optional. List of suggestions to include in the card.
14445	Suggestions []*GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestion `json:"suggestions,omitempty"`
14446
14447	// Title: Optional. Title of the card (at most 200 bytes). At least one
14448	// of the title, description or media must be set.
14449	Title string `json:"title,omitempty"`
14450
14451	// ForceSendFields is a list of field names (e.g. "Description") to
14452	// unconditionally include in API requests. By default, fields with
14453	// empty values are omitted from API requests. However, any non-pointer,
14454	// non-interface field appearing in ForceSendFields will be sent to the
14455	// server regardless of whether the field is empty or not. This may be
14456	// used to include empty fields in Patch requests.
14457	ForceSendFields []string `json:"-"`
14458
14459	// NullFields is a list of field names (e.g. "Description") to include
14460	// in API requests with the JSON null value. By default, fields with
14461	// empty values are omitted from API requests. However, any field with
14462	// an empty value appearing in NullFields will be sent to the server as
14463	// null. It is an error if a field in this list has a non-empty value.
14464	// This may be used to include null fields in Patch requests.
14465	NullFields []string `json:"-"`
14466}
14467
14468func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmCardContent) MarshalJSON() ([]byte, error) {
14469	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmCardContent
14470	raw := NoMethod(*s)
14471	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14472}
14473
14474// GoogleCloudDialogflowV2beta1IntentMessageRbmCardContentRbmMedia: Rich
14475// Business Messaging (RBM) Media displayed in Cards The following
14476// media-types are currently supported: Image Types * image/jpeg *
14477// image/jpg' * image/gif * image/png Video Types * video/h263 *
14478// video/m4v * video/mp4 * video/mpeg * video/mpeg4 * video/webm
14479type GoogleCloudDialogflowV2beta1IntentMessageRbmCardContentRbmMedia struct {
14480	// FileUri: Required. Publicly reachable URI of the file. The RBM
14481	// platform determines the MIME type of the file from the content-type
14482	// field in the HTTP headers when the platform fetches the file. The
14483	// content-type field must be present and accurate in the HTTP response
14484	// from the URL.
14485	FileUri string `json:"fileUri,omitempty"`
14486
14487	// Height: Required for cards with vertical orientation. The height of
14488	// the media within a rich card with a vertical layout. For a standalone
14489	// card with horizontal layout, height is not customizable, and this
14490	// field is ignored.
14491	//
14492	// Possible values:
14493	//   "HEIGHT_UNSPECIFIED" - Not specified.
14494	//   "SHORT" - 112 DP.
14495	//   "MEDIUM" - 168 DP.
14496	//   "TALL" - 264 DP. Not available for rich card carousels when the
14497	// card width is set to small.
14498	Height string `json:"height,omitempty"`
14499
14500	// ThumbnailUri: Optional. Publicly reachable URI of the thumbnail.If
14501	// you don't provide a thumbnail URI, the RBM platform displays a blank
14502	// placeholder thumbnail until the user's device downloads the file.
14503	// Depending on the user's setting, the file may not download
14504	// automatically and may require the user to tap a download button.
14505	ThumbnailUri string `json:"thumbnailUri,omitempty"`
14506
14507	// ForceSendFields is a list of field names (e.g. "FileUri") to
14508	// unconditionally include in API requests. By default, fields with
14509	// empty values are omitted from API requests. However, any non-pointer,
14510	// non-interface field appearing in ForceSendFields will be sent to the
14511	// server regardless of whether the field is empty or not. This may be
14512	// used to include empty fields in Patch requests.
14513	ForceSendFields []string `json:"-"`
14514
14515	// NullFields is a list of field names (e.g. "FileUri") to include in
14516	// API requests with the JSON null value. By default, fields with empty
14517	// values are omitted from API requests. However, any field with an
14518	// empty value appearing in NullFields will be sent to the server as
14519	// null. It is an error if a field in this list has a non-empty value.
14520	// This may be used to include null fields in Patch requests.
14521	NullFields []string `json:"-"`
14522}
14523
14524func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmCardContentRbmMedia) MarshalJSON() ([]byte, error) {
14525	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmCardContentRbmMedia
14526	raw := NoMethod(*s)
14527	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14528}
14529
14530// GoogleCloudDialogflowV2beta1IntentMessageRbmCarouselCard: Carousel
14531// Rich Business Messaging (RBM) rich card. Rich cards allow you to
14532// respond to users with more vivid content, e.g. with media and
14533// suggestions. If you want to show a single card with more control over
14534// the layout, please use RbmStandaloneCard instead.
14535type GoogleCloudDialogflowV2beta1IntentMessageRbmCarouselCard struct {
14536	// CardContents: Required. The cards in the carousel. A carousel must
14537	// have at least 2 cards and at most 10.
14538	CardContents []*GoogleCloudDialogflowV2beta1IntentMessageRbmCardContent `json:"cardContents,omitempty"`
14539
14540	// CardWidth: Required. The width of the cards in the carousel.
14541	//
14542	// Possible values:
14543	//   "CARD_WIDTH_UNSPECIFIED" - Not specified.
14544	//   "SMALL" - 120 DP. Note that tall media cannot be used.
14545	//   "MEDIUM" - 232 DP.
14546	CardWidth string `json:"cardWidth,omitempty"`
14547
14548	// ForceSendFields is a list of field names (e.g. "CardContents") to
14549	// unconditionally include in API requests. By default, fields with
14550	// empty values are omitted from API requests. However, any non-pointer,
14551	// non-interface field appearing in ForceSendFields will be sent to the
14552	// server regardless of whether the field is empty or not. This may be
14553	// used to include empty fields in Patch requests.
14554	ForceSendFields []string `json:"-"`
14555
14556	// NullFields is a list of field names (e.g. "CardContents") to include
14557	// in API requests with the JSON null value. By default, fields with
14558	// empty values are omitted from API requests. However, any field with
14559	// an empty value appearing in NullFields will be sent to the server as
14560	// null. It is an error if a field in this list has a non-empty value.
14561	// This may be used to include null fields in Patch requests.
14562	NullFields []string `json:"-"`
14563}
14564
14565func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmCarouselCard) MarshalJSON() ([]byte, error) {
14566	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmCarouselCard
14567	raw := NoMethod(*s)
14568	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14569}
14570
14571// GoogleCloudDialogflowV2beta1IntentMessageRbmStandaloneCard:
14572// Standalone Rich Business Messaging (RBM) rich card. Rich cards allow
14573// you to respond to users with more vivid content, e.g. with media and
14574// suggestions. You can group multiple rich cards into one using
14575// RbmCarouselCard but carousel cards will give you less control over
14576// the card layout.
14577type GoogleCloudDialogflowV2beta1IntentMessageRbmStandaloneCard struct {
14578	// CardContent: Required. Card content.
14579	CardContent *GoogleCloudDialogflowV2beta1IntentMessageRbmCardContent `json:"cardContent,omitempty"`
14580
14581	// CardOrientation: Required. Orientation of the card.
14582	//
14583	// Possible values:
14584	//   "CARD_ORIENTATION_UNSPECIFIED" - Not specified.
14585	//   "HORIZONTAL" - Horizontal layout.
14586	//   "VERTICAL" - Vertical layout.
14587	CardOrientation string `json:"cardOrientation,omitempty"`
14588
14589	// ThumbnailImageAlignment: Required if orientation is horizontal. Image
14590	// preview alignment for standalone cards with horizontal layout.
14591	//
14592	// Possible values:
14593	//   "THUMBNAIL_IMAGE_ALIGNMENT_UNSPECIFIED" - Not specified.
14594	//   "LEFT" - Thumbnail preview is left-aligned.
14595	//   "RIGHT" - Thumbnail preview is right-aligned.
14596	ThumbnailImageAlignment string `json:"thumbnailImageAlignment,omitempty"`
14597
14598	// ForceSendFields is a list of field names (e.g. "CardContent") to
14599	// unconditionally include in API requests. By default, fields with
14600	// empty values are omitted from API requests. However, any non-pointer,
14601	// non-interface field appearing in ForceSendFields will be sent to the
14602	// server regardless of whether the field is empty or not. This may be
14603	// used to include empty fields in Patch requests.
14604	ForceSendFields []string `json:"-"`
14605
14606	// NullFields is a list of field names (e.g. "CardContent") to include
14607	// in API requests with the JSON null value. By default, fields with
14608	// empty values are omitted from API requests. However, any field with
14609	// an empty value appearing in NullFields will be sent to the server as
14610	// null. It is an error if a field in this list has a non-empty value.
14611	// This may be used to include null fields in Patch requests.
14612	NullFields []string `json:"-"`
14613}
14614
14615func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmStandaloneCard) MarshalJSON() ([]byte, error) {
14616	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmStandaloneCard
14617	raw := NoMethod(*s)
14618	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14619}
14620
14621// GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedAction: Rich
14622// Business Messaging (RBM) suggested client-side action that the user
14623// can choose from the card.
14624type GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedAction struct {
14625	// Dial: Suggested client side action: Dial a phone number
14626	Dial *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionDial `json:"dial,omitempty"`
14627
14628	// OpenUrl: Suggested client side action: Open a URI on device
14629	OpenUrl *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionOpenUri `json:"openUrl,omitempty"`
14630
14631	// PostbackData: Opaque payload that the Dialogflow receives in a user
14632	// event when the user taps the suggested action. This data will be also
14633	// forwarded to webhook to allow performing custom business logic.
14634	PostbackData string `json:"postbackData,omitempty"`
14635
14636	// ShareLocation: Suggested client side action: Share user location
14637	ShareLocation *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionShareLocation `json:"shareLocation,omitempty"`
14638
14639	// Text: Text to display alongside the action.
14640	Text string `json:"text,omitempty"`
14641
14642	// ForceSendFields is a list of field names (e.g. "Dial") to
14643	// unconditionally include in API requests. By default, fields with
14644	// empty values are omitted from API requests. However, any non-pointer,
14645	// non-interface field appearing in ForceSendFields will be sent to the
14646	// server regardless of whether the field is empty or not. This may be
14647	// used to include empty fields in Patch requests.
14648	ForceSendFields []string `json:"-"`
14649
14650	// NullFields is a list of field names (e.g. "Dial") to include in API
14651	// requests with the JSON null value. By default, fields with empty
14652	// values are omitted from API requests. However, any field with an
14653	// empty value appearing in NullFields will be sent to the server as
14654	// null. It is an error if a field in this list has a non-empty value.
14655	// This may be used to include null fields in Patch requests.
14656	NullFields []string `json:"-"`
14657}
14658
14659func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedAction) MarshalJSON() ([]byte, error) {
14660	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedAction
14661	raw := NoMethod(*s)
14662	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14663}
14664
14665// GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggeste
14666// dActionDial: Opens the user's default dialer app with the specified
14667// phone number but does not dial automatically.
14668type GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionDial struct {
14669	// PhoneNumber: Required. The phone number to fill in the default dialer
14670	// app. This field should be in E.164
14671	// (https://en.wikipedia.org/wiki/E.164) format. An example of a
14672	// correctly formatted phone number: +15556767888.
14673	PhoneNumber string `json:"phoneNumber,omitempty"`
14674
14675	// ForceSendFields is a list of field names (e.g. "PhoneNumber") to
14676	// unconditionally include in API requests. By default, fields with
14677	// empty values are omitted from API requests. However, any non-pointer,
14678	// non-interface field appearing in ForceSendFields will be sent to the
14679	// server regardless of whether the field is empty or not. This may be
14680	// used to include empty fields in Patch requests.
14681	ForceSendFields []string `json:"-"`
14682
14683	// NullFields is a list of field names (e.g. "PhoneNumber") to include
14684	// in API requests with the JSON null value. By default, fields with
14685	// empty values are omitted from API requests. However, any field with
14686	// an empty value appearing in NullFields will be sent to the server as
14687	// null. It is an error if a field in this list has a non-empty value.
14688	// This may be used to include null fields in Patch requests.
14689	NullFields []string `json:"-"`
14690}
14691
14692func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionDial) MarshalJSON() ([]byte, error) {
14693	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionDial
14694	raw := NoMethod(*s)
14695	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14696}
14697
14698// GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggeste
14699// dActionOpenUri: Opens the user's default web browser app to the
14700// specified uri If the user has an app installed that is registered as
14701// the default handler for the URL, then this app will be opened
14702// instead, and its icon will be used in the suggested action UI.
14703type GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionOpenUri struct {
14704	// Uri: Required. The uri to open on the user device
14705	Uri string `json:"uri,omitempty"`
14706
14707	// ForceSendFields is a list of field names (e.g. "Uri") to
14708	// unconditionally include in API requests. By default, fields with
14709	// empty values are omitted from API requests. However, any non-pointer,
14710	// non-interface field appearing in ForceSendFields will be sent to the
14711	// server regardless of whether the field is empty or not. This may be
14712	// used to include empty fields in Patch requests.
14713	ForceSendFields []string `json:"-"`
14714
14715	// NullFields is a list of field names (e.g. "Uri") to include in API
14716	// requests with the JSON null value. By default, fields with empty
14717	// values are omitted from API requests. However, any field with an
14718	// empty value appearing in NullFields will be sent to the server as
14719	// null. It is an error if a field in this list has a non-empty value.
14720	// This may be used to include null fields in Patch requests.
14721	NullFields []string `json:"-"`
14722}
14723
14724func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionOpenUri) MarshalJSON() ([]byte, error) {
14725	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionOpenUri
14726	raw := NoMethod(*s)
14727	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14728}
14729
14730// GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggeste
14731// dActionShareLocation: Opens the device's location chooser so the user
14732// can pick a location to send back to the agent.
14733type GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionShareLocation struct {
14734}
14735
14736// GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedReply: Rich
14737// Business Messaging (RBM) suggested reply that the user can click
14738// instead of typing in their own response.
14739type GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedReply struct {
14740	// PostbackData: Opaque payload that the Dialogflow receives in a user
14741	// event when the user taps the suggested reply. This data will be also
14742	// forwarded to webhook to allow performing custom business logic.
14743	PostbackData string `json:"postbackData,omitempty"`
14744
14745	// Text: Suggested reply text.
14746	Text string `json:"text,omitempty"`
14747
14748	// ForceSendFields is a list of field names (e.g. "PostbackData") to
14749	// unconditionally include in API requests. By default, fields with
14750	// empty values are omitted from API requests. However, any non-pointer,
14751	// non-interface field appearing in ForceSendFields will be sent to the
14752	// server regardless of whether the field is empty or not. This may be
14753	// used to include empty fields in Patch requests.
14754	ForceSendFields []string `json:"-"`
14755
14756	// NullFields is a list of field names (e.g. "PostbackData") to include
14757	// in API requests with the JSON null value. By default, fields with
14758	// empty values are omitted from API requests. However, any field with
14759	// an empty value appearing in NullFields will be sent to the server as
14760	// null. It is an error if a field in this list has a non-empty value.
14761	// This may be used to include null fields in Patch requests.
14762	NullFields []string `json:"-"`
14763}
14764
14765func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedReply) MarshalJSON() ([]byte, error) {
14766	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedReply
14767	raw := NoMethod(*s)
14768	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14769}
14770
14771// GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestion: Rich Business
14772// Messaging (RBM) suggestion. Suggestions allow user to easily
14773// select/click a predefined response or perform an action (like opening
14774// a web uri).
14775type GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestion struct {
14776	// Action: Predefined client side actions that user can choose
14777	Action *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedAction `json:"action,omitempty"`
14778
14779	// Reply: Predefined replies for user to select instead of typing
14780	Reply *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedReply `json:"reply,omitempty"`
14781
14782	// ForceSendFields is a list of field names (e.g. "Action") to
14783	// unconditionally include in API requests. By default, fields with
14784	// empty values are omitted from API requests. However, any non-pointer,
14785	// non-interface field appearing in ForceSendFields will be sent to the
14786	// server regardless of whether the field is empty or not. This may be
14787	// used to include empty fields in Patch requests.
14788	ForceSendFields []string `json:"-"`
14789
14790	// NullFields is a list of field names (e.g. "Action") to include in API
14791	// requests with the JSON null value. By default, fields with empty
14792	// values are omitted from API requests. However, any field with an
14793	// empty value appearing in NullFields will be sent to the server as
14794	// null. It is an error if a field in this list has a non-empty value.
14795	// This may be used to include null fields in Patch requests.
14796	NullFields []string `json:"-"`
14797}
14798
14799func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestion) MarshalJSON() ([]byte, error) {
14800	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestion
14801	raw := NoMethod(*s)
14802	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14803}
14804
14805// GoogleCloudDialogflowV2beta1IntentMessageRbmText: Rich Business
14806// Messaging (RBM) text response with suggestions.
14807type GoogleCloudDialogflowV2beta1IntentMessageRbmText struct {
14808	// RbmSuggestion: Optional. One or more suggestions to show to the user.
14809	RbmSuggestion []*GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestion `json:"rbmSuggestion,omitempty"`
14810
14811	// Text: Required. Text sent and displayed to the user.
14812	Text string `json:"text,omitempty"`
14813
14814	// ForceSendFields is a list of field names (e.g. "RbmSuggestion") to
14815	// unconditionally include in API requests. By default, fields with
14816	// empty values are omitted from API requests. However, any non-pointer,
14817	// non-interface field appearing in ForceSendFields will be sent to the
14818	// server regardless of whether the field is empty or not. This may be
14819	// used to include empty fields in Patch requests.
14820	ForceSendFields []string `json:"-"`
14821
14822	// NullFields is a list of field names (e.g. "RbmSuggestion") to include
14823	// in API requests with the JSON null value. By default, fields with
14824	// empty values are omitted from API requests. However, any field with
14825	// an empty value appearing in NullFields will be sent to the server as
14826	// null. It is an error if a field in this list has a non-empty value.
14827	// This may be used to include null fields in Patch requests.
14828	NullFields []string `json:"-"`
14829}
14830
14831func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmText) MarshalJSON() ([]byte, error) {
14832	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmText
14833	raw := NoMethod(*s)
14834	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14835}
14836
14837// GoogleCloudDialogflowV2beta1IntentMessageSelectItemInfo: Additional
14838// info about the select item for when it is triggered in a dialog.
14839type GoogleCloudDialogflowV2beta1IntentMessageSelectItemInfo struct {
14840	// Key: Required. A unique key that will be sent back to the agent if
14841	// this response is given.
14842	Key string `json:"key,omitempty"`
14843
14844	// Synonyms: Optional. A list of synonyms that can also be used to
14845	// trigger this item in dialog.
14846	Synonyms []string `json:"synonyms,omitempty"`
14847
14848	// ForceSendFields is a list of field names (e.g. "Key") to
14849	// unconditionally include in API requests. By default, fields with
14850	// empty values are omitted from API requests. However, any non-pointer,
14851	// non-interface field appearing in ForceSendFields will be sent to the
14852	// server regardless of whether the field is empty or not. This may be
14853	// used to include empty fields in Patch requests.
14854	ForceSendFields []string `json:"-"`
14855
14856	// NullFields is a list of field names (e.g. "Key") to include in API
14857	// requests with the JSON null value. By default, fields with empty
14858	// values are omitted from API requests. However, any field with an
14859	// empty value appearing in NullFields will be sent to the server as
14860	// null. It is an error if a field in this list has a non-empty value.
14861	// This may be used to include null fields in Patch requests.
14862	NullFields []string `json:"-"`
14863}
14864
14865func (s *GoogleCloudDialogflowV2beta1IntentMessageSelectItemInfo) MarshalJSON() ([]byte, error) {
14866	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageSelectItemInfo
14867	raw := NoMethod(*s)
14868	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14869}
14870
14871// GoogleCloudDialogflowV2beta1IntentMessageSimpleResponse: The simple
14872// response message containing speech or text.
14873type GoogleCloudDialogflowV2beta1IntentMessageSimpleResponse struct {
14874	// DisplayText: Optional. The text to display.
14875	DisplayText string `json:"displayText,omitempty"`
14876
14877	// Ssml: One of text_to_speech or ssml must be provided. Structured
14878	// spoken response to the user in the SSML format. Mutually exclusive
14879	// with text_to_speech.
14880	Ssml string `json:"ssml,omitempty"`
14881
14882	// TextToSpeech: One of text_to_speech or ssml must be provided. The
14883	// plain text of the speech output. Mutually exclusive with ssml.
14884	TextToSpeech string `json:"textToSpeech,omitempty"`
14885
14886	// ForceSendFields is a list of field names (e.g. "DisplayText") to
14887	// unconditionally include in API requests. By default, fields with
14888	// empty values are omitted from API requests. However, any non-pointer,
14889	// non-interface field appearing in ForceSendFields will be sent to the
14890	// server regardless of whether the field is empty or not. This may be
14891	// used to include empty fields in Patch requests.
14892	ForceSendFields []string `json:"-"`
14893
14894	// NullFields is a list of field names (e.g. "DisplayText") to include
14895	// in API requests with the JSON null value. By default, fields with
14896	// empty values are omitted from API requests. However, any field with
14897	// an empty value appearing in NullFields will be sent to the server as
14898	// null. It is an error if a field in this list has a non-empty value.
14899	// This may be used to include null fields in Patch requests.
14900	NullFields []string `json:"-"`
14901}
14902
14903func (s *GoogleCloudDialogflowV2beta1IntentMessageSimpleResponse) MarshalJSON() ([]byte, error) {
14904	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageSimpleResponse
14905	raw := NoMethod(*s)
14906	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14907}
14908
14909// GoogleCloudDialogflowV2beta1IntentMessageSimpleResponses: The
14910// collection of simple response candidates. This message in
14911// `QueryResult.fulfillment_messages` and
14912// `WebhookResponse.fulfillment_messages` should contain only one
14913// `SimpleResponse`.
14914type GoogleCloudDialogflowV2beta1IntentMessageSimpleResponses struct {
14915	// SimpleResponses: Required. The list of simple responses.
14916	SimpleResponses []*GoogleCloudDialogflowV2beta1IntentMessageSimpleResponse `json:"simpleResponses,omitempty"`
14917
14918	// ForceSendFields is a list of field names (e.g. "SimpleResponses") to
14919	// unconditionally include in API requests. By default, fields with
14920	// empty values are omitted from API requests. However, any non-pointer,
14921	// non-interface field appearing in ForceSendFields will be sent to the
14922	// server regardless of whether the field is empty or not. This may be
14923	// used to include empty fields in Patch requests.
14924	ForceSendFields []string `json:"-"`
14925
14926	// NullFields is a list of field names (e.g. "SimpleResponses") to
14927	// include in API requests with the JSON null value. By default, fields
14928	// with empty values are omitted from API requests. However, any field
14929	// with an empty value appearing in NullFields will be sent to the
14930	// server as null. It is an error if a field in this list has a
14931	// non-empty value. This may be used to include null fields in Patch
14932	// requests.
14933	NullFields []string `json:"-"`
14934}
14935
14936func (s *GoogleCloudDialogflowV2beta1IntentMessageSimpleResponses) MarshalJSON() ([]byte, error) {
14937	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageSimpleResponses
14938	raw := NoMethod(*s)
14939	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14940}
14941
14942// GoogleCloudDialogflowV2beta1IntentMessageSuggestion: The suggestion
14943// chip message that the user can tap to quickly post a reply to the
14944// conversation.
14945type GoogleCloudDialogflowV2beta1IntentMessageSuggestion struct {
14946	// Title: Required. The text shown the in the suggestion chip.
14947	Title string `json:"title,omitempty"`
14948
14949	// ForceSendFields is a list of field names (e.g. "Title") to
14950	// unconditionally include in API requests. By default, fields with
14951	// empty values are omitted from API requests. However, any non-pointer,
14952	// non-interface field appearing in ForceSendFields will be sent to the
14953	// server regardless of whether the field is empty or not. This may be
14954	// used to include empty fields in Patch requests.
14955	ForceSendFields []string `json:"-"`
14956
14957	// NullFields is a list of field names (e.g. "Title") to include in API
14958	// requests with the JSON null value. By default, fields with empty
14959	// values are omitted from API requests. However, any field with an
14960	// empty value appearing in NullFields will be sent to the server as
14961	// null. It is an error if a field in this list has a non-empty value.
14962	// This may be used to include null fields in Patch requests.
14963	NullFields []string `json:"-"`
14964}
14965
14966func (s *GoogleCloudDialogflowV2beta1IntentMessageSuggestion) MarshalJSON() ([]byte, error) {
14967	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageSuggestion
14968	raw := NoMethod(*s)
14969	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14970}
14971
14972// GoogleCloudDialogflowV2beta1IntentMessageSuggestions: The collection
14973// of suggestions.
14974type GoogleCloudDialogflowV2beta1IntentMessageSuggestions struct {
14975	// Suggestions: Required. The list of suggested replies.
14976	Suggestions []*GoogleCloudDialogflowV2beta1IntentMessageSuggestion `json:"suggestions,omitempty"`
14977
14978	// ForceSendFields is a list of field names (e.g. "Suggestions") to
14979	// unconditionally include in API requests. By default, fields with
14980	// empty values are omitted from API requests. However, any non-pointer,
14981	// non-interface field appearing in ForceSendFields will be sent to the
14982	// server regardless of whether the field is empty or not. This may be
14983	// used to include empty fields in Patch requests.
14984	ForceSendFields []string `json:"-"`
14985
14986	// NullFields is a list of field names (e.g. "Suggestions") to include
14987	// in API requests with the JSON null value. By default, fields with
14988	// empty values are omitted from API requests. However, any field with
14989	// an empty value appearing in NullFields will be sent to the server as
14990	// null. It is an error if a field in this list has a non-empty value.
14991	// This may be used to include null fields in Patch requests.
14992	NullFields []string `json:"-"`
14993}
14994
14995func (s *GoogleCloudDialogflowV2beta1IntentMessageSuggestions) MarshalJSON() ([]byte, error) {
14996	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageSuggestions
14997	raw := NoMethod(*s)
14998	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14999}
15000
15001// GoogleCloudDialogflowV2beta1IntentMessageTableCard: Table card for
15002// Actions on Google.
15003type GoogleCloudDialogflowV2beta1IntentMessageTableCard struct {
15004	// Buttons: Optional. List of buttons for the card.
15005	Buttons []*GoogleCloudDialogflowV2beta1IntentMessageBasicCardButton `json:"buttons,omitempty"`
15006
15007	// ColumnProperties: Optional. Display properties for the columns in
15008	// this table.
15009	ColumnProperties []*GoogleCloudDialogflowV2beta1IntentMessageColumnProperties `json:"columnProperties,omitempty"`
15010
15011	// Image: Optional. Image which should be displayed on the card.
15012	Image *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"image,omitempty"`
15013
15014	// Rows: Optional. Rows in this table of data.
15015	Rows []*GoogleCloudDialogflowV2beta1IntentMessageTableCardRow `json:"rows,omitempty"`
15016
15017	// Subtitle: Optional. Subtitle to the title.
15018	Subtitle string `json:"subtitle,omitempty"`
15019
15020	// Title: Required. Title of the card.
15021	Title string `json:"title,omitempty"`
15022
15023	// ForceSendFields is a list of field names (e.g. "Buttons") to
15024	// unconditionally include in API requests. By default, fields with
15025	// empty values are omitted from API requests. However, any non-pointer,
15026	// non-interface field appearing in ForceSendFields will be sent to the
15027	// server regardless of whether the field is empty or not. This may be
15028	// used to include empty fields in Patch requests.
15029	ForceSendFields []string `json:"-"`
15030
15031	// NullFields is a list of field names (e.g. "Buttons") to include in
15032	// API requests with the JSON null value. By default, fields with empty
15033	// values are omitted from API requests. However, any field with an
15034	// empty value appearing in NullFields will be sent to the server as
15035	// null. It is an error if a field in this list has a non-empty value.
15036	// This may be used to include null fields in Patch requests.
15037	NullFields []string `json:"-"`
15038}
15039
15040func (s *GoogleCloudDialogflowV2beta1IntentMessageTableCard) MarshalJSON() ([]byte, error) {
15041	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageTableCard
15042	raw := NoMethod(*s)
15043	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15044}
15045
15046// GoogleCloudDialogflowV2beta1IntentMessageTableCardCell: Cell of
15047// TableCardRow.
15048type GoogleCloudDialogflowV2beta1IntentMessageTableCardCell struct {
15049	// Text: Required. Text in this cell.
15050	Text string `json:"text,omitempty"`
15051
15052	// ForceSendFields is a list of field names (e.g. "Text") to
15053	// unconditionally include in API requests. By default, fields with
15054	// empty values are omitted from API requests. However, any non-pointer,
15055	// non-interface field appearing in ForceSendFields will be sent to the
15056	// server regardless of whether the field is empty or not. This may be
15057	// used to include empty fields in Patch requests.
15058	ForceSendFields []string `json:"-"`
15059
15060	// NullFields is a list of field names (e.g. "Text") to include in API
15061	// requests with the JSON null value. By default, fields with empty
15062	// values are omitted from API requests. However, any field with an
15063	// empty value appearing in NullFields will be sent to the server as
15064	// null. It is an error if a field in this list has a non-empty value.
15065	// This may be used to include null fields in Patch requests.
15066	NullFields []string `json:"-"`
15067}
15068
15069func (s *GoogleCloudDialogflowV2beta1IntentMessageTableCardCell) MarshalJSON() ([]byte, error) {
15070	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageTableCardCell
15071	raw := NoMethod(*s)
15072	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15073}
15074
15075// GoogleCloudDialogflowV2beta1IntentMessageTableCardRow: Row of
15076// TableCard.
15077type GoogleCloudDialogflowV2beta1IntentMessageTableCardRow struct {
15078	// Cells: Optional. List of cells that make up this row.
15079	Cells []*GoogleCloudDialogflowV2beta1IntentMessageTableCardCell `json:"cells,omitempty"`
15080
15081	// DividerAfter: Optional. Whether to add a visual divider after this
15082	// row.
15083	DividerAfter bool `json:"dividerAfter,omitempty"`
15084
15085	// ForceSendFields is a list of field names (e.g. "Cells") to
15086	// unconditionally include in API requests. By default, fields with
15087	// empty values are omitted from API requests. However, any non-pointer,
15088	// non-interface field appearing in ForceSendFields will be sent to the
15089	// server regardless of whether the field is empty or not. This may be
15090	// used to include empty fields in Patch requests.
15091	ForceSendFields []string `json:"-"`
15092
15093	// NullFields is a list of field names (e.g. "Cells") to include in API
15094	// requests with the JSON null value. By default, fields with empty
15095	// values are omitted from API requests. However, any field with an
15096	// empty value appearing in NullFields will be sent to the server as
15097	// null. It is an error if a field in this list has a non-empty value.
15098	// This may be used to include null fields in Patch requests.
15099	NullFields []string `json:"-"`
15100}
15101
15102func (s *GoogleCloudDialogflowV2beta1IntentMessageTableCardRow) MarshalJSON() ([]byte, error) {
15103	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageTableCardRow
15104	raw := NoMethod(*s)
15105	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15106}
15107
15108// GoogleCloudDialogflowV2beta1IntentMessageTelephonyPlayAudio: Plays
15109// audio from a file in Telephony Gateway.
15110type GoogleCloudDialogflowV2beta1IntentMessageTelephonyPlayAudio struct {
15111	// AudioUri: Required. URI to a Google Cloud Storage object containing
15112	// the audio to play, e.g., "gs://bucket/object". The object must
15113	// contain a single channel (mono) of linear PCM audio (2 bytes /
15114	// sample) at 8kHz. This object must be readable by the
15115	// `service-@gcp-sa-dialogflow.iam.gserviceaccount.com` service account
15116	// where is the number of the Telephony Gateway project (usually the
15117	// same as the Dialogflow agent project). If the Google Cloud Storage
15118	// bucket is in the Telephony Gateway project, this permission is added
15119	// by default when enabling the Dialogflow V2 API. For audio from other
15120	// sources, consider using the `TelephonySynthesizeSpeech` message with
15121	// SSML.
15122	AudioUri string `json:"audioUri,omitempty"`
15123
15124	// ForceSendFields is a list of field names (e.g. "AudioUri") to
15125	// unconditionally include in API requests. By default, fields with
15126	// empty values are omitted from API requests. However, any non-pointer,
15127	// non-interface field appearing in ForceSendFields will be sent to the
15128	// server regardless of whether the field is empty or not. This may be
15129	// used to include empty fields in Patch requests.
15130	ForceSendFields []string `json:"-"`
15131
15132	// NullFields is a list of field names (e.g. "AudioUri") to include in
15133	// API requests with the JSON null value. By default, fields with empty
15134	// values are omitted from API requests. However, any field with an
15135	// empty value appearing in NullFields will be sent to the server as
15136	// null. It is an error if a field in this list has a non-empty value.
15137	// This may be used to include null fields in Patch requests.
15138	NullFields []string `json:"-"`
15139}
15140
15141func (s *GoogleCloudDialogflowV2beta1IntentMessageTelephonyPlayAudio) MarshalJSON() ([]byte, error) {
15142	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageTelephonyPlayAudio
15143	raw := NoMethod(*s)
15144	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15145}
15146
15147// GoogleCloudDialogflowV2beta1IntentMessageTelephonySynthesizeSpeech:
15148// Synthesizes speech and plays back the synthesized audio to the caller
15149// in Telephony Gateway. Telephony Gateway takes the synthesizer
15150// settings from `DetectIntentResponse.output_audio_config` which can
15151// either be set at request-level or can come from the agent-level
15152// synthesizer config.
15153type GoogleCloudDialogflowV2beta1IntentMessageTelephonySynthesizeSpeech struct {
15154	// Ssml: The SSML to be synthesized. For more information, see SSML
15155	// (https://developers.google.com/actions/reference/ssml).
15156	Ssml string `json:"ssml,omitempty"`
15157
15158	// Text: The raw text to be synthesized.
15159	Text string `json:"text,omitempty"`
15160
15161	// ForceSendFields is a list of field names (e.g. "Ssml") to
15162	// unconditionally include in API requests. By default, fields with
15163	// empty values are omitted from API requests. However, any non-pointer,
15164	// non-interface field appearing in ForceSendFields will be sent to the
15165	// server regardless of whether the field is empty or not. This may be
15166	// used to include empty fields in Patch requests.
15167	ForceSendFields []string `json:"-"`
15168
15169	// NullFields is a list of field names (e.g. "Ssml") to include in API
15170	// requests with the JSON null value. By default, fields with empty
15171	// values are omitted from API requests. However, any field with an
15172	// empty value appearing in NullFields will be sent to the server as
15173	// null. It is an error if a field in this list has a non-empty value.
15174	// This may be used to include null fields in Patch requests.
15175	NullFields []string `json:"-"`
15176}
15177
15178func (s *GoogleCloudDialogflowV2beta1IntentMessageTelephonySynthesizeSpeech) MarshalJSON() ([]byte, error) {
15179	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageTelephonySynthesizeSpeech
15180	raw := NoMethod(*s)
15181	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15182}
15183
15184// GoogleCloudDialogflowV2beta1IntentMessageTelephonyTransferCall:
15185// Transfers the call in Telephony Gateway.
15186type GoogleCloudDialogflowV2beta1IntentMessageTelephonyTransferCall struct {
15187	// PhoneNumber: Required. The phone number to transfer the call to in
15188	// E.164 format (https://en.wikipedia.org/wiki/E.164). We currently only
15189	// allow transferring to US numbers (+1xxxyyyzzzz).
15190	PhoneNumber string `json:"phoneNumber,omitempty"`
15191
15192	// ForceSendFields is a list of field names (e.g. "PhoneNumber") to
15193	// unconditionally include in API requests. By default, fields with
15194	// empty values are omitted from API requests. However, any non-pointer,
15195	// non-interface field appearing in ForceSendFields will be sent to the
15196	// server regardless of whether the field is empty or not. This may be
15197	// used to include empty fields in Patch requests.
15198	ForceSendFields []string `json:"-"`
15199
15200	// NullFields is a list of field names (e.g. "PhoneNumber") to include
15201	// in API requests with the JSON null value. By default, fields with
15202	// empty values are omitted from API requests. However, any field with
15203	// an empty value appearing in NullFields will be sent to the server as
15204	// null. It is an error if a field in this list has a non-empty value.
15205	// This may be used to include null fields in Patch requests.
15206	NullFields []string `json:"-"`
15207}
15208
15209func (s *GoogleCloudDialogflowV2beta1IntentMessageTelephonyTransferCall) MarshalJSON() ([]byte, error) {
15210	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageTelephonyTransferCall
15211	raw := NoMethod(*s)
15212	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15213}
15214
15215// GoogleCloudDialogflowV2beta1IntentMessageText: The text response
15216// message.
15217type GoogleCloudDialogflowV2beta1IntentMessageText struct {
15218	// Text: Optional. The collection of the agent's responses.
15219	Text []string `json:"text,omitempty"`
15220
15221	// ForceSendFields is a list of field names (e.g. "Text") to
15222	// unconditionally include in API requests. By default, fields with
15223	// empty values are omitted from API requests. However, any non-pointer,
15224	// non-interface field appearing in ForceSendFields will be sent to the
15225	// server regardless of whether the field is empty or not. This may be
15226	// used to include empty fields in Patch requests.
15227	ForceSendFields []string `json:"-"`
15228
15229	// NullFields is a list of field names (e.g. "Text") to include in API
15230	// requests with the JSON null value. By default, fields with empty
15231	// values are omitted from API requests. However, any field with an
15232	// empty value appearing in NullFields will be sent to the server as
15233	// null. It is an error if a field in this list has a non-empty value.
15234	// This may be used to include null fields in Patch requests.
15235	NullFields []string `json:"-"`
15236}
15237
15238func (s *GoogleCloudDialogflowV2beta1IntentMessageText) MarshalJSON() ([]byte, error) {
15239	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageText
15240	raw := NoMethod(*s)
15241	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15242}
15243
15244// GoogleCloudDialogflowV2beta1IntentParameter: Represents intent
15245// parameters.
15246type GoogleCloudDialogflowV2beta1IntentParameter struct {
15247	// DefaultValue: Optional. The default value to use when the `value`
15248	// yields an empty result. Default values can be extracted from contexts
15249	// by using the following syntax: `#context_name.parameter_name`.
15250	DefaultValue string `json:"defaultValue,omitempty"`
15251
15252	// DisplayName: Required. The name of the parameter.
15253	DisplayName string `json:"displayName,omitempty"`
15254
15255	// EntityTypeDisplayName: Optional. The name of the entity type,
15256	// prefixed with `@`, that describes values of the parameter. If the
15257	// parameter is required, this must be provided.
15258	EntityTypeDisplayName string `json:"entityTypeDisplayName,omitempty"`
15259
15260	// IsList: Optional. Indicates whether the parameter represents a list
15261	// of values.
15262	IsList bool `json:"isList,omitempty"`
15263
15264	// Mandatory: Optional. Indicates whether the parameter is required.
15265	// That is, whether the intent cannot be completed without collecting
15266	// the parameter value.
15267	Mandatory bool `json:"mandatory,omitempty"`
15268
15269	// Name: The unique identifier of this parameter.
15270	Name string `json:"name,omitempty"`
15271
15272	// Prompts: Optional. The collection of prompts that the agent can
15273	// present to the user in order to collect a value for the parameter.
15274	Prompts []string `json:"prompts,omitempty"`
15275
15276	// Value: Optional. The definition of the parameter value. It can be: -
15277	// a constant string, - a parameter value defined as `$parameter_name`,
15278	// - an original parameter value defined as `$parameter_name.original`,
15279	// - a parameter value from some context defined as
15280	// `#context_name.parameter_name`.
15281	Value string `json:"value,omitempty"`
15282
15283	// ForceSendFields is a list of field names (e.g. "DefaultValue") to
15284	// unconditionally include in API requests. By default, fields with
15285	// empty values are omitted from API requests. However, any non-pointer,
15286	// non-interface field appearing in ForceSendFields will be sent to the
15287	// server regardless of whether the field is empty or not. This may be
15288	// used to include empty fields in Patch requests.
15289	ForceSendFields []string `json:"-"`
15290
15291	// NullFields is a list of field names (e.g. "DefaultValue") to include
15292	// in API requests with the JSON null value. By default, fields with
15293	// empty values are omitted from API requests. However, any field with
15294	// an empty value appearing in NullFields will be sent to the server as
15295	// null. It is an error if a field in this list has a non-empty value.
15296	// This may be used to include null fields in Patch requests.
15297	NullFields []string `json:"-"`
15298}
15299
15300func (s *GoogleCloudDialogflowV2beta1IntentParameter) MarshalJSON() ([]byte, error) {
15301	type NoMethod GoogleCloudDialogflowV2beta1IntentParameter
15302	raw := NoMethod(*s)
15303	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15304}
15305
15306// GoogleCloudDialogflowV2beta1IntentTrainingPhrase: Represents an
15307// example that the agent is trained on.
15308type GoogleCloudDialogflowV2beta1IntentTrainingPhrase struct {
15309	// Name: Output only. The unique identifier of this training phrase.
15310	Name string `json:"name,omitempty"`
15311
15312	// Parts: Required. The ordered list of training phrase parts. The parts
15313	// are concatenated in order to form the training phrase. Note: The API
15314	// does not automatically annotate training phrases like the Dialogflow
15315	// Console does. Note: Do not forget to include whitespace at part
15316	// boundaries, so the training phrase is well formatted when the parts
15317	// are concatenated. If the training phrase does not need to be
15318	// annotated with parameters, you just need a single part with only the
15319	// Part.text field set. If you want to annotate the training phrase, you
15320	// must create multiple parts, where the fields of each part are
15321	// populated in one of two ways: - `Part.text` is set to a part of the
15322	// phrase that has no parameters. - `Part.text` is set to a part of the
15323	// phrase that you want to annotate, and the `entity_type`, `alias`, and
15324	// `user_defined` fields are all set.
15325	Parts []*GoogleCloudDialogflowV2beta1IntentTrainingPhrasePart `json:"parts,omitempty"`
15326
15327	// TimesAddedCount: Optional. Indicates how many times this example was
15328	// added to the intent. Each time a developer adds an existing sample by
15329	// editing an intent or training, this counter is increased.
15330	TimesAddedCount int64 `json:"timesAddedCount,omitempty"`
15331
15332	// Type: Required. The type of the training phrase.
15333	//
15334	// Possible values:
15335	//   "TYPE_UNSPECIFIED" - Not specified. This value should never be
15336	// used.
15337	//   "EXAMPLE" - Examples do not contain @-prefixed entity type names,
15338	// but example parts can be annotated with entity types.
15339	//   "TEMPLATE" - Templates are not annotated with entity types, but
15340	// they can contain @-prefixed entity type names as substrings. Template
15341	// mode has been deprecated. Example mode is the only supported way to
15342	// create new training phrases. If you have existing training phrases
15343	// that you've created in template mode, those will continue to work.
15344	Type string `json:"type,omitempty"`
15345
15346	// ForceSendFields is a list of field names (e.g. "Name") to
15347	// unconditionally include in API requests. By default, fields with
15348	// empty values are omitted from API requests. However, any non-pointer,
15349	// non-interface field appearing in ForceSendFields will be sent to the
15350	// server regardless of whether the field is empty or not. This may be
15351	// used to include empty fields in Patch requests.
15352	ForceSendFields []string `json:"-"`
15353
15354	// NullFields is a list of field names (e.g. "Name") to include in API
15355	// requests with the JSON null value. By default, fields with empty
15356	// values are omitted from API requests. However, any field with an
15357	// empty value appearing in NullFields will be sent to the server as
15358	// null. It is an error if a field in this list has a non-empty value.
15359	// This may be used to include null fields in Patch requests.
15360	NullFields []string `json:"-"`
15361}
15362
15363func (s *GoogleCloudDialogflowV2beta1IntentTrainingPhrase) MarshalJSON() ([]byte, error) {
15364	type NoMethod GoogleCloudDialogflowV2beta1IntentTrainingPhrase
15365	raw := NoMethod(*s)
15366	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15367}
15368
15369// GoogleCloudDialogflowV2beta1IntentTrainingPhrasePart: Represents a
15370// part of a training phrase.
15371type GoogleCloudDialogflowV2beta1IntentTrainingPhrasePart struct {
15372	// Alias: Optional. The parameter name for the value extracted from the
15373	// annotated part of the example. This field is required for annotated
15374	// parts of the training phrase.
15375	Alias string `json:"alias,omitempty"`
15376
15377	// EntityType: Optional. The entity type name prefixed with `@`. This
15378	// field is required for annotated parts of the training phrase.
15379	EntityType string `json:"entityType,omitempty"`
15380
15381	// Text: Required. The text for this part.
15382	Text string `json:"text,omitempty"`
15383
15384	// UserDefined: Optional. Indicates whether the text was manually
15385	// annotated. This field is set to true when the Dialogflow Console is
15386	// used to manually annotate the part. When creating an annotated part
15387	// with the API, you must set this to true.
15388	UserDefined bool `json:"userDefined,omitempty"`
15389
15390	// ForceSendFields is a list of field names (e.g. "Alias") to
15391	// unconditionally include in API requests. By default, fields with
15392	// empty values are omitted from API requests. However, any non-pointer,
15393	// non-interface field appearing in ForceSendFields will be sent to the
15394	// server regardless of whether the field is empty or not. This may be
15395	// used to include empty fields in Patch requests.
15396	ForceSendFields []string `json:"-"`
15397
15398	// NullFields is a list of field names (e.g. "Alias") to include in API
15399	// requests with the JSON null value. By default, fields with empty
15400	// values are omitted from API requests. However, any field with an
15401	// empty value appearing in NullFields will be sent to the server as
15402	// null. It is an error if a field in this list has a non-empty value.
15403	// This may be used to include null fields in Patch requests.
15404	NullFields []string `json:"-"`
15405}
15406
15407func (s *GoogleCloudDialogflowV2beta1IntentTrainingPhrasePart) MarshalJSON() ([]byte, error) {
15408	type NoMethod GoogleCloudDialogflowV2beta1IntentTrainingPhrasePart
15409	raw := NoMethod(*s)
15410	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15411}
15412
15413// GoogleCloudDialogflowV2beta1KnowledgeAnswers: Represents the result
15414// of querying a Knowledge base.
15415type GoogleCloudDialogflowV2beta1KnowledgeAnswers struct {
15416	// Answers: A list of answers from Knowledge Connector.
15417	Answers []*GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer `json:"answers,omitempty"`
15418
15419	// ForceSendFields is a list of field names (e.g. "Answers") to
15420	// unconditionally include in API requests. By default, fields with
15421	// empty values are omitted from API requests. However, any non-pointer,
15422	// non-interface field appearing in ForceSendFields will be sent to the
15423	// server regardless of whether the field is empty or not. This may be
15424	// used to include empty fields in Patch requests.
15425	ForceSendFields []string `json:"-"`
15426
15427	// NullFields is a list of field names (e.g. "Answers") to include in
15428	// API requests with the JSON null value. By default, fields with empty
15429	// values are omitted from API requests. However, any field with an
15430	// empty value appearing in NullFields will be sent to the server as
15431	// null. It is an error if a field in this list has a non-empty value.
15432	// This may be used to include null fields in Patch requests.
15433	NullFields []string `json:"-"`
15434}
15435
15436func (s *GoogleCloudDialogflowV2beta1KnowledgeAnswers) MarshalJSON() ([]byte, error) {
15437	type NoMethod GoogleCloudDialogflowV2beta1KnowledgeAnswers
15438	raw := NoMethod(*s)
15439	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15440}
15441
15442// GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer: An answer from
15443// Knowledge Connector.
15444type GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer struct {
15445	// Answer: The piece of text from the `source` knowledge base document
15446	// that answers this conversational query.
15447	Answer string `json:"answer,omitempty"`
15448
15449	// FaqQuestion: The corresponding FAQ question if the answer was
15450	// extracted from a FAQ Document, empty otherwise.
15451	FaqQuestion string `json:"faqQuestion,omitempty"`
15452
15453	// MatchConfidence: The system's confidence score that this Knowledge
15454	// answer is a good match for this conversational query. The range is
15455	// from 0.0 (completely uncertain) to 1.0 (completely certain). Note:
15456	// The confidence score is likely to vary somewhat (possibly even for
15457	// identical requests), as the underlying model is under constant
15458	// improvement. It may be deprecated in the future. We recommend using
15459	// `match_confidence_level` which should be generally more stable.
15460	MatchConfidence float64 `json:"matchConfidence,omitempty"`
15461
15462	// MatchConfidenceLevel: The system's confidence level that this
15463	// knowledge answer is a good match for this conversational query. NOTE:
15464	// The confidence level for a given `` pair may change without notice,
15465	// as it depends on models that are constantly being improved. However,
15466	// it will change less frequently than the confidence score below, and
15467	// should be preferred for referencing the quality of an answer.
15468	//
15469	// Possible values:
15470	//   "MATCH_CONFIDENCE_LEVEL_UNSPECIFIED" - Not specified.
15471	//   "LOW" - Indicates that the confidence is low.
15472	//   "MEDIUM" - Indicates our confidence is medium.
15473	//   "HIGH" - Indicates our confidence is high.
15474	MatchConfidenceLevel string `json:"matchConfidenceLevel,omitempty"`
15475
15476	// Source: Indicates which Knowledge Document this answer was extracted
15477	// from. Format: `projects//knowledgeBases//documents/`.
15478	Source string `json:"source,omitempty"`
15479
15480	// ForceSendFields is a list of field names (e.g. "Answer") to
15481	// unconditionally include in API requests. By default, fields with
15482	// empty values are omitted from API requests. However, any non-pointer,
15483	// non-interface field appearing in ForceSendFields will be sent to the
15484	// server regardless of whether the field is empty or not. This may be
15485	// used to include empty fields in Patch requests.
15486	ForceSendFields []string `json:"-"`
15487
15488	// NullFields is a list of field names (e.g. "Answer") to include in API
15489	// requests with the JSON null value. By default, fields with empty
15490	// values are omitted from API requests. However, any field with an
15491	// empty value appearing in NullFields will be sent to the server as
15492	// null. It is an error if a field in this list has a non-empty value.
15493	// This may be used to include null fields in Patch requests.
15494	NullFields []string `json:"-"`
15495}
15496
15497func (s *GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer) MarshalJSON() ([]byte, error) {
15498	type NoMethod GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer
15499	raw := NoMethod(*s)
15500	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15501}
15502
15503func (s *GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer) UnmarshalJSON(data []byte) error {
15504	type NoMethod GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer
15505	var s1 struct {
15506		MatchConfidence gensupport.JSONFloat64 `json:"matchConfidence"`
15507		*NoMethod
15508	}
15509	s1.NoMethod = (*NoMethod)(s)
15510	if err := json.Unmarshal(data, &s1); err != nil {
15511		return err
15512	}
15513	s.MatchConfidence = float64(s1.MatchConfidence)
15514	return nil
15515}
15516
15517// GoogleCloudDialogflowV2beta1KnowledgeOperationMetadata: Metadata in
15518// google::longrunning::Operation for Knowledge operations.
15519type GoogleCloudDialogflowV2beta1KnowledgeOperationMetadata struct {
15520	// State: Required. Output only. The current state of this operation.
15521	//
15522	// Possible values:
15523	//   "STATE_UNSPECIFIED" - State unspecified.
15524	//   "PENDING" - The operation has been created.
15525	//   "RUNNING" - The operation is currently running.
15526	//   "DONE" - The operation is done, either cancelled or completed.
15527	State string `json:"state,omitempty"`
15528
15529	// ForceSendFields is a list of field names (e.g. "State") to
15530	// unconditionally include in API requests. By default, fields with
15531	// empty values are omitted from API requests. However, any non-pointer,
15532	// non-interface field appearing in ForceSendFields will be sent to the
15533	// server regardless of whether the field is empty or not. This may be
15534	// used to include empty fields in Patch requests.
15535	ForceSendFields []string `json:"-"`
15536
15537	// NullFields is a list of field names (e.g. "State") to include in API
15538	// requests with the JSON null value. By default, fields with empty
15539	// values are omitted from API requests. However, any field with an
15540	// empty value appearing in NullFields will be sent to the server as
15541	// null. It is an error if a field in this list has a non-empty value.
15542	// This may be used to include null fields in Patch requests.
15543	NullFields []string `json:"-"`
15544}
15545
15546func (s *GoogleCloudDialogflowV2beta1KnowledgeOperationMetadata) MarshalJSON() ([]byte, error) {
15547	type NoMethod GoogleCloudDialogflowV2beta1KnowledgeOperationMetadata
15548	raw := NoMethod(*s)
15549	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15550}
15551
15552// GoogleCloudDialogflowV2beta1Message: Represents a message posted into
15553// a conversation.
15554type GoogleCloudDialogflowV2beta1Message struct {
15555	// Content: Required. The message content.
15556	Content string `json:"content,omitempty"`
15557
15558	// CreateTime: Output only. The time when the message was created in
15559	// Contact Center AI.
15560	CreateTime string `json:"createTime,omitempty"`
15561
15562	// LanguageCode: Optional. The message language. This should be a BCP-47
15563	// (https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. Example:
15564	// "en-US".
15565	LanguageCode string `json:"languageCode,omitempty"`
15566
15567	// MessageAnnotation: Output only. The annotation for the message.
15568	MessageAnnotation *GoogleCloudDialogflowV2beta1MessageAnnotation `json:"messageAnnotation,omitempty"`
15569
15570	// Name: Optional. The unique identifier of the message. Format:
15571	// `projects//locations//conversations//messages/`.
15572	Name string `json:"name,omitempty"`
15573
15574	// Participant: Output only. The participant that sends this message.
15575	Participant string `json:"participant,omitempty"`
15576
15577	// ParticipantRole: Output only. The role of the participant.
15578	//
15579	// Possible values:
15580	//   "ROLE_UNSPECIFIED" - Participant role not set.
15581	//   "HUMAN_AGENT" - Participant is a human agent.
15582	//   "AUTOMATED_AGENT" - Participant is an automated agent, such as a
15583	// Dialogflow agent.
15584	//   "END_USER" - Participant is an end user that has called or chatted
15585	// with Dialogflow services.
15586	ParticipantRole string `json:"participantRole,omitempty"`
15587
15588	// SendTime: Optional. The time when the message was sent.
15589	SendTime string `json:"sendTime,omitempty"`
15590
15591	// SentimentAnalysis: Output only. The sentiment analysis result for the
15592	// message.
15593	SentimentAnalysis *GoogleCloudDialogflowV2beta1SentimentAnalysisResult `json:"sentimentAnalysis,omitempty"`
15594
15595	// ForceSendFields is a list of field names (e.g. "Content") to
15596	// unconditionally include in API requests. By default, fields with
15597	// empty values are omitted from API requests. However, any non-pointer,
15598	// non-interface field appearing in ForceSendFields will be sent to the
15599	// server regardless of whether the field is empty or not. This may be
15600	// used to include empty fields in Patch requests.
15601	ForceSendFields []string `json:"-"`
15602
15603	// NullFields is a list of field names (e.g. "Content") to include in
15604	// API requests with the JSON null value. By default, fields with empty
15605	// values are omitted from API requests. However, any field with an
15606	// empty value appearing in NullFields will be sent to the server as
15607	// null. It is an error if a field in this list has a non-empty value.
15608	// This may be used to include null fields in Patch requests.
15609	NullFields []string `json:"-"`
15610}
15611
15612func (s *GoogleCloudDialogflowV2beta1Message) MarshalJSON() ([]byte, error) {
15613	type NoMethod GoogleCloudDialogflowV2beta1Message
15614	raw := NoMethod(*s)
15615	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15616}
15617
15618// GoogleCloudDialogflowV2beta1MessageAnnotation: Represents the result
15619// of annotation for the message.
15620type GoogleCloudDialogflowV2beta1MessageAnnotation struct {
15621	// ContainEntities: Required. Indicates whether the text message
15622	// contains entities.
15623	ContainEntities bool `json:"containEntities,omitempty"`
15624
15625	// Parts: Optional. The collection of annotated message parts ordered by
15626	// their position in the message. You can recover the annotated message
15627	// by concatenating [AnnotatedMessagePart.text].
15628	Parts []*GoogleCloudDialogflowV2beta1AnnotatedMessagePart `json:"parts,omitempty"`
15629
15630	// ForceSendFields is a list of field names (e.g. "ContainEntities") to
15631	// unconditionally include in API requests. By default, fields with
15632	// empty values are omitted from API requests. However, any non-pointer,
15633	// non-interface field appearing in ForceSendFields will be sent to the
15634	// server regardless of whether the field is empty or not. This may be
15635	// used to include empty fields in Patch requests.
15636	ForceSendFields []string `json:"-"`
15637
15638	// NullFields is a list of field names (e.g. "ContainEntities") to
15639	// include in API requests with the JSON null value. By default, fields
15640	// with empty values are omitted from API requests. However, any field
15641	// with an empty value appearing in NullFields will be sent to the
15642	// server as null. It is an error if a field in this list has a
15643	// non-empty value. This may be used to include null fields in Patch
15644	// requests.
15645	NullFields []string `json:"-"`
15646}
15647
15648func (s *GoogleCloudDialogflowV2beta1MessageAnnotation) MarshalJSON() ([]byte, error) {
15649	type NoMethod GoogleCloudDialogflowV2beta1MessageAnnotation
15650	raw := NoMethod(*s)
15651	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15652}
15653
15654// GoogleCloudDialogflowV2beta1OriginalDetectIntentRequest: Represents
15655// the contents of the original request that was passed to the
15656// `[Streaming]DetectIntent` call.
15657type GoogleCloudDialogflowV2beta1OriginalDetectIntentRequest struct {
15658	// Payload: Optional. This field is set to the value of the
15659	// `QueryParameters.payload` field passed in the request. Some
15660	// integrations that query a Dialogflow agent may provide additional
15661	// information in the payload. In particular, for the Dialogflow Phone
15662	// Gateway integration, this field has the form: { "telephony": {
15663	// "caller_id": "+18558363987" } } Note: The caller ID field
15664	// (`caller_id`) will be redacted for Trial Edition agents and populated
15665	// with the caller ID in E.164 format
15666	// (https://en.wikipedia.org/wiki/E.164) for Essentials Edition agents.
15667	Payload googleapi.RawMessage `json:"payload,omitempty"`
15668
15669	// Source: The source of this request, e.g., `google`, `facebook`,
15670	// `slack`. It is set by Dialogflow-owned servers.
15671	Source string `json:"source,omitempty"`
15672
15673	// Version: Optional. The version of the protocol used for this request.
15674	// This field is AoG-specific.
15675	Version string `json:"version,omitempty"`
15676
15677	// ForceSendFields is a list of field names (e.g. "Payload") to
15678	// unconditionally include in API requests. By default, fields with
15679	// empty values are omitted from API requests. However, any non-pointer,
15680	// non-interface field appearing in ForceSendFields will be sent to the
15681	// server regardless of whether the field is empty or not. This may be
15682	// used to include empty fields in Patch requests.
15683	ForceSendFields []string `json:"-"`
15684
15685	// NullFields is a list of field names (e.g. "Payload") to include in
15686	// API requests with the JSON null value. By default, fields with empty
15687	// values are omitted from API requests. However, any field with an
15688	// empty value appearing in NullFields will be sent to the server as
15689	// null. It is an error if a field in this list has a non-empty value.
15690	// This may be used to include null fields in Patch requests.
15691	NullFields []string `json:"-"`
15692}
15693
15694func (s *GoogleCloudDialogflowV2beta1OriginalDetectIntentRequest) MarshalJSON() ([]byte, error) {
15695	type NoMethod GoogleCloudDialogflowV2beta1OriginalDetectIntentRequest
15696	raw := NoMethod(*s)
15697	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15698}
15699
15700// GoogleCloudDialogflowV2beta1QueryResult: Represents the result of
15701// conversational query or event processing.
15702type GoogleCloudDialogflowV2beta1QueryResult struct {
15703	// Action: The action name from the matched intent.
15704	Action string `json:"action,omitempty"`
15705
15706	// AllRequiredParamsPresent: This field is set to: - `false` if the
15707	// matched intent has required parameters and not all of the required
15708	// parameter values have been collected. - `true` if all required
15709	// parameter values have been collected, or if the matched intent
15710	// doesn't contain any required parameters.
15711	AllRequiredParamsPresent bool `json:"allRequiredParamsPresent,omitempty"`
15712
15713	// DiagnosticInfo: Free-form diagnostic information for the associated
15714	// detect intent request. The fields of this data can change without
15715	// notice, so you should not write code that depends on its structure.
15716	// The data may contain: - webhook call latency - webhook errors
15717	DiagnosticInfo googleapi.RawMessage `json:"diagnosticInfo,omitempty"`
15718
15719	// FulfillmentMessages: The collection of rich messages to present to
15720	// the user.
15721	FulfillmentMessages []*GoogleCloudDialogflowV2beta1IntentMessage `json:"fulfillmentMessages,omitempty"`
15722
15723	// FulfillmentText: The text to be pronounced to the user or shown on
15724	// the screen. Note: This is a legacy field, `fulfillment_messages`
15725	// should be preferred.
15726	FulfillmentText string `json:"fulfillmentText,omitempty"`
15727
15728	// Intent: The intent that matched the conversational query. Some, not
15729	// all fields are filled in this message, including but not limited to:
15730	// `name`, `display_name`, `end_interaction` and `is_fallback`.
15731	Intent *GoogleCloudDialogflowV2beta1Intent `json:"intent,omitempty"`
15732
15733	// IntentDetectionConfidence: The intent detection confidence. Values
15734	// range from 0.0 (completely uncertain) to 1.0 (completely certain).
15735	// This value is for informational purpose only and is only used to help
15736	// match the best intent within the classification threshold. This value
15737	// may change for the same end-user expression at any time due to a
15738	// model retraining or change in implementation. If there are `multiple
15739	// knowledge_answers` messages, this value is set to the greatest
15740	// `knowledgeAnswers.match_confidence` value in the list.
15741	IntentDetectionConfidence float64 `json:"intentDetectionConfidence,omitempty"`
15742
15743	// KnowledgeAnswers: The result from Knowledge Connector (if any),
15744	// ordered by decreasing `KnowledgeAnswers.match_confidence`.
15745	KnowledgeAnswers *GoogleCloudDialogflowV2beta1KnowledgeAnswers `json:"knowledgeAnswers,omitempty"`
15746
15747	// LanguageCode: The language that was triggered during intent
15748	// detection. See Language Support
15749	// (https://cloud.google.com/dialogflow/docs/reference/language) for a
15750	// list of the currently supported language codes.
15751	LanguageCode string `json:"languageCode,omitempty"`
15752
15753	// OutputContexts: The collection of output contexts. If applicable,
15754	// `output_contexts.parameters` contains entries with name `.original`
15755	// containing the original parameter values before the query.
15756	OutputContexts []*GoogleCloudDialogflowV2beta1Context `json:"outputContexts,omitempty"`
15757
15758	// Parameters: The collection of extracted parameters. Depending on your
15759	// protocol or client library language, this is a map, associative
15760	// array, symbol table, dictionary, or JSON object composed of a
15761	// collection of (MapKey, MapValue) pairs: - MapKey type: string -
15762	// MapKey value: parameter name - MapValue type: - If parameter's entity
15763	// type is a composite entity: map - Else: depending on parameter value
15764	// type, could be one of string, number, boolean, null, list or map -
15765	// MapValue value: - If parameter's entity type is a composite entity:
15766	// map from composite entity property names to property values - Else:
15767	// parameter value
15768	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
15769
15770	// QueryText: The original conversational query text: - If natural
15771	// language text was provided as input, `query_text` contains a copy of
15772	// the input. - If natural language speech audio was provided as input,
15773	// `query_text` contains the speech recognition result. If speech
15774	// recognizer produced multiple alternatives, a particular one is
15775	// picked. - If automatic spell correction is enabled, `query_text` will
15776	// contain the corrected user input.
15777	QueryText string `json:"queryText,omitempty"`
15778
15779	// SentimentAnalysisResult: The sentiment analysis result, which depends
15780	// on the `sentiment_analysis_request_config` specified in the request.
15781	SentimentAnalysisResult *GoogleCloudDialogflowV2beta1SentimentAnalysisResult `json:"sentimentAnalysisResult,omitempty"`
15782
15783	// SpeechRecognitionConfidence: The Speech recognition confidence
15784	// between 0.0 and 1.0. A higher number indicates an estimated greater
15785	// likelihood that the recognized words are correct. The default of 0.0
15786	// is a sentinel value indicating that confidence was not set. This
15787	// field is not guaranteed to be accurate or set. In particular this
15788	// field isn't set for StreamingDetectIntent since the streaming
15789	// endpoint has separate confidence estimates per portion of the audio
15790	// in StreamingRecognitionResult.
15791	SpeechRecognitionConfidence float64 `json:"speechRecognitionConfidence,omitempty"`
15792
15793	// WebhookPayload: If the query was fulfilled by a webhook call, this
15794	// field is set to the value of the `payload` field returned in the
15795	// webhook response.
15796	WebhookPayload googleapi.RawMessage `json:"webhookPayload,omitempty"`
15797
15798	// WebhookSource: If the query was fulfilled by a webhook call, this
15799	// field is set to the value of the `source` field returned in the
15800	// webhook response.
15801	WebhookSource string `json:"webhookSource,omitempty"`
15802
15803	// ForceSendFields is a list of field names (e.g. "Action") to
15804	// unconditionally include in API requests. By default, fields with
15805	// empty values are omitted from API requests. However, any non-pointer,
15806	// non-interface field appearing in ForceSendFields will be sent to the
15807	// server regardless of whether the field is empty or not. This may be
15808	// used to include empty fields in Patch requests.
15809	ForceSendFields []string `json:"-"`
15810
15811	// NullFields is a list of field names (e.g. "Action") to include in API
15812	// requests with the JSON null value. By default, fields with empty
15813	// values are omitted from API requests. However, any field with an
15814	// empty value appearing in NullFields will be sent to the server as
15815	// null. It is an error if a field in this list has a non-empty value.
15816	// This may be used to include null fields in Patch requests.
15817	NullFields []string `json:"-"`
15818}
15819
15820func (s *GoogleCloudDialogflowV2beta1QueryResult) MarshalJSON() ([]byte, error) {
15821	type NoMethod GoogleCloudDialogflowV2beta1QueryResult
15822	raw := NoMethod(*s)
15823	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15824}
15825
15826func (s *GoogleCloudDialogflowV2beta1QueryResult) UnmarshalJSON(data []byte) error {
15827	type NoMethod GoogleCloudDialogflowV2beta1QueryResult
15828	var s1 struct {
15829		IntentDetectionConfidence   gensupport.JSONFloat64 `json:"intentDetectionConfidence"`
15830		SpeechRecognitionConfidence gensupport.JSONFloat64 `json:"speechRecognitionConfidence"`
15831		*NoMethod
15832	}
15833	s1.NoMethod = (*NoMethod)(s)
15834	if err := json.Unmarshal(data, &s1); err != nil {
15835		return err
15836	}
15837	s.IntentDetectionConfidence = float64(s1.IntentDetectionConfidence)
15838	s.SpeechRecognitionConfidence = float64(s1.SpeechRecognitionConfidence)
15839	return nil
15840}
15841
15842// GoogleCloudDialogflowV2beta1Sentiment: The sentiment, such as
15843// positive/negative feeling or association, for a unit of analysis,
15844// such as the query text.
15845type GoogleCloudDialogflowV2beta1Sentiment struct {
15846	// Magnitude: A non-negative number in the [0, +inf) range, which
15847	// represents the absolute magnitude of sentiment, regardless of score
15848	// (positive or negative).
15849	Magnitude float64 `json:"magnitude,omitempty"`
15850
15851	// Score: Sentiment score between -1.0 (negative sentiment) and 1.0
15852	// (positive sentiment).
15853	Score float64 `json:"score,omitempty"`
15854
15855	// ForceSendFields is a list of field names (e.g. "Magnitude") to
15856	// unconditionally include in API requests. By default, fields with
15857	// empty values are omitted from API requests. However, any non-pointer,
15858	// non-interface field appearing in ForceSendFields will be sent to the
15859	// server regardless of whether the field is empty or not. This may be
15860	// used to include empty fields in Patch requests.
15861	ForceSendFields []string `json:"-"`
15862
15863	// NullFields is a list of field names (e.g. "Magnitude") to include in
15864	// API requests with the JSON null value. By default, fields with empty
15865	// values are omitted from API requests. However, any field with an
15866	// empty value appearing in NullFields will be sent to the server as
15867	// null. It is an error if a field in this list has a non-empty value.
15868	// This may be used to include null fields in Patch requests.
15869	NullFields []string `json:"-"`
15870}
15871
15872func (s *GoogleCloudDialogflowV2beta1Sentiment) MarshalJSON() ([]byte, error) {
15873	type NoMethod GoogleCloudDialogflowV2beta1Sentiment
15874	raw := NoMethod(*s)
15875	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15876}
15877
15878func (s *GoogleCloudDialogflowV2beta1Sentiment) UnmarshalJSON(data []byte) error {
15879	type NoMethod GoogleCloudDialogflowV2beta1Sentiment
15880	var s1 struct {
15881		Magnitude gensupport.JSONFloat64 `json:"magnitude"`
15882		Score     gensupport.JSONFloat64 `json:"score"`
15883		*NoMethod
15884	}
15885	s1.NoMethod = (*NoMethod)(s)
15886	if err := json.Unmarshal(data, &s1); err != nil {
15887		return err
15888	}
15889	s.Magnitude = float64(s1.Magnitude)
15890	s.Score = float64(s1.Score)
15891	return nil
15892}
15893
15894// GoogleCloudDialogflowV2beta1SentimentAnalysisResult: The result of
15895// sentiment analysis. Sentiment analysis inspects user input and
15896// identifies the prevailing subjective opinion, especially to determine
15897// a user's attitude as positive, negative, or neutral. For
15898// Participants.DetectIntent, it needs to be configured in
15899// DetectIntentRequest.query_params. For
15900// Participants.StreamingDetectIntent, it needs to be configured in
15901// StreamingDetectIntentRequest.query_params. And for
15902// Participants.AnalyzeContent and Participants.StreamingAnalyzeContent,
15903// it needs to be configured in
15904// ConversationProfile.human_agent_assistant_config
15905type GoogleCloudDialogflowV2beta1SentimentAnalysisResult struct {
15906	// QueryTextSentiment: The sentiment analysis result for `query_text`.
15907	QueryTextSentiment *GoogleCloudDialogflowV2beta1Sentiment `json:"queryTextSentiment,omitempty"`
15908
15909	// ForceSendFields is a list of field names (e.g. "QueryTextSentiment")
15910	// to unconditionally include in API requests. By default, fields with
15911	// empty values are omitted from API requests. However, any non-pointer,
15912	// non-interface field appearing in ForceSendFields will be sent to the
15913	// server regardless of whether the field is empty or not. This may be
15914	// used to include empty fields in Patch requests.
15915	ForceSendFields []string `json:"-"`
15916
15917	// NullFields is a list of field names (e.g. "QueryTextSentiment") to
15918	// include in API requests with the JSON null value. By default, fields
15919	// with empty values are omitted from API requests. However, any field
15920	// with an empty value appearing in NullFields will be sent to the
15921	// server as null. It is an error if a field in this list has a
15922	// non-empty value. This may be used to include null fields in Patch
15923	// requests.
15924	NullFields []string `json:"-"`
15925}
15926
15927func (s *GoogleCloudDialogflowV2beta1SentimentAnalysisResult) MarshalJSON() ([]byte, error) {
15928	type NoMethod GoogleCloudDialogflowV2beta1SentimentAnalysisResult
15929	raw := NoMethod(*s)
15930	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15931}
15932
15933// GoogleCloudDialogflowV2beta1SessionEntityType: A session represents a
15934// conversation between a Dialogflow agent and an end-user. You can
15935// create special entities, called session entities, during a session.
15936// Session entities can extend or replace custom entity types and only
15937// exist during the session that they were created for. All session
15938// data, including session entities, is stored by Dialogflow for 20
15939// minutes. For more information, see the session entity guide
15940// (https://cloud.google.com/dialogflow/docs/entities-session).
15941type GoogleCloudDialogflowV2beta1SessionEntityType struct {
15942	// Entities: Required. The collection of entities associated with this
15943	// session entity type.
15944	Entities []*GoogleCloudDialogflowV2beta1EntityTypeEntity `json:"entities,omitempty"`
15945
15946	// EntityOverrideMode: Required. Indicates whether the additional data
15947	// should override or supplement the custom entity type definition.
15948	//
15949	// Possible values:
15950	//   "ENTITY_OVERRIDE_MODE_UNSPECIFIED" - Not specified. This value
15951	// should be never used.
15952	//   "ENTITY_OVERRIDE_MODE_OVERRIDE" - The collection of session
15953	// entities overrides the collection of entities in the corresponding
15954	// custom entity type.
15955	//   "ENTITY_OVERRIDE_MODE_SUPPLEMENT" - The collection of session
15956	// entities extends the collection of entities in the corresponding
15957	// custom entity type. Note: Even in this override mode calls to
15958	// `ListSessionEntityTypes`, `GetSessionEntityType`,
15959	// `CreateSessionEntityType` and `UpdateSessionEntityType` only return
15960	// the additional entities added in this session entity type. If you
15961	// want to get the supplemented list, please call
15962	// EntityTypes.GetEntityType on the custom entity type and merge.
15963	EntityOverrideMode string `json:"entityOverrideMode,omitempty"`
15964
15965	// Name: Required. The unique identifier of this session entity type.
15966	// Supported formats: - `projects//agent/sessions//entityTypes/` -
15967	// `projects//locations//agent/sessions//entityTypes/` -
15968	// `projects//agent/environments//users//sessions//entityTypes/` -
15969	// `projects//locations//agent/environments/
15970	// /users//sessions//entityTypes/` If `Location ID` is not specified we
15971	// assume default 'us' location. If `Environment ID` is not specified,
15972	// we assume default 'draft' environment. If `User ID` is not specified,
15973	// we assume default '-' user. `` must be the display name of an
15974	// existing entity type in the same agent that will be overridden or
15975	// supplemented.
15976	Name string `json:"name,omitempty"`
15977
15978	// ForceSendFields is a list of field names (e.g. "Entities") to
15979	// unconditionally include in API requests. By default, fields with
15980	// empty values are omitted from API requests. However, any non-pointer,
15981	// non-interface field appearing in ForceSendFields will be sent to the
15982	// server regardless of whether the field is empty or not. This may be
15983	// used to include empty fields in Patch requests.
15984	ForceSendFields []string `json:"-"`
15985
15986	// NullFields is a list of field names (e.g. "Entities") to include in
15987	// API requests with the JSON null value. By default, fields with empty
15988	// values are omitted from API requests. However, any field with an
15989	// 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 *GoogleCloudDialogflowV2beta1SessionEntityType) MarshalJSON() ([]byte, error) {
15996	type NoMethod GoogleCloudDialogflowV2beta1SessionEntityType
15997	raw := NoMethod(*s)
15998	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15999}
16000
16001// GoogleCloudDialogflowV2beta1SmartReplyAnswer: Represents a smart
16002// reply answer.
16003type GoogleCloudDialogflowV2beta1SmartReplyAnswer struct {
16004	// AnswerRecord: The name of answer record, in the format of
16005	// "projects//locations//answerRecords/"
16006	AnswerRecord string `json:"answerRecord,omitempty"`
16007
16008	// Confidence: Smart reply confidence. The system's confidence score
16009	// that this reply is a good match for this conversation, as a value
16010	// from 0.0 (completely uncertain) to 1.0 (completely certain).
16011	Confidence float64 `json:"confidence,omitempty"`
16012
16013	// Reply: The content of the reply.
16014	Reply string `json:"reply,omitempty"`
16015
16016	// ForceSendFields is a list of field names (e.g. "AnswerRecord") to
16017	// unconditionally include in API requests. By default, fields with
16018	// empty values are omitted from API requests. However, any non-pointer,
16019	// non-interface field appearing in ForceSendFields will be sent to the
16020	// server regardless of whether the field is empty or not. This may be
16021	// used to include empty fields in Patch requests.
16022	ForceSendFields []string `json:"-"`
16023
16024	// NullFields is a list of field names (e.g. "AnswerRecord") to include
16025	// in API requests with the JSON null value. By default, fields with
16026	// empty values are omitted from API requests. However, any field with
16027	// an empty value appearing in NullFields will be sent to the server as
16028	// null. It is an error if a field in this list has a non-empty value.
16029	// This may be used to include null fields in Patch requests.
16030	NullFields []string `json:"-"`
16031}
16032
16033func (s *GoogleCloudDialogflowV2beta1SmartReplyAnswer) MarshalJSON() ([]byte, error) {
16034	type NoMethod GoogleCloudDialogflowV2beta1SmartReplyAnswer
16035	raw := NoMethod(*s)
16036	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16037}
16038
16039func (s *GoogleCloudDialogflowV2beta1SmartReplyAnswer) UnmarshalJSON(data []byte) error {
16040	type NoMethod GoogleCloudDialogflowV2beta1SmartReplyAnswer
16041	var s1 struct {
16042		Confidence gensupport.JSONFloat64 `json:"confidence"`
16043		*NoMethod
16044	}
16045	s1.NoMethod = (*NoMethod)(s)
16046	if err := json.Unmarshal(data, &s1); err != nil {
16047		return err
16048	}
16049	s.Confidence = float64(s1.Confidence)
16050	return nil
16051}
16052
16053// GoogleCloudDialogflowV2beta1SuggestArticlesResponse: The response
16054// message for Participants.SuggestArticles.
16055type GoogleCloudDialogflowV2beta1SuggestArticlesResponse struct {
16056	// ArticleAnswers: Output only. Articles ordered by score in descending
16057	// order.
16058	ArticleAnswers []*GoogleCloudDialogflowV2beta1ArticleAnswer `json:"articleAnswers,omitempty"`
16059
16060	// ContextSize: Number of messages prior to and including latest_message
16061	// to compile the suggestion. It may be smaller than the
16062	// SuggestArticlesResponse.context_size field in the request if there
16063	// aren't that many messages in the conversation.
16064	ContextSize int64 `json:"contextSize,omitempty"`
16065
16066	// LatestMessage: The name of the latest conversation message used to
16067	// compile suggestion for. Format:
16068	// `projects//locations//conversations//messages/`.
16069	LatestMessage string `json:"latestMessage,omitempty"`
16070
16071	// ForceSendFields is a list of field names (e.g. "ArticleAnswers") to
16072	// unconditionally include in API requests. By default, fields with
16073	// empty values are omitted from API requests. However, any non-pointer,
16074	// non-interface field appearing in ForceSendFields will be sent to the
16075	// server regardless of whether the field is empty or not. This may be
16076	// used to include empty fields in Patch requests.
16077	ForceSendFields []string `json:"-"`
16078
16079	// NullFields is a list of field names (e.g. "ArticleAnswers") to
16080	// include in API requests with the JSON null value. By default, fields
16081	// with empty values are omitted from API requests. However, any field
16082	// with an empty value appearing in NullFields will be sent to the
16083	// server as null. It is an error if a field in this list has a
16084	// non-empty value. This may be used to include null fields in Patch
16085	// requests.
16086	NullFields []string `json:"-"`
16087}
16088
16089func (s *GoogleCloudDialogflowV2beta1SuggestArticlesResponse) MarshalJSON() ([]byte, error) {
16090	type NoMethod GoogleCloudDialogflowV2beta1SuggestArticlesResponse
16091	raw := NoMethod(*s)
16092	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16093}
16094
16095// GoogleCloudDialogflowV2beta1SuggestFaqAnswersResponse: The request
16096// message for Participants.SuggestFaqAnswers.
16097type GoogleCloudDialogflowV2beta1SuggestFaqAnswersResponse struct {
16098	// ContextSize: Number of messages prior to and including latest_message
16099	// to compile the suggestion. It may be smaller than the
16100	// SuggestFaqAnswersRequest.context_size field in the request if there
16101	// aren't that many messages in the conversation.
16102	ContextSize int64 `json:"contextSize,omitempty"`
16103
16104	// FaqAnswers: Output only. Answers extracted from FAQ documents.
16105	FaqAnswers []*GoogleCloudDialogflowV2beta1FaqAnswer `json:"faqAnswers,omitempty"`
16106
16107	// LatestMessage: The name of the latest conversation message used to
16108	// compile suggestion for. Format:
16109	// `projects//locations//conversations//messages/`.
16110	LatestMessage string `json:"latestMessage,omitempty"`
16111
16112	// ForceSendFields is a list of field names (e.g. "ContextSize") to
16113	// unconditionally include in API requests. By default, fields with
16114	// empty values are omitted from API requests. However, any non-pointer,
16115	// non-interface field appearing in ForceSendFields will be sent to the
16116	// server regardless of whether the field is empty or not. This may be
16117	// used to include empty fields in Patch requests.
16118	ForceSendFields []string `json:"-"`
16119
16120	// NullFields is a list of field names (e.g. "ContextSize") to include
16121	// in API requests with the JSON null value. By default, fields with
16122	// empty values are omitted from API requests. However, any field with
16123	// an empty value appearing in NullFields will be sent to the server as
16124	// null. It is an error if a field in this list has a non-empty value.
16125	// This may be used to include null fields in Patch requests.
16126	NullFields []string `json:"-"`
16127}
16128
16129func (s *GoogleCloudDialogflowV2beta1SuggestFaqAnswersResponse) MarshalJSON() ([]byte, error) {
16130	type NoMethod GoogleCloudDialogflowV2beta1SuggestFaqAnswersResponse
16131	raw := NoMethod(*s)
16132	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16133}
16134
16135// GoogleCloudDialogflowV2beta1SuggestSmartRepliesResponse: The response
16136// message for Participants.SuggestSmartReplies.
16137type GoogleCloudDialogflowV2beta1SuggestSmartRepliesResponse struct {
16138	// ContextSize: Number of messages prior to and including latest_message
16139	// to compile the suggestion. It may be smaller than the
16140	// SuggestSmartRepliesRequest.context_size field in the request if there
16141	// aren't that many messages in the conversation.
16142	ContextSize int64 `json:"contextSize,omitempty"`
16143
16144	// LatestMessage: The name of the latest conversation message used to
16145	// compile suggestion for. Format:
16146	// `projects//locations//conversations//messages/`.
16147	LatestMessage string `json:"latestMessage,omitempty"`
16148
16149	// SmartReplyAnswers: Output only. Multiple reply options provided by
16150	// smart reply service. The order is based on the rank of the model
16151	// prediction. The maximum number of the returned replies is set in
16152	// SmartReplyConfig.
16153	SmartReplyAnswers []*GoogleCloudDialogflowV2beta1SmartReplyAnswer `json:"smartReplyAnswers,omitempty"`
16154
16155	// ForceSendFields is a list of field names (e.g. "ContextSize") to
16156	// unconditionally include in API requests. By default, fields with
16157	// empty values are omitted from API requests. However, any non-pointer,
16158	// non-interface field appearing in ForceSendFields will be sent to the
16159	// server regardless of whether the field is empty or not. This may be
16160	// used to include empty fields in Patch requests.
16161	ForceSendFields []string `json:"-"`
16162
16163	// NullFields is a list of field names (e.g. "ContextSize") to include
16164	// in API requests with the JSON null value. By default, fields with
16165	// empty values are omitted from API requests. However, any field with
16166	// an empty value appearing in NullFields will be sent to the server as
16167	// null. It is an error if a field in this list has a non-empty value.
16168	// This may be used to include null fields in Patch requests.
16169	NullFields []string `json:"-"`
16170}
16171
16172func (s *GoogleCloudDialogflowV2beta1SuggestSmartRepliesResponse) MarshalJSON() ([]byte, error) {
16173	type NoMethod GoogleCloudDialogflowV2beta1SuggestSmartRepliesResponse
16174	raw := NoMethod(*s)
16175	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16176}
16177
16178// GoogleCloudDialogflowV2beta1SuggestionResult: One response of
16179// different type of suggestion response which is used in the response
16180// of Participants.AnalyzeContent and Participants.AnalyzeContent, as
16181// well as HumanAgentAssistantEvent.
16182type GoogleCloudDialogflowV2beta1SuggestionResult struct {
16183	// Error: Error status if the request failed.
16184	Error *GoogleRpcStatus `json:"error,omitempty"`
16185
16186	// SuggestArticlesResponse: SuggestArticlesResponse if request is for
16187	// ARTICLE_SUGGESTION.
16188	SuggestArticlesResponse *GoogleCloudDialogflowV2beta1SuggestArticlesResponse `json:"suggestArticlesResponse,omitempty"`
16189
16190	// SuggestFaqAnswersResponse: SuggestFaqAnswersResponse if request is
16191	// for FAQ_ANSWER.
16192	SuggestFaqAnswersResponse *GoogleCloudDialogflowV2beta1SuggestFaqAnswersResponse `json:"suggestFaqAnswersResponse,omitempty"`
16193
16194	// SuggestSmartRepliesResponse: SuggestSmartRepliesResponse if request
16195	// is for SMART_REPLY.
16196	SuggestSmartRepliesResponse *GoogleCloudDialogflowV2beta1SuggestSmartRepliesResponse `json:"suggestSmartRepliesResponse,omitempty"`
16197
16198	// ForceSendFields is a list of field names (e.g. "Error") to
16199	// unconditionally include in API requests. By default, fields with
16200	// empty values are omitted from API requests. However, any non-pointer,
16201	// non-interface field appearing in ForceSendFields will be sent to the
16202	// server regardless of whether the field is empty or not. This may be
16203	// used to include empty fields in Patch requests.
16204	ForceSendFields []string `json:"-"`
16205
16206	// NullFields is a list of field names (e.g. "Error") to include in API
16207	// requests with the JSON null value. By default, fields with empty
16208	// values are omitted from API requests. However, any field with an
16209	// empty value appearing in NullFields will be sent to the server as
16210	// null. It is an error if a field in this list has a non-empty value.
16211	// This may be used to include null fields in Patch requests.
16212	NullFields []string `json:"-"`
16213}
16214
16215func (s *GoogleCloudDialogflowV2beta1SuggestionResult) MarshalJSON() ([]byte, error) {
16216	type NoMethod GoogleCloudDialogflowV2beta1SuggestionResult
16217	raw := NoMethod(*s)
16218	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16219}
16220
16221// GoogleCloudDialogflowV2beta1WebhookRequest: The request message for a
16222// webhook call.
16223type GoogleCloudDialogflowV2beta1WebhookRequest struct {
16224	// AlternativeQueryResults: Alternative query results from
16225	// KnowledgeService.
16226	AlternativeQueryResults []*GoogleCloudDialogflowV2beta1QueryResult `json:"alternativeQueryResults,omitempty"`
16227
16228	// OriginalDetectIntentRequest: Optional. The contents of the original
16229	// request that was passed to `[Streaming]DetectIntent` call.
16230	OriginalDetectIntentRequest *GoogleCloudDialogflowV2beta1OriginalDetectIntentRequest `json:"originalDetectIntentRequest,omitempty"`
16231
16232	// QueryResult: The result of the conversational query or event
16233	// processing. Contains the same value as
16234	// `[Streaming]DetectIntentResponse.query_result`.
16235	QueryResult *GoogleCloudDialogflowV2beta1QueryResult `json:"queryResult,omitempty"`
16236
16237	// ResponseId: The unique identifier of the response. Contains the same
16238	// value as `[Streaming]DetectIntentResponse.response_id`.
16239	ResponseId string `json:"responseId,omitempty"`
16240
16241	// Session: The unique identifier of detectIntent request session. Can
16242	// be used to identify end-user inside webhook implementation. Supported
16243	// formats: - `projects//agent/sessions/, -
16244	// `projects//locations//agent/sessions/`, -
16245	// `projects//agent/environments//users//sessions/`, -
16246	// `projects//locations//agent/environments//users//sessions/`,
16247	Session string `json:"session,omitempty"`
16248
16249	// ForceSendFields is a list of field names (e.g.
16250	// "AlternativeQueryResults") to unconditionally include in API
16251	// requests. By default, fields with empty values are omitted from API
16252	// requests. However, any non-pointer, non-interface field appearing in
16253	// ForceSendFields will be sent to the server regardless of whether the
16254	// field is empty or not. This may be used to include empty fields in
16255	// Patch requests.
16256	ForceSendFields []string `json:"-"`
16257
16258	// NullFields is a list of field names (e.g. "AlternativeQueryResults")
16259	// to include in API requests with the JSON null value. By default,
16260	// fields with empty values are omitted from API requests. However, any
16261	// field with an empty value appearing in NullFields will be sent to the
16262	// server as null. It is an error if a field in this list has a
16263	// non-empty value. This may be used to include null fields in Patch
16264	// requests.
16265	NullFields []string `json:"-"`
16266}
16267
16268func (s *GoogleCloudDialogflowV2beta1WebhookRequest) MarshalJSON() ([]byte, error) {
16269	type NoMethod GoogleCloudDialogflowV2beta1WebhookRequest
16270	raw := NoMethod(*s)
16271	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16272}
16273
16274// GoogleCloudDialogflowV2beta1WebhookResponse: The response message for
16275// a webhook call. This response is validated by the Dialogflow server.
16276// If validation fails, an error will be returned in the
16277// QueryResult.diagnostic_info field. Setting JSON fields to an empty
16278// value with the wrong type is a common error. To avoid this error: -
16279// Use "" for empty strings - Use `{}` or `null` for empty objects -
16280// Use `[]` or `null` for empty arrays For more information, see the
16281// Protocol Buffers Language Guide
16282// (https://developers.google.com/protocol-buffers/docs/proto3#json).
16283type GoogleCloudDialogflowV2beta1WebhookResponse struct {
16284	// EndInteraction: Optional. Indicates that this intent ends an
16285	// interaction. Some integrations (e.g., Actions on Google or Dialogflow
16286	// phone gateway) use this information to close interaction with an end
16287	// user. Default is false.
16288	EndInteraction bool `json:"endInteraction,omitempty"`
16289
16290	// FollowupEventInput: Optional. Invokes the supplied events. When this
16291	// field is set, Dialogflow ignores the `fulfillment_text`,
16292	// `fulfillment_messages`, and `payload` fields.
16293	FollowupEventInput *GoogleCloudDialogflowV2beta1EventInput `json:"followupEventInput,omitempty"`
16294
16295	// FulfillmentMessages: Optional. The rich response messages intended
16296	// for the end-user. When provided, Dialogflow uses this field to
16297	// populate QueryResult.fulfillment_messages sent to the integration or
16298	// API caller.
16299	FulfillmentMessages []*GoogleCloudDialogflowV2beta1IntentMessage `json:"fulfillmentMessages,omitempty"`
16300
16301	// FulfillmentText: Optional. The text response message intended for the
16302	// end-user. It is recommended to use
16303	// `fulfillment_messages.text.text[0]` instead. When provided,
16304	// Dialogflow uses this field to populate QueryResult.fulfillment_text
16305	// sent to the integration or API caller.
16306	FulfillmentText string `json:"fulfillmentText,omitempty"`
16307
16308	// LiveAgentHandoff: Indicates that a live agent should be brought in to
16309	// handle the interaction with the user. In most cases, when you set
16310	// this flag to true, you would also want to set end_interaction to true
16311	// as well. Default is false.
16312	LiveAgentHandoff bool `json:"liveAgentHandoff,omitempty"`
16313
16314	// OutputContexts: Optional. The collection of output contexts that will
16315	// overwrite currently active contexts for the session and reset their
16316	// lifespans. When provided, Dialogflow uses this field to populate
16317	// QueryResult.output_contexts sent to the integration or API caller.
16318	OutputContexts []*GoogleCloudDialogflowV2beta1Context `json:"outputContexts,omitempty"`
16319
16320	// Payload: Optional. This field can be used to pass custom data from
16321	// your webhook to the integration or API caller. Arbitrary JSON objects
16322	// are supported. When provided, Dialogflow uses this field to populate
16323	// QueryResult.webhook_payload sent to the integration or API caller.
16324	// This field is also used by the Google Assistant integration
16325	// (https://cloud.google.com/dialogflow/docs/integrations/aog) for rich
16326	// response messages. See the format definition at Google Assistant
16327	// Dialogflow webhook format
16328	// (https://developers.google.com/assistant/actions/build/json/dialogflow-webhook-json)
16329	Payload googleapi.RawMessage `json:"payload,omitempty"`
16330
16331	// SessionEntityTypes: Optional. Additional session entity types to
16332	// replace or extend developer entity types with. The entity synonyms
16333	// apply to all languages and persist for the session. Setting this data
16334	// from a webhook overwrites the session entity types that have been set
16335	// using `detectIntent`, `streamingDetectIntent` or SessionEntityType
16336	// management methods.
16337	SessionEntityTypes []*GoogleCloudDialogflowV2beta1SessionEntityType `json:"sessionEntityTypes,omitempty"`
16338
16339	// Source: Optional. A custom field used to identify the webhook source.
16340	// Arbitrary strings are supported. When provided, Dialogflow uses this
16341	// field to populate QueryResult.webhook_source sent to the integration
16342	// or API caller.
16343	Source string `json:"source,omitempty"`
16344
16345	// ForceSendFields is a list of field names (e.g. "EndInteraction") to
16346	// unconditionally include in API requests. By default, fields with
16347	// empty values are omitted from API requests. However, any non-pointer,
16348	// non-interface field appearing in ForceSendFields will be sent to the
16349	// server regardless of whether the field is empty or not. This may be
16350	// used to include empty fields in Patch requests.
16351	ForceSendFields []string `json:"-"`
16352
16353	// NullFields is a list of field names (e.g. "EndInteraction") to
16354	// include in API requests with the JSON null value. By default, fields
16355	// with empty values are omitted from API requests. However, any field
16356	// with an empty value appearing in NullFields will be sent to the
16357	// server as null. It is an error if a field in this list has a
16358	// non-empty value. This may be used to include null fields in Patch
16359	// requests.
16360	NullFields []string `json:"-"`
16361}
16362
16363func (s *GoogleCloudDialogflowV2beta1WebhookResponse) MarshalJSON() ([]byte, error) {
16364	type NoMethod GoogleCloudDialogflowV2beta1WebhookResponse
16365	raw := NoMethod(*s)
16366	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16367}
16368
16369// GoogleCloudDialogflowV3alpha1CreateDocumentOperationMetadata:
16370// Metadata for CreateDocument operation.
16371type GoogleCloudDialogflowV3alpha1CreateDocumentOperationMetadata struct {
16372	// GenericMetadata: The generic information of the operation.
16373	GenericMetadata *GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
16374
16375	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
16376	// unconditionally include in API requests. By default, fields with
16377	// empty values are omitted from API requests. However, any non-pointer,
16378	// non-interface field appearing in ForceSendFields will be sent to the
16379	// server regardless of whether the field is empty or not. This may be
16380	// used to include empty fields in Patch requests.
16381	ForceSendFields []string `json:"-"`
16382
16383	// NullFields is a list of field names (e.g. "GenericMetadata") to
16384	// include in API requests with the JSON null value. By default, fields
16385	// with empty values are omitted from API requests. However, any field
16386	// with an empty value appearing in NullFields will be sent to the
16387	// server as null. It is an error if a field in this list has a
16388	// non-empty value. This may be used to include null fields in Patch
16389	// requests.
16390	NullFields []string `json:"-"`
16391}
16392
16393func (s *GoogleCloudDialogflowV3alpha1CreateDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
16394	type NoMethod GoogleCloudDialogflowV3alpha1CreateDocumentOperationMetadata
16395	raw := NoMethod(*s)
16396	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16397}
16398
16399// GoogleCloudDialogflowV3alpha1DeleteDocumentOperationMetadata:
16400// Metadata for DeleteDocument operation.
16401type GoogleCloudDialogflowV3alpha1DeleteDocumentOperationMetadata struct {
16402	// GenericMetadata: The generic information of the operation.
16403	GenericMetadata *GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
16404
16405	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
16406	// unconditionally include in API requests. By default, fields with
16407	// empty values are omitted from API requests. However, any non-pointer,
16408	// non-interface field appearing in ForceSendFields will be sent to the
16409	// server regardless of whether the field is empty or not. This may be
16410	// used to include empty fields in Patch requests.
16411	ForceSendFields []string `json:"-"`
16412
16413	// NullFields is a list of field names (e.g. "GenericMetadata") to
16414	// include in API requests with the JSON null value. By default, fields
16415	// with empty values are omitted from API requests. However, any field
16416	// with an empty value appearing in NullFields will be sent to the
16417	// server as null. It is an error if a field in this list has a
16418	// non-empty value. This may be used to include null fields in Patch
16419	// requests.
16420	NullFields []string `json:"-"`
16421}
16422
16423func (s *GoogleCloudDialogflowV3alpha1DeleteDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
16424	type NoMethod GoogleCloudDialogflowV3alpha1DeleteDocumentOperationMetadata
16425	raw := NoMethod(*s)
16426	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16427}
16428
16429// GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata:
16430// Metadata in google::longrunning::Operation for Knowledge operations.
16431type GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata struct {
16432	// State: Required. Output only. The current state of this operation.
16433	//
16434	// Possible values:
16435	//   "STATE_UNSPECIFIED" - State unspecified.
16436	//   "PENDING" - The operation has been created.
16437	//   "RUNNING" - The operation is currently running.
16438	//   "DONE" - The operation is done, either cancelled or completed.
16439	State string `json:"state,omitempty"`
16440
16441	// ForceSendFields is a list of field names (e.g. "State") to
16442	// unconditionally include in API requests. By default, fields with
16443	// empty values are omitted from API requests. However, any non-pointer,
16444	// non-interface field appearing in ForceSendFields will be sent to the
16445	// server regardless of whether the field is empty or not. This may be
16446	// used to include empty fields in Patch requests.
16447	ForceSendFields []string `json:"-"`
16448
16449	// NullFields is a list of field names (e.g. "State") to include in API
16450	// requests with the JSON null value. By default, fields with empty
16451	// values are omitted from API requests. However, any field with an
16452	// empty value appearing in NullFields will be sent to the server as
16453	// null. It is an error if a field in this list has a non-empty value.
16454	// This may be used to include null fields in Patch requests.
16455	NullFields []string `json:"-"`
16456}
16457
16458func (s *GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata) MarshalJSON() ([]byte, error) {
16459	type NoMethod GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata
16460	raw := NoMethod(*s)
16461	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16462}
16463
16464// GoogleCloudDialogflowV3alpha1ImportDocumentsOperationMetadata:
16465// Metadata for ImportDocuments operation.
16466type GoogleCloudDialogflowV3alpha1ImportDocumentsOperationMetadata struct {
16467	// GenericMetadata: The generic information of the operation.
16468	GenericMetadata *GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
16469
16470	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
16471	// unconditionally include in API requests. By default, fields with
16472	// empty values are omitted from API requests. However, any non-pointer,
16473	// non-interface field appearing in ForceSendFields will be sent to the
16474	// server regardless of whether the field is empty or not. This may be
16475	// used to include empty fields in Patch requests.
16476	ForceSendFields []string `json:"-"`
16477
16478	// NullFields is a list of field names (e.g. "GenericMetadata") to
16479	// include in API requests with the JSON null value. By default, fields
16480	// with empty values are omitted from API requests. However, any field
16481	// with an empty value appearing in NullFields will be sent to the
16482	// server as null. It is an error if a field in this list has a
16483	// non-empty value. This may be used to include null fields in Patch
16484	// requests.
16485	NullFields []string `json:"-"`
16486}
16487
16488func (s *GoogleCloudDialogflowV3alpha1ImportDocumentsOperationMetadata) MarshalJSON() ([]byte, error) {
16489	type NoMethod GoogleCloudDialogflowV3alpha1ImportDocumentsOperationMetadata
16490	raw := NoMethod(*s)
16491	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16492}
16493
16494// GoogleCloudDialogflowV3alpha1ImportDocumentsResponse: Response
16495// message for Documents.ImportDocuments.
16496type GoogleCloudDialogflowV3alpha1ImportDocumentsResponse struct {
16497	// Warnings: Includes details about skipped documents or any other
16498	// warnings.
16499	Warnings []*GoogleRpcStatus `json:"warnings,omitempty"`
16500
16501	// ForceSendFields is a list of field names (e.g. "Warnings") to
16502	// unconditionally include in API requests. By default, fields with
16503	// empty values are omitted from API requests. However, any non-pointer,
16504	// non-interface field appearing in ForceSendFields will be sent to the
16505	// server regardless of whether the field is empty or not. This may be
16506	// used to include empty fields in Patch requests.
16507	ForceSendFields []string `json:"-"`
16508
16509	// NullFields is a list of field names (e.g. "Warnings") to include in
16510	// API requests with the JSON null value. By default, fields with empty
16511	// values are omitted from API requests. However, any field with an
16512	// empty value appearing in NullFields will be sent to the server as
16513	// null. It is an error if a field in this list has a non-empty value.
16514	// This may be used to include null fields in Patch requests.
16515	NullFields []string `json:"-"`
16516}
16517
16518func (s *GoogleCloudDialogflowV3alpha1ImportDocumentsResponse) MarshalJSON() ([]byte, error) {
16519	type NoMethod GoogleCloudDialogflowV3alpha1ImportDocumentsResponse
16520	raw := NoMethod(*s)
16521	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16522}
16523
16524// GoogleCloudDialogflowV3alpha1ReloadDocumentOperationMetadata:
16525// Metadata for ReloadDocument operation.
16526type GoogleCloudDialogflowV3alpha1ReloadDocumentOperationMetadata struct {
16527	// GenericMetadata: The generic information of the operation.
16528	GenericMetadata *GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
16529
16530	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
16531	// unconditionally include in API requests. By default, fields with
16532	// empty values are omitted from API requests. However, any non-pointer,
16533	// non-interface field appearing in ForceSendFields will be sent to the
16534	// server regardless of whether the field is empty or not. This may be
16535	// used to include empty fields in Patch requests.
16536	ForceSendFields []string `json:"-"`
16537
16538	// NullFields is a list of field names (e.g. "GenericMetadata") to
16539	// include in API requests with the JSON null value. By default, fields
16540	// with empty values are omitted from API requests. However, any field
16541	// with an empty value appearing in NullFields will be sent to the
16542	// server as null. It is an error if a field in this list has a
16543	// non-empty value. This may be used to include null fields in Patch
16544	// requests.
16545	NullFields []string `json:"-"`
16546}
16547
16548func (s *GoogleCloudDialogflowV3alpha1ReloadDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
16549	type NoMethod GoogleCloudDialogflowV3alpha1ReloadDocumentOperationMetadata
16550	raw := NoMethod(*s)
16551	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16552}
16553
16554// GoogleCloudDialogflowV3alpha1UpdateDocumentOperationMetadata:
16555// Metadata for UpdateDocument operation.
16556type GoogleCloudDialogflowV3alpha1UpdateDocumentOperationMetadata struct {
16557	// GenericMetadata: The generic information of the operation.
16558	GenericMetadata *GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
16559
16560	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
16561	// unconditionally include in API requests. By default, fields with
16562	// empty values are omitted from API requests. However, any non-pointer,
16563	// non-interface field appearing in ForceSendFields will be sent to the
16564	// server regardless of whether the field is empty or not. This may be
16565	// used to include empty fields in Patch requests.
16566	ForceSendFields []string `json:"-"`
16567
16568	// NullFields is a list of field names (e.g. "GenericMetadata") to
16569	// include in API requests with the JSON null value. By default, fields
16570	// with empty values are omitted from API requests. However, any field
16571	// with an empty value appearing in NullFields will be sent to the
16572	// server as null. It is an error if a field in this list has a
16573	// non-empty value. This may be used to include null fields in Patch
16574	// requests.
16575	NullFields []string `json:"-"`
16576}
16577
16578func (s *GoogleCloudDialogflowV3alpha1UpdateDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
16579	type NoMethod GoogleCloudDialogflowV3alpha1UpdateDocumentOperationMetadata
16580	raw := NoMethod(*s)
16581	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16582}
16583
16584// GoogleLongrunningListOperationsResponse: The response message for
16585// Operations.ListOperations.
16586type GoogleLongrunningListOperationsResponse struct {
16587	// NextPageToken: The standard List next-page token.
16588	NextPageToken string `json:"nextPageToken,omitempty"`
16589
16590	// Operations: A list of operations that matches the specified filter in
16591	// the request.
16592	Operations []*GoogleLongrunningOperation `json:"operations,omitempty"`
16593
16594	// ServerResponse contains the HTTP response code and headers from the
16595	// server.
16596	googleapi.ServerResponse `json:"-"`
16597
16598	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
16599	// unconditionally include in API requests. By default, fields with
16600	// empty values are omitted from API requests. However, any non-pointer,
16601	// non-interface field appearing in ForceSendFields will be sent to the
16602	// server regardless of whether the field is empty or not. This may be
16603	// used to include empty fields in Patch requests.
16604	ForceSendFields []string `json:"-"`
16605
16606	// NullFields is a list of field names (e.g. "NextPageToken") to include
16607	// in API requests with the JSON null value. By default, fields with
16608	// empty values are omitted from API requests. However, any field with
16609	// an empty value appearing in NullFields will be sent to the server as
16610	// null. It is an error if a field in this list has a non-empty value.
16611	// This may be used to include null fields in Patch requests.
16612	NullFields []string `json:"-"`
16613}
16614
16615func (s *GoogleLongrunningListOperationsResponse) MarshalJSON() ([]byte, error) {
16616	type NoMethod GoogleLongrunningListOperationsResponse
16617	raw := NoMethod(*s)
16618	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16619}
16620
16621// GoogleLongrunningOperation: This resource represents a long-running
16622// operation that is the result of a network API call.
16623type GoogleLongrunningOperation struct {
16624	// Done: If the value is `false`, it means the operation is still in
16625	// progress. If `true`, the operation is completed, and either `error`
16626	// or `response` is available.
16627	Done bool `json:"done,omitempty"`
16628
16629	// Error: The error result of the operation in case of failure or
16630	// cancellation.
16631	Error *GoogleRpcStatus `json:"error,omitempty"`
16632
16633	// Metadata: Service-specific metadata associated with the operation. It
16634	// typically contains progress information and common metadata such as
16635	// create time. Some services might not provide such metadata. Any
16636	// method that returns a long-running operation should document the
16637	// metadata type, if any.
16638	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
16639
16640	// Name: The server-assigned name, which is only unique within the same
16641	// service that originally returns it. If you use the default HTTP
16642	// mapping, the `name` should be a resource name ending with
16643	// `operations/{unique_id}`.
16644	Name string `json:"name,omitempty"`
16645
16646	// Response: The normal response of the operation in case of success. If
16647	// the original method returns no data on success, such as `Delete`, the
16648	// response is `google.protobuf.Empty`. If the original method is
16649	// standard `Get`/`Create`/`Update`, the response should be the
16650	// resource. For other methods, the response should have the type
16651	// `XxxResponse`, where `Xxx` is the original method name. For example,
16652	// if the original method name is `TakeSnapshot()`, the inferred
16653	// response type is `TakeSnapshotResponse`.
16654	Response googleapi.RawMessage `json:"response,omitempty"`
16655
16656	// ServerResponse contains the HTTP response code and headers from the
16657	// server.
16658	googleapi.ServerResponse `json:"-"`
16659
16660	// ForceSendFields is a list of field names (e.g. "Done") to
16661	// unconditionally include in API requests. By default, fields with
16662	// empty values are omitted from API requests. However, any non-pointer,
16663	// non-interface field appearing in ForceSendFields will be sent to the
16664	// server regardless of whether the field is empty or not. This may be
16665	// used to include empty fields in Patch requests.
16666	ForceSendFields []string `json:"-"`
16667
16668	// NullFields is a list of field names (e.g. "Done") to include in API
16669	// requests with the JSON null value. By default, fields with empty
16670	// values are omitted from API requests. However, any field with an
16671	// empty value appearing in NullFields will be sent to the server as
16672	// null. It is an error if a field in this list has a non-empty value.
16673	// This may be used to include null fields in Patch requests.
16674	NullFields []string `json:"-"`
16675}
16676
16677func (s *GoogleLongrunningOperation) MarshalJSON() ([]byte, error) {
16678	type NoMethod GoogleLongrunningOperation
16679	raw := NoMethod(*s)
16680	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16681}
16682
16683// GoogleProtobufEmpty: A generic empty message that you can re-use to
16684// avoid defining duplicated empty messages in your APIs. A typical
16685// example is to use it as the request or the response type of an API
16686// method. For instance: service Foo { rpc Bar(google.protobuf.Empty)
16687// returns (google.protobuf.Empty); } The JSON representation for
16688// `Empty` is empty JSON object `{}`.
16689type GoogleProtobufEmpty struct {
16690	// ServerResponse contains the HTTP response code and headers from the
16691	// server.
16692	googleapi.ServerResponse `json:"-"`
16693}
16694
16695// GoogleRpcStatus: The `Status` type defines a logical error model that
16696// is suitable for different programming environments, including REST
16697// APIs and RPC APIs. It is used by gRPC (https://github.com/grpc). Each
16698// `Status` message contains three pieces of data: error code, error
16699// message, and error details. You can find out more about this error
16700// model and how to work with it in the API Design Guide
16701// (https://cloud.google.com/apis/design/errors).
16702type GoogleRpcStatus struct {
16703	// Code: The status code, which should be an enum value of
16704	// google.rpc.Code.
16705	Code int64 `json:"code,omitempty"`
16706
16707	// Details: A list of messages that carry the error details. There is a
16708	// common set of message types for APIs to use.
16709	Details []googleapi.RawMessage `json:"details,omitempty"`
16710
16711	// Message: A developer-facing error message, which should be in
16712	// English. Any user-facing error message should be localized and sent
16713	// in the google.rpc.Status.details field, or localized by the client.
16714	Message string `json:"message,omitempty"`
16715
16716	// ForceSendFields is a list of field names (e.g. "Code") to
16717	// unconditionally include in API requests. By default, fields with
16718	// empty values are omitted from API requests. However, any non-pointer,
16719	// non-interface field appearing in ForceSendFields will be sent to the
16720	// server regardless of whether the field is empty or not. This may be
16721	// used to include empty fields in Patch requests.
16722	ForceSendFields []string `json:"-"`
16723
16724	// NullFields is a list of field names (e.g. "Code") to include in API
16725	// requests with the JSON null value. By default, fields with empty
16726	// values are omitted from API requests. However, any field with an
16727	// empty value appearing in NullFields will be sent to the server as
16728	// null. It is an error if a field in this list has a non-empty value.
16729	// This may be used to include null fields in Patch requests.
16730	NullFields []string `json:"-"`
16731}
16732
16733func (s *GoogleRpcStatus) MarshalJSON() ([]byte, error) {
16734	type NoMethod GoogleRpcStatus
16735	raw := NoMethod(*s)
16736	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16737}
16738
16739// GoogleTypeLatLng: An object that represents a latitude/longitude
16740// pair. This is expressed as a pair of doubles to represent degrees
16741// latitude and degrees longitude. Unless specified otherwise, this must
16742// conform to the WGS84 standard. Values must be within normalized
16743// ranges.
16744type GoogleTypeLatLng struct {
16745	// Latitude: The latitude in degrees. It must be in the range [-90.0,
16746	// +90.0].
16747	Latitude float64 `json:"latitude,omitempty"`
16748
16749	// Longitude: The longitude in degrees. It must be in the range [-180.0,
16750	// +180.0].
16751	Longitude float64 `json:"longitude,omitempty"`
16752
16753	// ForceSendFields is a list of field names (e.g. "Latitude") to
16754	// unconditionally include in API requests. By default, fields with
16755	// empty values are omitted from API requests. However, any non-pointer,
16756	// non-interface field appearing in ForceSendFields will be sent to the
16757	// server regardless of whether the field is empty or not. This may be
16758	// used to include empty fields in Patch requests.
16759	ForceSendFields []string `json:"-"`
16760
16761	// NullFields is a list of field names (e.g. "Latitude") to include in
16762	// API requests with the JSON null value. By default, fields with empty
16763	// values are omitted from API requests. However, any field with an
16764	// empty value appearing in NullFields will be sent to the server as
16765	// null. It is an error if a field in this list has a non-empty value.
16766	// This may be used to include null fields in Patch requests.
16767	NullFields []string `json:"-"`
16768}
16769
16770func (s *GoogleTypeLatLng) MarshalJSON() ([]byte, error) {
16771	type NoMethod GoogleTypeLatLng
16772	raw := NoMethod(*s)
16773	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16774}
16775
16776func (s *GoogleTypeLatLng) UnmarshalJSON(data []byte) error {
16777	type NoMethod GoogleTypeLatLng
16778	var s1 struct {
16779		Latitude  gensupport.JSONFloat64 `json:"latitude"`
16780		Longitude gensupport.JSONFloat64 `json:"longitude"`
16781		*NoMethod
16782	}
16783	s1.NoMethod = (*NoMethod)(s)
16784	if err := json.Unmarshal(data, &s1); err != nil {
16785		return err
16786	}
16787	s.Latitude = float64(s1.Latitude)
16788	s.Longitude = float64(s1.Longitude)
16789	return nil
16790}
16791
16792// method id "dialogflow.projects.deleteAgent":
16793
16794type ProjectsDeleteAgentCall struct {
16795	s          *Service
16796	parent     string
16797	urlParams_ gensupport.URLParams
16798	ctx_       context.Context
16799	header_    http.Header
16800}
16801
16802// DeleteAgent: Deletes the specified agent.
16803//
16804// - parent: The project that the agent to delete is associated with.
16805//   Format: `projects/`.
16806func (r *ProjectsService) DeleteAgent(parent string) *ProjectsDeleteAgentCall {
16807	c := &ProjectsDeleteAgentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16808	c.parent = parent
16809	return c
16810}
16811
16812// Fields allows partial responses to be retrieved. See
16813// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
16814// for more information.
16815func (c *ProjectsDeleteAgentCall) Fields(s ...googleapi.Field) *ProjectsDeleteAgentCall {
16816	c.urlParams_.Set("fields", googleapi.CombineFields(s))
16817	return c
16818}
16819
16820// Context sets the context to be used in this call's Do method. Any
16821// pending HTTP request will be aborted if the provided context is
16822// canceled.
16823func (c *ProjectsDeleteAgentCall) Context(ctx context.Context) *ProjectsDeleteAgentCall {
16824	c.ctx_ = ctx
16825	return c
16826}
16827
16828// Header returns an http.Header that can be modified by the caller to
16829// add HTTP headers to the request.
16830func (c *ProjectsDeleteAgentCall) Header() http.Header {
16831	if c.header_ == nil {
16832		c.header_ = make(http.Header)
16833	}
16834	return c.header_
16835}
16836
16837func (c *ProjectsDeleteAgentCall) doRequest(alt string) (*http.Response, error) {
16838	reqHeaders := make(http.Header)
16839	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
16840	for k, v := range c.header_ {
16841		reqHeaders[k] = v
16842	}
16843	reqHeaders.Set("User-Agent", c.s.userAgent())
16844	var body io.Reader = nil
16845	c.urlParams_.Set("alt", alt)
16846	c.urlParams_.Set("prettyPrint", "false")
16847	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent")
16848	urls += "?" + c.urlParams_.Encode()
16849	req, err := http.NewRequest("DELETE", urls, body)
16850	if err != nil {
16851		return nil, err
16852	}
16853	req.Header = reqHeaders
16854	googleapi.Expand(req.URL, map[string]string{
16855		"parent": c.parent,
16856	})
16857	return gensupport.SendRequest(c.ctx_, c.s.client, req)
16858}
16859
16860// Do executes the "dialogflow.projects.deleteAgent" call.
16861// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
16862// non-2xx status code is an error. Response headers are in either
16863// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
16864// returned at all) in error.(*googleapi.Error).Header. Use
16865// googleapi.IsNotModified to check whether the returned error was
16866// because http.StatusNotModified was returned.
16867func (c *ProjectsDeleteAgentCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
16868	gensupport.SetOptions(c.urlParams_, opts...)
16869	res, err := c.doRequest("json")
16870	if res != nil && res.StatusCode == http.StatusNotModified {
16871		if res.Body != nil {
16872			res.Body.Close()
16873		}
16874		return nil, &googleapi.Error{
16875			Code:   res.StatusCode,
16876			Header: res.Header,
16877		}
16878	}
16879	if err != nil {
16880		return nil, err
16881	}
16882	defer googleapi.CloseBody(res)
16883	if err := googleapi.CheckResponse(res); err != nil {
16884		return nil, err
16885	}
16886	ret := &GoogleProtobufEmpty{
16887		ServerResponse: googleapi.ServerResponse{
16888			Header:         res.Header,
16889			HTTPStatusCode: res.StatusCode,
16890		},
16891	}
16892	target := &ret
16893	if err := gensupport.DecodeResponse(target, res); err != nil {
16894		return nil, err
16895	}
16896	return ret, nil
16897	// {
16898	//   "description": "Deletes the specified agent.",
16899	//   "flatPath": "v2/projects/{projectsId}/agent",
16900	//   "httpMethod": "DELETE",
16901	//   "id": "dialogflow.projects.deleteAgent",
16902	//   "parameterOrder": [
16903	//     "parent"
16904	//   ],
16905	//   "parameters": {
16906	//     "parent": {
16907	//       "description": "Required. The project that the agent to delete is associated with. Format: `projects/`.",
16908	//       "location": "path",
16909	//       "pattern": "^projects/[^/]+$",
16910	//       "required": true,
16911	//       "type": "string"
16912	//     }
16913	//   },
16914	//   "path": "v2/{+parent}/agent",
16915	//   "response": {
16916	//     "$ref": "GoogleProtobufEmpty"
16917	//   },
16918	//   "scopes": [
16919	//     "https://www.googleapis.com/auth/cloud-platform",
16920	//     "https://www.googleapis.com/auth/dialogflow"
16921	//   ]
16922	// }
16923
16924}
16925
16926// method id "dialogflow.projects.getAgent":
16927
16928type ProjectsGetAgentCall struct {
16929	s            *Service
16930	parent       string
16931	urlParams_   gensupport.URLParams
16932	ifNoneMatch_ string
16933	ctx_         context.Context
16934	header_      http.Header
16935}
16936
16937// GetAgent: Retrieves the specified agent.
16938//
16939// - parent: The project that the agent to fetch is associated with.
16940//   Format: `projects/`.
16941func (r *ProjectsService) GetAgent(parent string) *ProjectsGetAgentCall {
16942	c := &ProjectsGetAgentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
16943	c.parent = parent
16944	return c
16945}
16946
16947// Fields allows partial responses to be retrieved. See
16948// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
16949// for more information.
16950func (c *ProjectsGetAgentCall) Fields(s ...googleapi.Field) *ProjectsGetAgentCall {
16951	c.urlParams_.Set("fields", googleapi.CombineFields(s))
16952	return c
16953}
16954
16955// IfNoneMatch sets the optional parameter which makes the operation
16956// fail if the object's ETag matches the given value. This is useful for
16957// getting updates only after the object has changed since the last
16958// request. Use googleapi.IsNotModified to check whether the response
16959// error from Do is the result of In-None-Match.
16960func (c *ProjectsGetAgentCall) IfNoneMatch(entityTag string) *ProjectsGetAgentCall {
16961	c.ifNoneMatch_ = entityTag
16962	return c
16963}
16964
16965// Context sets the context to be used in this call's Do method. Any
16966// pending HTTP request will be aborted if the provided context is
16967// canceled.
16968func (c *ProjectsGetAgentCall) Context(ctx context.Context) *ProjectsGetAgentCall {
16969	c.ctx_ = ctx
16970	return c
16971}
16972
16973// Header returns an http.Header that can be modified by the caller to
16974// add HTTP headers to the request.
16975func (c *ProjectsGetAgentCall) Header() http.Header {
16976	if c.header_ == nil {
16977		c.header_ = make(http.Header)
16978	}
16979	return c.header_
16980}
16981
16982func (c *ProjectsGetAgentCall) doRequest(alt string) (*http.Response, error) {
16983	reqHeaders := make(http.Header)
16984	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
16985	for k, v := range c.header_ {
16986		reqHeaders[k] = v
16987	}
16988	reqHeaders.Set("User-Agent", c.s.userAgent())
16989	if c.ifNoneMatch_ != "" {
16990		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
16991	}
16992	var body io.Reader = nil
16993	c.urlParams_.Set("alt", alt)
16994	c.urlParams_.Set("prettyPrint", "false")
16995	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent")
16996	urls += "?" + c.urlParams_.Encode()
16997	req, err := http.NewRequest("GET", urls, body)
16998	if err != nil {
16999		return nil, err
17000	}
17001	req.Header = reqHeaders
17002	googleapi.Expand(req.URL, map[string]string{
17003		"parent": c.parent,
17004	})
17005	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17006}
17007
17008// Do executes the "dialogflow.projects.getAgent" call.
17009// Exactly one of *GoogleCloudDialogflowV2Agent or error will be
17010// non-nil. Any non-2xx status code is an error. Response headers are in
17011// either *GoogleCloudDialogflowV2Agent.ServerResponse.Header or (if a
17012// response was returned at all) in error.(*googleapi.Error).Header. Use
17013// googleapi.IsNotModified to check whether the returned error was
17014// because http.StatusNotModified was returned.
17015func (c *ProjectsGetAgentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Agent, error) {
17016	gensupport.SetOptions(c.urlParams_, opts...)
17017	res, err := c.doRequest("json")
17018	if res != nil && res.StatusCode == http.StatusNotModified {
17019		if res.Body != nil {
17020			res.Body.Close()
17021		}
17022		return nil, &googleapi.Error{
17023			Code:   res.StatusCode,
17024			Header: res.Header,
17025		}
17026	}
17027	if err != nil {
17028		return nil, err
17029	}
17030	defer googleapi.CloseBody(res)
17031	if err := googleapi.CheckResponse(res); err != nil {
17032		return nil, err
17033	}
17034	ret := &GoogleCloudDialogflowV2Agent{
17035		ServerResponse: googleapi.ServerResponse{
17036			Header:         res.Header,
17037			HTTPStatusCode: res.StatusCode,
17038		},
17039	}
17040	target := &ret
17041	if err := gensupport.DecodeResponse(target, res); err != nil {
17042		return nil, err
17043	}
17044	return ret, nil
17045	// {
17046	//   "description": "Retrieves the specified agent.",
17047	//   "flatPath": "v2/projects/{projectsId}/agent",
17048	//   "httpMethod": "GET",
17049	//   "id": "dialogflow.projects.getAgent",
17050	//   "parameterOrder": [
17051	//     "parent"
17052	//   ],
17053	//   "parameters": {
17054	//     "parent": {
17055	//       "description": "Required. The project that the agent to fetch is associated with. Format: `projects/`.",
17056	//       "location": "path",
17057	//       "pattern": "^projects/[^/]+$",
17058	//       "required": true,
17059	//       "type": "string"
17060	//     }
17061	//   },
17062	//   "path": "v2/{+parent}/agent",
17063	//   "response": {
17064	//     "$ref": "GoogleCloudDialogflowV2Agent"
17065	//   },
17066	//   "scopes": [
17067	//     "https://www.googleapis.com/auth/cloud-platform",
17068	//     "https://www.googleapis.com/auth/dialogflow"
17069	//   ]
17070	// }
17071
17072}
17073
17074// method id "dialogflow.projects.setAgent":
17075
17076type ProjectsSetAgentCall struct {
17077	s                            *Service
17078	parent                       string
17079	googleclouddialogflowv2agent *GoogleCloudDialogflowV2Agent
17080	urlParams_                   gensupport.URLParams
17081	ctx_                         context.Context
17082	header_                      http.Header
17083}
17084
17085// SetAgent: Creates/updates the specified agent.
17086//
17087// - parent: The project of this agent. Format: `projects/`.
17088func (r *ProjectsService) SetAgent(parent string, googleclouddialogflowv2agent *GoogleCloudDialogflowV2Agent) *ProjectsSetAgentCall {
17089	c := &ProjectsSetAgentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17090	c.parent = parent
17091	c.googleclouddialogflowv2agent = googleclouddialogflowv2agent
17092	return c
17093}
17094
17095// UpdateMask sets the optional parameter "updateMask": The mask to
17096// control which fields get updated.
17097func (c *ProjectsSetAgentCall) UpdateMask(updateMask string) *ProjectsSetAgentCall {
17098	c.urlParams_.Set("updateMask", updateMask)
17099	return c
17100}
17101
17102// Fields allows partial responses to be retrieved. See
17103// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17104// for more information.
17105func (c *ProjectsSetAgentCall) Fields(s ...googleapi.Field) *ProjectsSetAgentCall {
17106	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17107	return c
17108}
17109
17110// Context sets the context to be used in this call's Do method. Any
17111// pending HTTP request will be aborted if the provided context is
17112// canceled.
17113func (c *ProjectsSetAgentCall) Context(ctx context.Context) *ProjectsSetAgentCall {
17114	c.ctx_ = ctx
17115	return c
17116}
17117
17118// Header returns an http.Header that can be modified by the caller to
17119// add HTTP headers to the request.
17120func (c *ProjectsSetAgentCall) Header() http.Header {
17121	if c.header_ == nil {
17122		c.header_ = make(http.Header)
17123	}
17124	return c.header_
17125}
17126
17127func (c *ProjectsSetAgentCall) doRequest(alt string) (*http.Response, error) {
17128	reqHeaders := make(http.Header)
17129	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
17130	for k, v := range c.header_ {
17131		reqHeaders[k] = v
17132	}
17133	reqHeaders.Set("User-Agent", c.s.userAgent())
17134	var body io.Reader = nil
17135	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2agent)
17136	if err != nil {
17137		return nil, err
17138	}
17139	reqHeaders.Set("Content-Type", "application/json")
17140	c.urlParams_.Set("alt", alt)
17141	c.urlParams_.Set("prettyPrint", "false")
17142	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent")
17143	urls += "?" + c.urlParams_.Encode()
17144	req, err := http.NewRequest("POST", urls, body)
17145	if err != nil {
17146		return nil, err
17147	}
17148	req.Header = reqHeaders
17149	googleapi.Expand(req.URL, map[string]string{
17150		"parent": c.parent,
17151	})
17152	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17153}
17154
17155// Do executes the "dialogflow.projects.setAgent" call.
17156// Exactly one of *GoogleCloudDialogflowV2Agent or error will be
17157// non-nil. Any non-2xx status code is an error. Response headers are in
17158// either *GoogleCloudDialogflowV2Agent.ServerResponse.Header or (if a
17159// response was returned at all) in error.(*googleapi.Error).Header. Use
17160// googleapi.IsNotModified to check whether the returned error was
17161// because http.StatusNotModified was returned.
17162func (c *ProjectsSetAgentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Agent, error) {
17163	gensupport.SetOptions(c.urlParams_, opts...)
17164	res, err := c.doRequest("json")
17165	if res != nil && res.StatusCode == http.StatusNotModified {
17166		if res.Body != nil {
17167			res.Body.Close()
17168		}
17169		return nil, &googleapi.Error{
17170			Code:   res.StatusCode,
17171			Header: res.Header,
17172		}
17173	}
17174	if err != nil {
17175		return nil, err
17176	}
17177	defer googleapi.CloseBody(res)
17178	if err := googleapi.CheckResponse(res); err != nil {
17179		return nil, err
17180	}
17181	ret := &GoogleCloudDialogflowV2Agent{
17182		ServerResponse: googleapi.ServerResponse{
17183			Header:         res.Header,
17184			HTTPStatusCode: res.StatusCode,
17185		},
17186	}
17187	target := &ret
17188	if err := gensupport.DecodeResponse(target, res); err != nil {
17189		return nil, err
17190	}
17191	return ret, nil
17192	// {
17193	//   "description": "Creates/updates the specified agent.",
17194	//   "flatPath": "v2/projects/{projectsId}/agent",
17195	//   "httpMethod": "POST",
17196	//   "id": "dialogflow.projects.setAgent",
17197	//   "parameterOrder": [
17198	//     "parent"
17199	//   ],
17200	//   "parameters": {
17201	//     "parent": {
17202	//       "description": "Required. The project of this agent. Format: `projects/`.",
17203	//       "location": "path",
17204	//       "pattern": "^projects/[^/]+$",
17205	//       "required": true,
17206	//       "type": "string"
17207	//     },
17208	//     "updateMask": {
17209	//       "description": "Optional. The mask to control which fields get updated.",
17210	//       "format": "google-fieldmask",
17211	//       "location": "query",
17212	//       "type": "string"
17213	//     }
17214	//   },
17215	//   "path": "v2/{+parent}/agent",
17216	//   "request": {
17217	//     "$ref": "GoogleCloudDialogflowV2Agent"
17218	//   },
17219	//   "response": {
17220	//     "$ref": "GoogleCloudDialogflowV2Agent"
17221	//   },
17222	//   "scopes": [
17223	//     "https://www.googleapis.com/auth/cloud-platform",
17224	//     "https://www.googleapis.com/auth/dialogflow"
17225	//   ]
17226	// }
17227
17228}
17229
17230// method id "dialogflow.projects.agent.export":
17231
17232type ProjectsAgentExportCall struct {
17233	s                                         *Service
17234	parent                                    string
17235	googleclouddialogflowv2exportagentrequest *GoogleCloudDialogflowV2ExportAgentRequest
17236	urlParams_                                gensupport.URLParams
17237	ctx_                                      context.Context
17238	header_                                   http.Header
17239}
17240
17241// Export: Exports the specified agent to a ZIP file. Operation
17242//
17243// - parent: The project that the agent to export is associated with.
17244//   Format: `projects/`.
17245func (r *ProjectsAgentService) Export(parent string, googleclouddialogflowv2exportagentrequest *GoogleCloudDialogflowV2ExportAgentRequest) *ProjectsAgentExportCall {
17246	c := &ProjectsAgentExportCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17247	c.parent = parent
17248	c.googleclouddialogflowv2exportagentrequest = googleclouddialogflowv2exportagentrequest
17249	return c
17250}
17251
17252// Fields allows partial responses to be retrieved. See
17253// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17254// for more information.
17255func (c *ProjectsAgentExportCall) Fields(s ...googleapi.Field) *ProjectsAgentExportCall {
17256	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17257	return c
17258}
17259
17260// Context sets the context to be used in this call's Do method. Any
17261// pending HTTP request will be aborted if the provided context is
17262// canceled.
17263func (c *ProjectsAgentExportCall) Context(ctx context.Context) *ProjectsAgentExportCall {
17264	c.ctx_ = ctx
17265	return c
17266}
17267
17268// Header returns an http.Header that can be modified by the caller to
17269// add HTTP headers to the request.
17270func (c *ProjectsAgentExportCall) Header() http.Header {
17271	if c.header_ == nil {
17272		c.header_ = make(http.Header)
17273	}
17274	return c.header_
17275}
17276
17277func (c *ProjectsAgentExportCall) doRequest(alt string) (*http.Response, error) {
17278	reqHeaders := make(http.Header)
17279	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
17280	for k, v := range c.header_ {
17281		reqHeaders[k] = v
17282	}
17283	reqHeaders.Set("User-Agent", c.s.userAgent())
17284	var body io.Reader = nil
17285	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2exportagentrequest)
17286	if err != nil {
17287		return nil, err
17288	}
17289	reqHeaders.Set("Content-Type", "application/json")
17290	c.urlParams_.Set("alt", alt)
17291	c.urlParams_.Set("prettyPrint", "false")
17292	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:export")
17293	urls += "?" + c.urlParams_.Encode()
17294	req, err := http.NewRequest("POST", urls, body)
17295	if err != nil {
17296		return nil, err
17297	}
17298	req.Header = reqHeaders
17299	googleapi.Expand(req.URL, map[string]string{
17300		"parent": c.parent,
17301	})
17302	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17303}
17304
17305// Do executes the "dialogflow.projects.agent.export" call.
17306// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
17307// Any non-2xx status code is an error. Response headers are in either
17308// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
17309// was returned at all) in error.(*googleapi.Error).Header. Use
17310// googleapi.IsNotModified to check whether the returned error was
17311// because http.StatusNotModified was returned.
17312func (c *ProjectsAgentExportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
17313	gensupport.SetOptions(c.urlParams_, opts...)
17314	res, err := c.doRequest("json")
17315	if res != nil && res.StatusCode == http.StatusNotModified {
17316		if res.Body != nil {
17317			res.Body.Close()
17318		}
17319		return nil, &googleapi.Error{
17320			Code:   res.StatusCode,
17321			Header: res.Header,
17322		}
17323	}
17324	if err != nil {
17325		return nil, err
17326	}
17327	defer googleapi.CloseBody(res)
17328	if err := googleapi.CheckResponse(res); err != nil {
17329		return nil, err
17330	}
17331	ret := &GoogleLongrunningOperation{
17332		ServerResponse: googleapi.ServerResponse{
17333			Header:         res.Header,
17334			HTTPStatusCode: res.StatusCode,
17335		},
17336	}
17337	target := &ret
17338	if err := gensupport.DecodeResponse(target, res); err != nil {
17339		return nil, err
17340	}
17341	return ret, nil
17342	// {
17343	//   "description": "Exports the specified agent to a ZIP file. Operation ",
17344	//   "flatPath": "v2/projects/{projectsId}/agent:export",
17345	//   "httpMethod": "POST",
17346	//   "id": "dialogflow.projects.agent.export",
17347	//   "parameterOrder": [
17348	//     "parent"
17349	//   ],
17350	//   "parameters": {
17351	//     "parent": {
17352	//       "description": "Required. The project that the agent to export is associated with. Format: `projects/`.",
17353	//       "location": "path",
17354	//       "pattern": "^projects/[^/]+$",
17355	//       "required": true,
17356	//       "type": "string"
17357	//     }
17358	//   },
17359	//   "path": "v2/{+parent}/agent:export",
17360	//   "request": {
17361	//     "$ref": "GoogleCloudDialogflowV2ExportAgentRequest"
17362	//   },
17363	//   "response": {
17364	//     "$ref": "GoogleLongrunningOperation"
17365	//   },
17366	//   "scopes": [
17367	//     "https://www.googleapis.com/auth/cloud-platform",
17368	//     "https://www.googleapis.com/auth/dialogflow"
17369	//   ]
17370	// }
17371
17372}
17373
17374// method id "dialogflow.projects.agent.getFulfillment":
17375
17376type ProjectsAgentGetFulfillmentCall struct {
17377	s            *Service
17378	name         string
17379	urlParams_   gensupport.URLParams
17380	ifNoneMatch_ string
17381	ctx_         context.Context
17382	header_      http.Header
17383}
17384
17385// GetFulfillment: Retrieves the fulfillment.
17386//
17387// - name: The name of the fulfillment. Format:
17388//   `projects//agent/fulfillment`.
17389func (r *ProjectsAgentService) GetFulfillment(name string) *ProjectsAgentGetFulfillmentCall {
17390	c := &ProjectsAgentGetFulfillmentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17391	c.name = name
17392	return c
17393}
17394
17395// Fields allows partial responses to be retrieved. See
17396// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17397// for more information.
17398func (c *ProjectsAgentGetFulfillmentCall) Fields(s ...googleapi.Field) *ProjectsAgentGetFulfillmentCall {
17399	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17400	return c
17401}
17402
17403// IfNoneMatch sets the optional parameter which makes the operation
17404// fail if the object's ETag matches the given value. This is useful for
17405// getting updates only after the object has changed since the last
17406// request. Use googleapi.IsNotModified to check whether the response
17407// error from Do is the result of In-None-Match.
17408func (c *ProjectsAgentGetFulfillmentCall) IfNoneMatch(entityTag string) *ProjectsAgentGetFulfillmentCall {
17409	c.ifNoneMatch_ = entityTag
17410	return c
17411}
17412
17413// Context sets the context to be used in this call's Do method. Any
17414// pending HTTP request will be aborted if the provided context is
17415// canceled.
17416func (c *ProjectsAgentGetFulfillmentCall) Context(ctx context.Context) *ProjectsAgentGetFulfillmentCall {
17417	c.ctx_ = ctx
17418	return c
17419}
17420
17421// Header returns an http.Header that can be modified by the caller to
17422// add HTTP headers to the request.
17423func (c *ProjectsAgentGetFulfillmentCall) Header() http.Header {
17424	if c.header_ == nil {
17425		c.header_ = make(http.Header)
17426	}
17427	return c.header_
17428}
17429
17430func (c *ProjectsAgentGetFulfillmentCall) doRequest(alt string) (*http.Response, error) {
17431	reqHeaders := make(http.Header)
17432	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
17433	for k, v := range c.header_ {
17434		reqHeaders[k] = v
17435	}
17436	reqHeaders.Set("User-Agent", c.s.userAgent())
17437	if c.ifNoneMatch_ != "" {
17438		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
17439	}
17440	var body io.Reader = nil
17441	c.urlParams_.Set("alt", alt)
17442	c.urlParams_.Set("prettyPrint", "false")
17443	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
17444	urls += "?" + c.urlParams_.Encode()
17445	req, err := http.NewRequest("GET", urls, body)
17446	if err != nil {
17447		return nil, err
17448	}
17449	req.Header = reqHeaders
17450	googleapi.Expand(req.URL, map[string]string{
17451		"name": c.name,
17452	})
17453	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17454}
17455
17456// Do executes the "dialogflow.projects.agent.getFulfillment" call.
17457// Exactly one of *GoogleCloudDialogflowV2Fulfillment or error will be
17458// non-nil. Any non-2xx status code is an error. Response headers are in
17459// either *GoogleCloudDialogflowV2Fulfillment.ServerResponse.Header or
17460// (if a response was returned at all) in
17461// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
17462// whether the returned error was because http.StatusNotModified was
17463// returned.
17464func (c *ProjectsAgentGetFulfillmentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Fulfillment, error) {
17465	gensupport.SetOptions(c.urlParams_, opts...)
17466	res, err := c.doRequest("json")
17467	if res != nil && res.StatusCode == http.StatusNotModified {
17468		if res.Body != nil {
17469			res.Body.Close()
17470		}
17471		return nil, &googleapi.Error{
17472			Code:   res.StatusCode,
17473			Header: res.Header,
17474		}
17475	}
17476	if err != nil {
17477		return nil, err
17478	}
17479	defer googleapi.CloseBody(res)
17480	if err := googleapi.CheckResponse(res); err != nil {
17481		return nil, err
17482	}
17483	ret := &GoogleCloudDialogflowV2Fulfillment{
17484		ServerResponse: googleapi.ServerResponse{
17485			Header:         res.Header,
17486			HTTPStatusCode: res.StatusCode,
17487		},
17488	}
17489	target := &ret
17490	if err := gensupport.DecodeResponse(target, res); err != nil {
17491		return nil, err
17492	}
17493	return ret, nil
17494	// {
17495	//   "description": "Retrieves the fulfillment.",
17496	//   "flatPath": "v2/projects/{projectsId}/agent/fulfillment",
17497	//   "httpMethod": "GET",
17498	//   "id": "dialogflow.projects.agent.getFulfillment",
17499	//   "parameterOrder": [
17500	//     "name"
17501	//   ],
17502	//   "parameters": {
17503	//     "name": {
17504	//       "description": "Required. The name of the fulfillment. Format: `projects//agent/fulfillment`.",
17505	//       "location": "path",
17506	//       "pattern": "^projects/[^/]+/agent/fulfillment$",
17507	//       "required": true,
17508	//       "type": "string"
17509	//     }
17510	//   },
17511	//   "path": "v2/{+name}",
17512	//   "response": {
17513	//     "$ref": "GoogleCloudDialogflowV2Fulfillment"
17514	//   },
17515	//   "scopes": [
17516	//     "https://www.googleapis.com/auth/cloud-platform",
17517	//     "https://www.googleapis.com/auth/dialogflow"
17518	//   ]
17519	// }
17520
17521}
17522
17523// method id "dialogflow.projects.agent.getValidationResult":
17524
17525type ProjectsAgentGetValidationResultCall struct {
17526	s            *Service
17527	parent       string
17528	urlParams_   gensupport.URLParams
17529	ifNoneMatch_ string
17530	ctx_         context.Context
17531	header_      http.Header
17532}
17533
17534// GetValidationResult: Gets agent validation result. Agent validation
17535// is performed during training time and is updated automatically when
17536// training is completed.
17537//
17538// - parent: The project that the agent is associated with. Format:
17539//   `projects/`.
17540func (r *ProjectsAgentService) GetValidationResult(parent string) *ProjectsAgentGetValidationResultCall {
17541	c := &ProjectsAgentGetValidationResultCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17542	c.parent = parent
17543	return c
17544}
17545
17546// LanguageCode sets the optional parameter "languageCode": The language
17547// for which you want a validation result. If not specified, the agent's
17548// default language is used. Many languages
17549// (https://cloud.google.com/dialogflow/docs/reference/language) are
17550// supported. Note: languages must be enabled in the agent before they
17551// can be used.
17552func (c *ProjectsAgentGetValidationResultCall) LanguageCode(languageCode string) *ProjectsAgentGetValidationResultCall {
17553	c.urlParams_.Set("languageCode", languageCode)
17554	return c
17555}
17556
17557// Fields allows partial responses to be retrieved. See
17558// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17559// for more information.
17560func (c *ProjectsAgentGetValidationResultCall) Fields(s ...googleapi.Field) *ProjectsAgentGetValidationResultCall {
17561	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17562	return c
17563}
17564
17565// IfNoneMatch sets the optional parameter which makes the operation
17566// fail if the object's ETag matches the given value. This is useful for
17567// getting updates only after the object has changed since the last
17568// request. Use googleapi.IsNotModified to check whether the response
17569// error from Do is the result of In-None-Match.
17570func (c *ProjectsAgentGetValidationResultCall) IfNoneMatch(entityTag string) *ProjectsAgentGetValidationResultCall {
17571	c.ifNoneMatch_ = entityTag
17572	return c
17573}
17574
17575// Context sets the context to be used in this call's Do method. Any
17576// pending HTTP request will be aborted if the provided context is
17577// canceled.
17578func (c *ProjectsAgentGetValidationResultCall) Context(ctx context.Context) *ProjectsAgentGetValidationResultCall {
17579	c.ctx_ = ctx
17580	return c
17581}
17582
17583// Header returns an http.Header that can be modified by the caller to
17584// add HTTP headers to the request.
17585func (c *ProjectsAgentGetValidationResultCall) Header() http.Header {
17586	if c.header_ == nil {
17587		c.header_ = make(http.Header)
17588	}
17589	return c.header_
17590}
17591
17592func (c *ProjectsAgentGetValidationResultCall) doRequest(alt string) (*http.Response, error) {
17593	reqHeaders := make(http.Header)
17594	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
17595	for k, v := range c.header_ {
17596		reqHeaders[k] = v
17597	}
17598	reqHeaders.Set("User-Agent", c.s.userAgent())
17599	if c.ifNoneMatch_ != "" {
17600		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
17601	}
17602	var body io.Reader = nil
17603	c.urlParams_.Set("alt", alt)
17604	c.urlParams_.Set("prettyPrint", "false")
17605	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent/validationResult")
17606	urls += "?" + c.urlParams_.Encode()
17607	req, err := http.NewRequest("GET", urls, body)
17608	if err != nil {
17609		return nil, err
17610	}
17611	req.Header = reqHeaders
17612	googleapi.Expand(req.URL, map[string]string{
17613		"parent": c.parent,
17614	})
17615	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17616}
17617
17618// Do executes the "dialogflow.projects.agent.getValidationResult" call.
17619// Exactly one of *GoogleCloudDialogflowV2ValidationResult or error will
17620// be non-nil. Any non-2xx status code is an error. Response headers are
17621// in either
17622// *GoogleCloudDialogflowV2ValidationResult.ServerResponse.Header or (if
17623// a response was returned at all) in error.(*googleapi.Error).Header.
17624// Use googleapi.IsNotModified to check whether the returned error was
17625// because http.StatusNotModified was returned.
17626func (c *ProjectsAgentGetValidationResultCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ValidationResult, error) {
17627	gensupport.SetOptions(c.urlParams_, opts...)
17628	res, err := c.doRequest("json")
17629	if res != nil && res.StatusCode == http.StatusNotModified {
17630		if res.Body != nil {
17631			res.Body.Close()
17632		}
17633		return nil, &googleapi.Error{
17634			Code:   res.StatusCode,
17635			Header: res.Header,
17636		}
17637	}
17638	if err != nil {
17639		return nil, err
17640	}
17641	defer googleapi.CloseBody(res)
17642	if err := googleapi.CheckResponse(res); err != nil {
17643		return nil, err
17644	}
17645	ret := &GoogleCloudDialogflowV2ValidationResult{
17646		ServerResponse: googleapi.ServerResponse{
17647			Header:         res.Header,
17648			HTTPStatusCode: res.StatusCode,
17649		},
17650	}
17651	target := &ret
17652	if err := gensupport.DecodeResponse(target, res); err != nil {
17653		return nil, err
17654	}
17655	return ret, nil
17656	// {
17657	//   "description": "Gets agent validation result. Agent validation is performed during training time and is updated automatically when training is completed.",
17658	//   "flatPath": "v2/projects/{projectsId}/agent/validationResult",
17659	//   "httpMethod": "GET",
17660	//   "id": "dialogflow.projects.agent.getValidationResult",
17661	//   "parameterOrder": [
17662	//     "parent"
17663	//   ],
17664	//   "parameters": {
17665	//     "languageCode": {
17666	//       "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.",
17667	//       "location": "query",
17668	//       "type": "string"
17669	//     },
17670	//     "parent": {
17671	//       "description": "Required. The project that the agent is associated with. Format: `projects/`.",
17672	//       "location": "path",
17673	//       "pattern": "^projects/[^/]+$",
17674	//       "required": true,
17675	//       "type": "string"
17676	//     }
17677	//   },
17678	//   "path": "v2/{+parent}/agent/validationResult",
17679	//   "response": {
17680	//     "$ref": "GoogleCloudDialogflowV2ValidationResult"
17681	//   },
17682	//   "scopes": [
17683	//     "https://www.googleapis.com/auth/cloud-platform",
17684	//     "https://www.googleapis.com/auth/dialogflow"
17685	//   ]
17686	// }
17687
17688}
17689
17690// method id "dialogflow.projects.agent.import":
17691
17692type ProjectsAgentImportCall struct {
17693	s                                         *Service
17694	parent                                    string
17695	googleclouddialogflowv2importagentrequest *GoogleCloudDialogflowV2ImportAgentRequest
17696	urlParams_                                gensupport.URLParams
17697	ctx_                                      context.Context
17698	header_                                   http.Header
17699}
17700
17701// Import: Imports the specified agent from a ZIP file. Uploads new
17702// intents and entity types without deleting the existing ones. Intents
17703// and entity types with the same name are replaced with the new
17704// versions from ImportAgentRequest. After the import, the imported
17705// draft agent will be trained automatically (unless disabled in agent
17706// settings). However, once the import is done, training may not be
17707// completed yet. Please call TrainAgent and wait for the operation it
17708// returns in order to train explicitly. Operation An operation which
17709// tracks when importing is complete. It only tracks when the draft
17710// agent is updated not when it is done training.
17711//
17712// - parent: The project that the agent to import is associated with.
17713//   Format: `projects/`.
17714func (r *ProjectsAgentService) Import(parent string, googleclouddialogflowv2importagentrequest *GoogleCloudDialogflowV2ImportAgentRequest) *ProjectsAgentImportCall {
17715	c := &ProjectsAgentImportCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17716	c.parent = parent
17717	c.googleclouddialogflowv2importagentrequest = googleclouddialogflowv2importagentrequest
17718	return c
17719}
17720
17721// Fields allows partial responses to be retrieved. See
17722// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17723// for more information.
17724func (c *ProjectsAgentImportCall) Fields(s ...googleapi.Field) *ProjectsAgentImportCall {
17725	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17726	return c
17727}
17728
17729// Context sets the context to be used in this call's Do method. Any
17730// pending HTTP request will be aborted if the provided context is
17731// canceled.
17732func (c *ProjectsAgentImportCall) Context(ctx context.Context) *ProjectsAgentImportCall {
17733	c.ctx_ = ctx
17734	return c
17735}
17736
17737// Header returns an http.Header that can be modified by the caller to
17738// add HTTP headers to the request.
17739func (c *ProjectsAgentImportCall) Header() http.Header {
17740	if c.header_ == nil {
17741		c.header_ = make(http.Header)
17742	}
17743	return c.header_
17744}
17745
17746func (c *ProjectsAgentImportCall) doRequest(alt string) (*http.Response, error) {
17747	reqHeaders := make(http.Header)
17748	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
17749	for k, v := range c.header_ {
17750		reqHeaders[k] = v
17751	}
17752	reqHeaders.Set("User-Agent", c.s.userAgent())
17753	var body io.Reader = nil
17754	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2importagentrequest)
17755	if err != nil {
17756		return nil, err
17757	}
17758	reqHeaders.Set("Content-Type", "application/json")
17759	c.urlParams_.Set("alt", alt)
17760	c.urlParams_.Set("prettyPrint", "false")
17761	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:import")
17762	urls += "?" + c.urlParams_.Encode()
17763	req, err := http.NewRequest("POST", urls, body)
17764	if err != nil {
17765		return nil, err
17766	}
17767	req.Header = reqHeaders
17768	googleapi.Expand(req.URL, map[string]string{
17769		"parent": c.parent,
17770	})
17771	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17772}
17773
17774// Do executes the "dialogflow.projects.agent.import" call.
17775// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
17776// Any non-2xx status code is an error. Response headers are in either
17777// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
17778// was returned at all) in error.(*googleapi.Error).Header. Use
17779// googleapi.IsNotModified to check whether the returned error was
17780// because http.StatusNotModified was returned.
17781func (c *ProjectsAgentImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
17782	gensupport.SetOptions(c.urlParams_, opts...)
17783	res, err := c.doRequest("json")
17784	if res != nil && res.StatusCode == http.StatusNotModified {
17785		if res.Body != nil {
17786			res.Body.Close()
17787		}
17788		return nil, &googleapi.Error{
17789			Code:   res.StatusCode,
17790			Header: res.Header,
17791		}
17792	}
17793	if err != nil {
17794		return nil, err
17795	}
17796	defer googleapi.CloseBody(res)
17797	if err := googleapi.CheckResponse(res); err != nil {
17798		return nil, err
17799	}
17800	ret := &GoogleLongrunningOperation{
17801		ServerResponse: googleapi.ServerResponse{
17802			Header:         res.Header,
17803			HTTPStatusCode: res.StatusCode,
17804		},
17805	}
17806	target := &ret
17807	if err := gensupport.DecodeResponse(target, res); err != nil {
17808		return nil, err
17809	}
17810	return ret, nil
17811	// {
17812	//   "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. Operation An operation which tracks when importing is complete. It only tracks when the draft agent is updated not when it is done training.",
17813	//   "flatPath": "v2/projects/{projectsId}/agent:import",
17814	//   "httpMethod": "POST",
17815	//   "id": "dialogflow.projects.agent.import",
17816	//   "parameterOrder": [
17817	//     "parent"
17818	//   ],
17819	//   "parameters": {
17820	//     "parent": {
17821	//       "description": "Required. The project that the agent to import is associated with. Format: `projects/`.",
17822	//       "location": "path",
17823	//       "pattern": "^projects/[^/]+$",
17824	//       "required": true,
17825	//       "type": "string"
17826	//     }
17827	//   },
17828	//   "path": "v2/{+parent}/agent:import",
17829	//   "request": {
17830	//     "$ref": "GoogleCloudDialogflowV2ImportAgentRequest"
17831	//   },
17832	//   "response": {
17833	//     "$ref": "GoogleLongrunningOperation"
17834	//   },
17835	//   "scopes": [
17836	//     "https://www.googleapis.com/auth/cloud-platform",
17837	//     "https://www.googleapis.com/auth/dialogflow"
17838	//   ]
17839	// }
17840
17841}
17842
17843// method id "dialogflow.projects.agent.restore":
17844
17845type ProjectsAgentRestoreCall struct {
17846	s                                          *Service
17847	parent                                     string
17848	googleclouddialogflowv2restoreagentrequest *GoogleCloudDialogflowV2RestoreAgentRequest
17849	urlParams_                                 gensupport.URLParams
17850	ctx_                                       context.Context
17851	header_                                    http.Header
17852}
17853
17854// Restore: Restores the specified agent from a ZIP file. Replaces the
17855// current agent version with a new one. All the intents and entity
17856// types in the older version are deleted. After the restore, the
17857// restored draft agent will be trained automatically (unless disabled
17858// in agent settings). However, once the restore is done, training may
17859// not be completed yet. Please call TrainAgent and wait for the
17860// operation it returns in order to train explicitly. Operation An
17861// operation which tracks when restoring is complete. It only tracks
17862// when the draft agent is updated not when it is done training.
17863//
17864// - parent: The project that the agent to restore is associated with.
17865//   Format: `projects/`.
17866func (r *ProjectsAgentService) Restore(parent string, googleclouddialogflowv2restoreagentrequest *GoogleCloudDialogflowV2RestoreAgentRequest) *ProjectsAgentRestoreCall {
17867	c := &ProjectsAgentRestoreCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17868	c.parent = parent
17869	c.googleclouddialogflowv2restoreagentrequest = googleclouddialogflowv2restoreagentrequest
17870	return c
17871}
17872
17873// Fields allows partial responses to be retrieved. See
17874// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17875// for more information.
17876func (c *ProjectsAgentRestoreCall) Fields(s ...googleapi.Field) *ProjectsAgentRestoreCall {
17877	c.urlParams_.Set("fields", googleapi.CombineFields(s))
17878	return c
17879}
17880
17881// Context sets the context to be used in this call's Do method. Any
17882// pending HTTP request will be aborted if the provided context is
17883// canceled.
17884func (c *ProjectsAgentRestoreCall) Context(ctx context.Context) *ProjectsAgentRestoreCall {
17885	c.ctx_ = ctx
17886	return c
17887}
17888
17889// Header returns an http.Header that can be modified by the caller to
17890// add HTTP headers to the request.
17891func (c *ProjectsAgentRestoreCall) Header() http.Header {
17892	if c.header_ == nil {
17893		c.header_ = make(http.Header)
17894	}
17895	return c.header_
17896}
17897
17898func (c *ProjectsAgentRestoreCall) doRequest(alt string) (*http.Response, error) {
17899	reqHeaders := make(http.Header)
17900	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
17901	for k, v := range c.header_ {
17902		reqHeaders[k] = v
17903	}
17904	reqHeaders.Set("User-Agent", c.s.userAgent())
17905	var body io.Reader = nil
17906	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2restoreagentrequest)
17907	if err != nil {
17908		return nil, err
17909	}
17910	reqHeaders.Set("Content-Type", "application/json")
17911	c.urlParams_.Set("alt", alt)
17912	c.urlParams_.Set("prettyPrint", "false")
17913	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:restore")
17914	urls += "?" + c.urlParams_.Encode()
17915	req, err := http.NewRequest("POST", urls, body)
17916	if err != nil {
17917		return nil, err
17918	}
17919	req.Header = reqHeaders
17920	googleapi.Expand(req.URL, map[string]string{
17921		"parent": c.parent,
17922	})
17923	return gensupport.SendRequest(c.ctx_, c.s.client, req)
17924}
17925
17926// Do executes the "dialogflow.projects.agent.restore" call.
17927// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
17928// Any non-2xx status code is an error. Response headers are in either
17929// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
17930// was returned at all) in error.(*googleapi.Error).Header. Use
17931// googleapi.IsNotModified to check whether the returned error was
17932// because http.StatusNotModified was returned.
17933func (c *ProjectsAgentRestoreCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
17934	gensupport.SetOptions(c.urlParams_, opts...)
17935	res, err := c.doRequest("json")
17936	if res != nil && res.StatusCode == http.StatusNotModified {
17937		if res.Body != nil {
17938			res.Body.Close()
17939		}
17940		return nil, &googleapi.Error{
17941			Code:   res.StatusCode,
17942			Header: res.Header,
17943		}
17944	}
17945	if err != nil {
17946		return nil, err
17947	}
17948	defer googleapi.CloseBody(res)
17949	if err := googleapi.CheckResponse(res); err != nil {
17950		return nil, err
17951	}
17952	ret := &GoogleLongrunningOperation{
17953		ServerResponse: googleapi.ServerResponse{
17954			Header:         res.Header,
17955			HTTPStatusCode: res.StatusCode,
17956		},
17957	}
17958	target := &ret
17959	if err := gensupport.DecodeResponse(target, res); err != nil {
17960		return nil, err
17961	}
17962	return ret, nil
17963	// {
17964	//   "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. Operation An operation which tracks when restoring is complete. It only tracks when the draft agent is updated not when it is done training.",
17965	//   "flatPath": "v2/projects/{projectsId}/agent:restore",
17966	//   "httpMethod": "POST",
17967	//   "id": "dialogflow.projects.agent.restore",
17968	//   "parameterOrder": [
17969	//     "parent"
17970	//   ],
17971	//   "parameters": {
17972	//     "parent": {
17973	//       "description": "Required. The project that the agent to restore is associated with. Format: `projects/`.",
17974	//       "location": "path",
17975	//       "pattern": "^projects/[^/]+$",
17976	//       "required": true,
17977	//       "type": "string"
17978	//     }
17979	//   },
17980	//   "path": "v2/{+parent}/agent:restore",
17981	//   "request": {
17982	//     "$ref": "GoogleCloudDialogflowV2RestoreAgentRequest"
17983	//   },
17984	//   "response": {
17985	//     "$ref": "GoogleLongrunningOperation"
17986	//   },
17987	//   "scopes": [
17988	//     "https://www.googleapis.com/auth/cloud-platform",
17989	//     "https://www.googleapis.com/auth/dialogflow"
17990	//   ]
17991	// }
17992
17993}
17994
17995// method id "dialogflow.projects.agent.search":
17996
17997type ProjectsAgentSearchCall struct {
17998	s            *Service
17999	parent       string
18000	urlParams_   gensupport.URLParams
18001	ifNoneMatch_ string
18002	ctx_         context.Context
18003	header_      http.Header
18004}
18005
18006// Search: Returns the list of agents. Since there is at most one
18007// conversational agent per project, this method is useful primarily for
18008// listing all agents across projects the caller has access to. One can
18009// achieve that with a wildcard project collection id "-". Refer to List
18010// Sub-Collections
18011// (https://cloud.google.com/apis/design/design_patterns#list_sub-collections).
18012//
18013// - parent: The project to list agents from. Format: `projects/`.
18014func (r *ProjectsAgentService) Search(parent string) *ProjectsAgentSearchCall {
18015	c := &ProjectsAgentSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18016	c.parent = parent
18017	return c
18018}
18019
18020// PageSize sets the optional parameter "pageSize": The maximum number
18021// of items to return in a single page. By default 100 and at most 1000.
18022func (c *ProjectsAgentSearchCall) PageSize(pageSize int64) *ProjectsAgentSearchCall {
18023	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
18024	return c
18025}
18026
18027// PageToken sets the optional parameter "pageToken": The
18028// next_page_token value returned from a previous list request.
18029func (c *ProjectsAgentSearchCall) PageToken(pageToken string) *ProjectsAgentSearchCall {
18030	c.urlParams_.Set("pageToken", pageToken)
18031	return c
18032}
18033
18034// Fields allows partial responses to be retrieved. See
18035// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18036// for more information.
18037func (c *ProjectsAgentSearchCall) Fields(s ...googleapi.Field) *ProjectsAgentSearchCall {
18038	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18039	return c
18040}
18041
18042// IfNoneMatch sets the optional parameter which makes the operation
18043// fail if the object's ETag matches the given value. This is useful for
18044// getting updates only after the object has changed since the last
18045// request. Use googleapi.IsNotModified to check whether the response
18046// error from Do is the result of In-None-Match.
18047func (c *ProjectsAgentSearchCall) IfNoneMatch(entityTag string) *ProjectsAgentSearchCall {
18048	c.ifNoneMatch_ = entityTag
18049	return c
18050}
18051
18052// Context sets the context to be used in this call's Do method. Any
18053// pending HTTP request will be aborted if the provided context is
18054// canceled.
18055func (c *ProjectsAgentSearchCall) Context(ctx context.Context) *ProjectsAgentSearchCall {
18056	c.ctx_ = ctx
18057	return c
18058}
18059
18060// Header returns an http.Header that can be modified by the caller to
18061// add HTTP headers to the request.
18062func (c *ProjectsAgentSearchCall) Header() http.Header {
18063	if c.header_ == nil {
18064		c.header_ = make(http.Header)
18065	}
18066	return c.header_
18067}
18068
18069func (c *ProjectsAgentSearchCall) doRequest(alt string) (*http.Response, error) {
18070	reqHeaders := make(http.Header)
18071	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
18072	for k, v := range c.header_ {
18073		reqHeaders[k] = v
18074	}
18075	reqHeaders.Set("User-Agent", c.s.userAgent())
18076	if c.ifNoneMatch_ != "" {
18077		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18078	}
18079	var body io.Reader = nil
18080	c.urlParams_.Set("alt", alt)
18081	c.urlParams_.Set("prettyPrint", "false")
18082	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:search")
18083	urls += "?" + c.urlParams_.Encode()
18084	req, err := http.NewRequest("GET", urls, body)
18085	if err != nil {
18086		return nil, err
18087	}
18088	req.Header = reqHeaders
18089	googleapi.Expand(req.URL, map[string]string{
18090		"parent": c.parent,
18091	})
18092	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18093}
18094
18095// Do executes the "dialogflow.projects.agent.search" call.
18096// Exactly one of *GoogleCloudDialogflowV2SearchAgentsResponse or error
18097// will be non-nil. Any non-2xx status code is an error. Response
18098// headers are in either
18099// *GoogleCloudDialogflowV2SearchAgentsResponse.ServerResponse.Header or
18100// (if a response was returned at all) in
18101// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
18102// whether the returned error was because http.StatusNotModified was
18103// returned.
18104func (c *ProjectsAgentSearchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SearchAgentsResponse, error) {
18105	gensupport.SetOptions(c.urlParams_, opts...)
18106	res, err := c.doRequest("json")
18107	if res != nil && res.StatusCode == http.StatusNotModified {
18108		if res.Body != nil {
18109			res.Body.Close()
18110		}
18111		return nil, &googleapi.Error{
18112			Code:   res.StatusCode,
18113			Header: res.Header,
18114		}
18115	}
18116	if err != nil {
18117		return nil, err
18118	}
18119	defer googleapi.CloseBody(res)
18120	if err := googleapi.CheckResponse(res); err != nil {
18121		return nil, err
18122	}
18123	ret := &GoogleCloudDialogflowV2SearchAgentsResponse{
18124		ServerResponse: googleapi.ServerResponse{
18125			Header:         res.Header,
18126			HTTPStatusCode: res.StatusCode,
18127		},
18128	}
18129	target := &ret
18130	if err := gensupport.DecodeResponse(target, res); err != nil {
18131		return nil, err
18132	}
18133	return ret, nil
18134	// {
18135	//   "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).",
18136	//   "flatPath": "v2/projects/{projectsId}/agent:search",
18137	//   "httpMethod": "GET",
18138	//   "id": "dialogflow.projects.agent.search",
18139	//   "parameterOrder": [
18140	//     "parent"
18141	//   ],
18142	//   "parameters": {
18143	//     "pageSize": {
18144	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
18145	//       "format": "int32",
18146	//       "location": "query",
18147	//       "type": "integer"
18148	//     },
18149	//     "pageToken": {
18150	//       "description": "The next_page_token value returned from a previous list request.",
18151	//       "location": "query",
18152	//       "type": "string"
18153	//     },
18154	//     "parent": {
18155	//       "description": "Required. The project to list agents from. Format: `projects/`.",
18156	//       "location": "path",
18157	//       "pattern": "^projects/[^/]+$",
18158	//       "required": true,
18159	//       "type": "string"
18160	//     }
18161	//   },
18162	//   "path": "v2/{+parent}/agent:search",
18163	//   "response": {
18164	//     "$ref": "GoogleCloudDialogflowV2SearchAgentsResponse"
18165	//   },
18166	//   "scopes": [
18167	//     "https://www.googleapis.com/auth/cloud-platform",
18168	//     "https://www.googleapis.com/auth/dialogflow"
18169	//   ]
18170	// }
18171
18172}
18173
18174// Pages invokes f for each page of results.
18175// A non-nil error returned from f will halt the iteration.
18176// The provided context supersedes any context provided to the Context method.
18177func (c *ProjectsAgentSearchCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2SearchAgentsResponse) error) error {
18178	c.ctx_ = ctx
18179	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
18180	for {
18181		x, err := c.Do()
18182		if err != nil {
18183			return err
18184		}
18185		if err := f(x); err != nil {
18186			return err
18187		}
18188		if x.NextPageToken == "" {
18189			return nil
18190		}
18191		c.PageToken(x.NextPageToken)
18192	}
18193}
18194
18195// method id "dialogflow.projects.agent.train":
18196
18197type ProjectsAgentTrainCall struct {
18198	s                                        *Service
18199	parent                                   string
18200	googleclouddialogflowv2trainagentrequest *GoogleCloudDialogflowV2TrainAgentRequest
18201	urlParams_                               gensupport.URLParams
18202	ctx_                                     context.Context
18203	header_                                  http.Header
18204}
18205
18206// Train: Trains the specified agent. Operation
18207//
18208// - parent: The project that the agent to train is associated with.
18209//   Format: `projects/`.
18210func (r *ProjectsAgentService) Train(parent string, googleclouddialogflowv2trainagentrequest *GoogleCloudDialogflowV2TrainAgentRequest) *ProjectsAgentTrainCall {
18211	c := &ProjectsAgentTrainCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18212	c.parent = parent
18213	c.googleclouddialogflowv2trainagentrequest = googleclouddialogflowv2trainagentrequest
18214	return c
18215}
18216
18217// Fields allows partial responses to be retrieved. See
18218// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18219// for more information.
18220func (c *ProjectsAgentTrainCall) Fields(s ...googleapi.Field) *ProjectsAgentTrainCall {
18221	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18222	return c
18223}
18224
18225// Context sets the context to be used in this call's Do method. Any
18226// pending HTTP request will be aborted if the provided context is
18227// canceled.
18228func (c *ProjectsAgentTrainCall) Context(ctx context.Context) *ProjectsAgentTrainCall {
18229	c.ctx_ = ctx
18230	return c
18231}
18232
18233// Header returns an http.Header that can be modified by the caller to
18234// add HTTP headers to the request.
18235func (c *ProjectsAgentTrainCall) Header() http.Header {
18236	if c.header_ == nil {
18237		c.header_ = make(http.Header)
18238	}
18239	return c.header_
18240}
18241
18242func (c *ProjectsAgentTrainCall) doRequest(alt string) (*http.Response, error) {
18243	reqHeaders := make(http.Header)
18244	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
18245	for k, v := range c.header_ {
18246		reqHeaders[k] = v
18247	}
18248	reqHeaders.Set("User-Agent", c.s.userAgent())
18249	var body io.Reader = nil
18250	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2trainagentrequest)
18251	if err != nil {
18252		return nil, err
18253	}
18254	reqHeaders.Set("Content-Type", "application/json")
18255	c.urlParams_.Set("alt", alt)
18256	c.urlParams_.Set("prettyPrint", "false")
18257	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:train")
18258	urls += "?" + c.urlParams_.Encode()
18259	req, err := http.NewRequest("POST", urls, body)
18260	if err != nil {
18261		return nil, err
18262	}
18263	req.Header = reqHeaders
18264	googleapi.Expand(req.URL, map[string]string{
18265		"parent": c.parent,
18266	})
18267	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18268}
18269
18270// Do executes the "dialogflow.projects.agent.train" call.
18271// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
18272// Any non-2xx status code is an error. Response headers are in either
18273// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
18274// was returned at all) in error.(*googleapi.Error).Header. Use
18275// googleapi.IsNotModified to check whether the returned error was
18276// because http.StatusNotModified was returned.
18277func (c *ProjectsAgentTrainCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
18278	gensupport.SetOptions(c.urlParams_, opts...)
18279	res, err := c.doRequest("json")
18280	if res != nil && res.StatusCode == http.StatusNotModified {
18281		if res.Body != nil {
18282			res.Body.Close()
18283		}
18284		return nil, &googleapi.Error{
18285			Code:   res.StatusCode,
18286			Header: res.Header,
18287		}
18288	}
18289	if err != nil {
18290		return nil, err
18291	}
18292	defer googleapi.CloseBody(res)
18293	if err := googleapi.CheckResponse(res); err != nil {
18294		return nil, err
18295	}
18296	ret := &GoogleLongrunningOperation{
18297		ServerResponse: googleapi.ServerResponse{
18298			Header:         res.Header,
18299			HTTPStatusCode: res.StatusCode,
18300		},
18301	}
18302	target := &ret
18303	if err := gensupport.DecodeResponse(target, res); err != nil {
18304		return nil, err
18305	}
18306	return ret, nil
18307	// {
18308	//   "description": "Trains the specified agent. Operation ",
18309	//   "flatPath": "v2/projects/{projectsId}/agent:train",
18310	//   "httpMethod": "POST",
18311	//   "id": "dialogflow.projects.agent.train",
18312	//   "parameterOrder": [
18313	//     "parent"
18314	//   ],
18315	//   "parameters": {
18316	//     "parent": {
18317	//       "description": "Required. The project that the agent to train is associated with. Format: `projects/`.",
18318	//       "location": "path",
18319	//       "pattern": "^projects/[^/]+$",
18320	//       "required": true,
18321	//       "type": "string"
18322	//     }
18323	//   },
18324	//   "path": "v2/{+parent}/agent:train",
18325	//   "request": {
18326	//     "$ref": "GoogleCloudDialogflowV2TrainAgentRequest"
18327	//   },
18328	//   "response": {
18329	//     "$ref": "GoogleLongrunningOperation"
18330	//   },
18331	//   "scopes": [
18332	//     "https://www.googleapis.com/auth/cloud-platform",
18333	//     "https://www.googleapis.com/auth/dialogflow"
18334	//   ]
18335	// }
18336
18337}
18338
18339// method id "dialogflow.projects.agent.updateFulfillment":
18340
18341type ProjectsAgentUpdateFulfillmentCall struct {
18342	s                                  *Service
18343	nameid                             string
18344	googleclouddialogflowv2fulfillment *GoogleCloudDialogflowV2Fulfillment
18345	urlParams_                         gensupport.URLParams
18346	ctx_                               context.Context
18347	header_                            http.Header
18348}
18349
18350// UpdateFulfillment: Updates the fulfillment.
18351//
18352// - name: The unique identifier of the fulfillment. Format:
18353//   `projects//agent/fulfillment`.
18354func (r *ProjectsAgentService) UpdateFulfillment(nameid string, googleclouddialogflowv2fulfillment *GoogleCloudDialogflowV2Fulfillment) *ProjectsAgentUpdateFulfillmentCall {
18355	c := &ProjectsAgentUpdateFulfillmentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18356	c.nameid = nameid
18357	c.googleclouddialogflowv2fulfillment = googleclouddialogflowv2fulfillment
18358	return c
18359}
18360
18361// UpdateMask sets the optional parameter "updateMask": Required. The
18362// mask to control which fields get updated. If the mask is not present,
18363// all fields will be updated.
18364func (c *ProjectsAgentUpdateFulfillmentCall) UpdateMask(updateMask string) *ProjectsAgentUpdateFulfillmentCall {
18365	c.urlParams_.Set("updateMask", updateMask)
18366	return c
18367}
18368
18369// Fields allows partial responses to be retrieved. See
18370// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18371// for more information.
18372func (c *ProjectsAgentUpdateFulfillmentCall) Fields(s ...googleapi.Field) *ProjectsAgentUpdateFulfillmentCall {
18373	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18374	return c
18375}
18376
18377// Context sets the context to be used in this call's Do method. Any
18378// pending HTTP request will be aborted if the provided context is
18379// canceled.
18380func (c *ProjectsAgentUpdateFulfillmentCall) Context(ctx context.Context) *ProjectsAgentUpdateFulfillmentCall {
18381	c.ctx_ = ctx
18382	return c
18383}
18384
18385// Header returns an http.Header that can be modified by the caller to
18386// add HTTP headers to the request.
18387func (c *ProjectsAgentUpdateFulfillmentCall) Header() http.Header {
18388	if c.header_ == nil {
18389		c.header_ = make(http.Header)
18390	}
18391	return c.header_
18392}
18393
18394func (c *ProjectsAgentUpdateFulfillmentCall) doRequest(alt string) (*http.Response, error) {
18395	reqHeaders := make(http.Header)
18396	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
18397	for k, v := range c.header_ {
18398		reqHeaders[k] = v
18399	}
18400	reqHeaders.Set("User-Agent", c.s.userAgent())
18401	var body io.Reader = nil
18402	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2fulfillment)
18403	if err != nil {
18404		return nil, err
18405	}
18406	reqHeaders.Set("Content-Type", "application/json")
18407	c.urlParams_.Set("alt", alt)
18408	c.urlParams_.Set("prettyPrint", "false")
18409	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
18410	urls += "?" + c.urlParams_.Encode()
18411	req, err := http.NewRequest("PATCH", urls, body)
18412	if err != nil {
18413		return nil, err
18414	}
18415	req.Header = reqHeaders
18416	googleapi.Expand(req.URL, map[string]string{
18417		"name": c.nameid,
18418	})
18419	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18420}
18421
18422// Do executes the "dialogflow.projects.agent.updateFulfillment" call.
18423// Exactly one of *GoogleCloudDialogflowV2Fulfillment or error will be
18424// non-nil. Any non-2xx status code is an error. Response headers are in
18425// either *GoogleCloudDialogflowV2Fulfillment.ServerResponse.Header or
18426// (if a response was returned at all) in
18427// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
18428// whether the returned error was because http.StatusNotModified was
18429// returned.
18430func (c *ProjectsAgentUpdateFulfillmentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Fulfillment, error) {
18431	gensupport.SetOptions(c.urlParams_, opts...)
18432	res, err := c.doRequest("json")
18433	if res != nil && res.StatusCode == http.StatusNotModified {
18434		if res.Body != nil {
18435			res.Body.Close()
18436		}
18437		return nil, &googleapi.Error{
18438			Code:   res.StatusCode,
18439			Header: res.Header,
18440		}
18441	}
18442	if err != nil {
18443		return nil, err
18444	}
18445	defer googleapi.CloseBody(res)
18446	if err := googleapi.CheckResponse(res); err != nil {
18447		return nil, err
18448	}
18449	ret := &GoogleCloudDialogflowV2Fulfillment{
18450		ServerResponse: googleapi.ServerResponse{
18451			Header:         res.Header,
18452			HTTPStatusCode: res.StatusCode,
18453		},
18454	}
18455	target := &ret
18456	if err := gensupport.DecodeResponse(target, res); err != nil {
18457		return nil, err
18458	}
18459	return ret, nil
18460	// {
18461	//   "description": "Updates the fulfillment.",
18462	//   "flatPath": "v2/projects/{projectsId}/agent/fulfillment",
18463	//   "httpMethod": "PATCH",
18464	//   "id": "dialogflow.projects.agent.updateFulfillment",
18465	//   "parameterOrder": [
18466	//     "name"
18467	//   ],
18468	//   "parameters": {
18469	//     "name": {
18470	//       "description": "Required. The unique identifier of the fulfillment. Format: `projects//agent/fulfillment`.",
18471	//       "location": "path",
18472	//       "pattern": "^projects/[^/]+/agent/fulfillment$",
18473	//       "required": true,
18474	//       "type": "string"
18475	//     },
18476	//     "updateMask": {
18477	//       "description": "Required. The mask to control which fields get updated. If the mask is not present, all fields will be updated.",
18478	//       "format": "google-fieldmask",
18479	//       "location": "query",
18480	//       "type": "string"
18481	//     }
18482	//   },
18483	//   "path": "v2/{+name}",
18484	//   "request": {
18485	//     "$ref": "GoogleCloudDialogflowV2Fulfillment"
18486	//   },
18487	//   "response": {
18488	//     "$ref": "GoogleCloudDialogflowV2Fulfillment"
18489	//   },
18490	//   "scopes": [
18491	//     "https://www.googleapis.com/auth/cloud-platform",
18492	//     "https://www.googleapis.com/auth/dialogflow"
18493	//   ]
18494	// }
18495
18496}
18497
18498// method id "dialogflow.projects.agent.entityTypes.batchDelete":
18499
18500type ProjectsAgentEntityTypesBatchDeleteCall struct {
18501	s                                                    *Service
18502	parent                                               string
18503	googleclouddialogflowv2batchdeleteentitytypesrequest *GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest
18504	urlParams_                                           gensupport.URLParams
18505	ctx_                                                 context.Context
18506	header_                                              http.Header
18507}
18508
18509// BatchDelete: Deletes entity types in the specified agent. Operation
18510//
18511// - parent: The name of the agent to delete all entities types for.
18512//   Format: `projects//agent`.
18513func (r *ProjectsAgentEntityTypesService) BatchDelete(parent string, googleclouddialogflowv2batchdeleteentitytypesrequest *GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest) *ProjectsAgentEntityTypesBatchDeleteCall {
18514	c := &ProjectsAgentEntityTypesBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18515	c.parent = parent
18516	c.googleclouddialogflowv2batchdeleteentitytypesrequest = googleclouddialogflowv2batchdeleteentitytypesrequest
18517	return c
18518}
18519
18520// Fields allows partial responses to be retrieved. See
18521// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18522// for more information.
18523func (c *ProjectsAgentEntityTypesBatchDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesBatchDeleteCall {
18524	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18525	return c
18526}
18527
18528// Context sets the context to be used in this call's Do method. Any
18529// pending HTTP request will be aborted if the provided context is
18530// canceled.
18531func (c *ProjectsAgentEntityTypesBatchDeleteCall) Context(ctx context.Context) *ProjectsAgentEntityTypesBatchDeleteCall {
18532	c.ctx_ = ctx
18533	return c
18534}
18535
18536// Header returns an http.Header that can be modified by the caller to
18537// add HTTP headers to the request.
18538func (c *ProjectsAgentEntityTypesBatchDeleteCall) Header() http.Header {
18539	if c.header_ == nil {
18540		c.header_ = make(http.Header)
18541	}
18542	return c.header_
18543}
18544
18545func (c *ProjectsAgentEntityTypesBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
18546	reqHeaders := make(http.Header)
18547	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
18548	for k, v := range c.header_ {
18549		reqHeaders[k] = v
18550	}
18551	reqHeaders.Set("User-Agent", c.s.userAgent())
18552	var body io.Reader = nil
18553	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchdeleteentitytypesrequest)
18554	if err != nil {
18555		return nil, err
18556	}
18557	reqHeaders.Set("Content-Type", "application/json")
18558	c.urlParams_.Set("alt", alt)
18559	c.urlParams_.Set("prettyPrint", "false")
18560	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes:batchDelete")
18561	urls += "?" + c.urlParams_.Encode()
18562	req, err := http.NewRequest("POST", urls, body)
18563	if err != nil {
18564		return nil, err
18565	}
18566	req.Header = reqHeaders
18567	googleapi.Expand(req.URL, map[string]string{
18568		"parent": c.parent,
18569	})
18570	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18571}
18572
18573// Do executes the "dialogflow.projects.agent.entityTypes.batchDelete" call.
18574// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
18575// Any non-2xx status code is an error. Response headers are in either
18576// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
18577// was returned at all) in error.(*googleapi.Error).Header. Use
18578// googleapi.IsNotModified to check whether the returned error was
18579// because http.StatusNotModified was returned.
18580func (c *ProjectsAgentEntityTypesBatchDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
18581	gensupport.SetOptions(c.urlParams_, opts...)
18582	res, err := c.doRequest("json")
18583	if res != nil && res.StatusCode == http.StatusNotModified {
18584		if res.Body != nil {
18585			res.Body.Close()
18586		}
18587		return nil, &googleapi.Error{
18588			Code:   res.StatusCode,
18589			Header: res.Header,
18590		}
18591	}
18592	if err != nil {
18593		return nil, err
18594	}
18595	defer googleapi.CloseBody(res)
18596	if err := googleapi.CheckResponse(res); err != nil {
18597		return nil, err
18598	}
18599	ret := &GoogleLongrunningOperation{
18600		ServerResponse: googleapi.ServerResponse{
18601			Header:         res.Header,
18602			HTTPStatusCode: res.StatusCode,
18603		},
18604	}
18605	target := &ret
18606	if err := gensupport.DecodeResponse(target, res); err != nil {
18607		return nil, err
18608	}
18609	return ret, nil
18610	// {
18611	//   "description": "Deletes entity types in the specified agent. Operation ",
18612	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes:batchDelete",
18613	//   "httpMethod": "POST",
18614	//   "id": "dialogflow.projects.agent.entityTypes.batchDelete",
18615	//   "parameterOrder": [
18616	//     "parent"
18617	//   ],
18618	//   "parameters": {
18619	//     "parent": {
18620	//       "description": "Required. The name of the agent to delete all entities types for. Format: `projects//agent`.",
18621	//       "location": "path",
18622	//       "pattern": "^projects/[^/]+/agent$",
18623	//       "required": true,
18624	//       "type": "string"
18625	//     }
18626	//   },
18627	//   "path": "v2/{+parent}/entityTypes:batchDelete",
18628	//   "request": {
18629	//     "$ref": "GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest"
18630	//   },
18631	//   "response": {
18632	//     "$ref": "GoogleLongrunningOperation"
18633	//   },
18634	//   "scopes": [
18635	//     "https://www.googleapis.com/auth/cloud-platform",
18636	//     "https://www.googleapis.com/auth/dialogflow"
18637	//   ]
18638	// }
18639
18640}
18641
18642// method id "dialogflow.projects.agent.entityTypes.batchUpdate":
18643
18644type ProjectsAgentEntityTypesBatchUpdateCall struct {
18645	s                                                    *Service
18646	parent                                               string
18647	googleclouddialogflowv2batchupdateentitytypesrequest *GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest
18648	urlParams_                                           gensupport.URLParams
18649	ctx_                                                 context.Context
18650	header_                                              http.Header
18651}
18652
18653// BatchUpdate: Updates/Creates multiple entity types in the specified
18654// agent. Operation
18655//
18656// - parent: The name of the agent to update or create entity types in.
18657//   Format: `projects//agent`.
18658func (r *ProjectsAgentEntityTypesService) BatchUpdate(parent string, googleclouddialogflowv2batchupdateentitytypesrequest *GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest) *ProjectsAgentEntityTypesBatchUpdateCall {
18659	c := &ProjectsAgentEntityTypesBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18660	c.parent = parent
18661	c.googleclouddialogflowv2batchupdateentitytypesrequest = googleclouddialogflowv2batchupdateentitytypesrequest
18662	return c
18663}
18664
18665// Fields allows partial responses to be retrieved. See
18666// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18667// for more information.
18668func (c *ProjectsAgentEntityTypesBatchUpdateCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesBatchUpdateCall {
18669	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18670	return c
18671}
18672
18673// Context sets the context to be used in this call's Do method. Any
18674// pending HTTP request will be aborted if the provided context is
18675// canceled.
18676func (c *ProjectsAgentEntityTypesBatchUpdateCall) Context(ctx context.Context) *ProjectsAgentEntityTypesBatchUpdateCall {
18677	c.ctx_ = ctx
18678	return c
18679}
18680
18681// Header returns an http.Header that can be modified by the caller to
18682// add HTTP headers to the request.
18683func (c *ProjectsAgentEntityTypesBatchUpdateCall) Header() http.Header {
18684	if c.header_ == nil {
18685		c.header_ = make(http.Header)
18686	}
18687	return c.header_
18688}
18689
18690func (c *ProjectsAgentEntityTypesBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
18691	reqHeaders := make(http.Header)
18692	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
18693	for k, v := range c.header_ {
18694		reqHeaders[k] = v
18695	}
18696	reqHeaders.Set("User-Agent", c.s.userAgent())
18697	var body io.Reader = nil
18698	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchupdateentitytypesrequest)
18699	if err != nil {
18700		return nil, err
18701	}
18702	reqHeaders.Set("Content-Type", "application/json")
18703	c.urlParams_.Set("alt", alt)
18704	c.urlParams_.Set("prettyPrint", "false")
18705	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes:batchUpdate")
18706	urls += "?" + c.urlParams_.Encode()
18707	req, err := http.NewRequest("POST", urls, body)
18708	if err != nil {
18709		return nil, err
18710	}
18711	req.Header = reqHeaders
18712	googleapi.Expand(req.URL, map[string]string{
18713		"parent": c.parent,
18714	})
18715	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18716}
18717
18718// Do executes the "dialogflow.projects.agent.entityTypes.batchUpdate" call.
18719// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
18720// Any non-2xx status code is an error. Response headers are in either
18721// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
18722// was returned at all) in error.(*googleapi.Error).Header. Use
18723// googleapi.IsNotModified to check whether the returned error was
18724// because http.StatusNotModified was returned.
18725func (c *ProjectsAgentEntityTypesBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
18726	gensupport.SetOptions(c.urlParams_, opts...)
18727	res, err := c.doRequest("json")
18728	if res != nil && res.StatusCode == http.StatusNotModified {
18729		if res.Body != nil {
18730			res.Body.Close()
18731		}
18732		return nil, &googleapi.Error{
18733			Code:   res.StatusCode,
18734			Header: res.Header,
18735		}
18736	}
18737	if err != nil {
18738		return nil, err
18739	}
18740	defer googleapi.CloseBody(res)
18741	if err := googleapi.CheckResponse(res); err != nil {
18742		return nil, err
18743	}
18744	ret := &GoogleLongrunningOperation{
18745		ServerResponse: googleapi.ServerResponse{
18746			Header:         res.Header,
18747			HTTPStatusCode: res.StatusCode,
18748		},
18749	}
18750	target := &ret
18751	if err := gensupport.DecodeResponse(target, res); err != nil {
18752		return nil, err
18753	}
18754	return ret, nil
18755	// {
18756	//   "description": "Updates/Creates multiple entity types in the specified agent. Operation ",
18757	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes:batchUpdate",
18758	//   "httpMethod": "POST",
18759	//   "id": "dialogflow.projects.agent.entityTypes.batchUpdate",
18760	//   "parameterOrder": [
18761	//     "parent"
18762	//   ],
18763	//   "parameters": {
18764	//     "parent": {
18765	//       "description": "Required. The name of the agent to update or create entity types in. Format: `projects//agent`.",
18766	//       "location": "path",
18767	//       "pattern": "^projects/[^/]+/agent$",
18768	//       "required": true,
18769	//       "type": "string"
18770	//     }
18771	//   },
18772	//   "path": "v2/{+parent}/entityTypes:batchUpdate",
18773	//   "request": {
18774	//     "$ref": "GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest"
18775	//   },
18776	//   "response": {
18777	//     "$ref": "GoogleLongrunningOperation"
18778	//   },
18779	//   "scopes": [
18780	//     "https://www.googleapis.com/auth/cloud-platform",
18781	//     "https://www.googleapis.com/auth/dialogflow"
18782	//   ]
18783	// }
18784
18785}
18786
18787// method id "dialogflow.projects.agent.entityTypes.create":
18788
18789type ProjectsAgentEntityTypesCreateCall struct {
18790	s                                 *Service
18791	parent                            string
18792	googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType
18793	urlParams_                        gensupport.URLParams
18794	ctx_                              context.Context
18795	header_                           http.Header
18796}
18797
18798// Create: Creates an entity type in the specified agent.
18799//
18800// - parent: The agent to create a entity type for. Format:
18801//   `projects//agent`.
18802func (r *ProjectsAgentEntityTypesService) Create(parent string, googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType) *ProjectsAgentEntityTypesCreateCall {
18803	c := &ProjectsAgentEntityTypesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18804	c.parent = parent
18805	c.googleclouddialogflowv2entitytype = googleclouddialogflowv2entitytype
18806	return c
18807}
18808
18809// LanguageCode sets the optional parameter "languageCode": The language
18810// used to access language-specific data. If not specified, the agent's
18811// default language is used. For more information, see Multilingual
18812// intent and entity data
18813// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
18814func (c *ProjectsAgentEntityTypesCreateCall) LanguageCode(languageCode string) *ProjectsAgentEntityTypesCreateCall {
18815	c.urlParams_.Set("languageCode", languageCode)
18816	return c
18817}
18818
18819// Fields allows partial responses to be retrieved. See
18820// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18821// for more information.
18822func (c *ProjectsAgentEntityTypesCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesCreateCall {
18823	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18824	return c
18825}
18826
18827// Context sets the context to be used in this call's Do method. Any
18828// pending HTTP request will be aborted if the provided context is
18829// canceled.
18830func (c *ProjectsAgentEntityTypesCreateCall) Context(ctx context.Context) *ProjectsAgentEntityTypesCreateCall {
18831	c.ctx_ = ctx
18832	return c
18833}
18834
18835// Header returns an http.Header that can be modified by the caller to
18836// add HTTP headers to the request.
18837func (c *ProjectsAgentEntityTypesCreateCall) Header() http.Header {
18838	if c.header_ == nil {
18839		c.header_ = make(http.Header)
18840	}
18841	return c.header_
18842}
18843
18844func (c *ProjectsAgentEntityTypesCreateCall) doRequest(alt string) (*http.Response, error) {
18845	reqHeaders := make(http.Header)
18846	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
18847	for k, v := range c.header_ {
18848		reqHeaders[k] = v
18849	}
18850	reqHeaders.Set("User-Agent", c.s.userAgent())
18851	var body io.Reader = nil
18852	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2entitytype)
18853	if err != nil {
18854		return nil, err
18855	}
18856	reqHeaders.Set("Content-Type", "application/json")
18857	c.urlParams_.Set("alt", alt)
18858	c.urlParams_.Set("prettyPrint", "false")
18859	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
18860	urls += "?" + c.urlParams_.Encode()
18861	req, err := http.NewRequest("POST", urls, body)
18862	if err != nil {
18863		return nil, err
18864	}
18865	req.Header = reqHeaders
18866	googleapi.Expand(req.URL, map[string]string{
18867		"parent": c.parent,
18868	})
18869	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18870}
18871
18872// Do executes the "dialogflow.projects.agent.entityTypes.create" call.
18873// Exactly one of *GoogleCloudDialogflowV2EntityType or error will be
18874// non-nil. Any non-2xx status code is an error. Response headers are in
18875// either *GoogleCloudDialogflowV2EntityType.ServerResponse.Header or
18876// (if a response was returned at all) in
18877// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
18878// whether the returned error was because http.StatusNotModified was
18879// returned.
18880func (c *ProjectsAgentEntityTypesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EntityType, error) {
18881	gensupport.SetOptions(c.urlParams_, opts...)
18882	res, err := c.doRequest("json")
18883	if res != nil && res.StatusCode == http.StatusNotModified {
18884		if res.Body != nil {
18885			res.Body.Close()
18886		}
18887		return nil, &googleapi.Error{
18888			Code:   res.StatusCode,
18889			Header: res.Header,
18890		}
18891	}
18892	if err != nil {
18893		return nil, err
18894	}
18895	defer googleapi.CloseBody(res)
18896	if err := googleapi.CheckResponse(res); err != nil {
18897		return nil, err
18898	}
18899	ret := &GoogleCloudDialogflowV2EntityType{
18900		ServerResponse: googleapi.ServerResponse{
18901			Header:         res.Header,
18902			HTTPStatusCode: res.StatusCode,
18903		},
18904	}
18905	target := &ret
18906	if err := gensupport.DecodeResponse(target, res); err != nil {
18907		return nil, err
18908	}
18909	return ret, nil
18910	// {
18911	//   "description": "Creates an entity type in the specified agent.",
18912	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes",
18913	//   "httpMethod": "POST",
18914	//   "id": "dialogflow.projects.agent.entityTypes.create",
18915	//   "parameterOrder": [
18916	//     "parent"
18917	//   ],
18918	//   "parameters": {
18919	//     "languageCode": {
18920	//       "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).",
18921	//       "location": "query",
18922	//       "type": "string"
18923	//     },
18924	//     "parent": {
18925	//       "description": "Required. The agent to create a entity type for. Format: `projects//agent`.",
18926	//       "location": "path",
18927	//       "pattern": "^projects/[^/]+/agent$",
18928	//       "required": true,
18929	//       "type": "string"
18930	//     }
18931	//   },
18932	//   "path": "v2/{+parent}/entityTypes",
18933	//   "request": {
18934	//     "$ref": "GoogleCloudDialogflowV2EntityType"
18935	//   },
18936	//   "response": {
18937	//     "$ref": "GoogleCloudDialogflowV2EntityType"
18938	//   },
18939	//   "scopes": [
18940	//     "https://www.googleapis.com/auth/cloud-platform",
18941	//     "https://www.googleapis.com/auth/dialogflow"
18942	//   ]
18943	// }
18944
18945}
18946
18947// method id "dialogflow.projects.agent.entityTypes.delete":
18948
18949type ProjectsAgentEntityTypesDeleteCall struct {
18950	s          *Service
18951	name       string
18952	urlParams_ gensupport.URLParams
18953	ctx_       context.Context
18954	header_    http.Header
18955}
18956
18957// Delete: Deletes the specified entity type.
18958//
18959// - name: The name of the entity type to delete. Format:
18960//   `projects//agent/entityTypes/`.
18961func (r *ProjectsAgentEntityTypesService) Delete(name string) *ProjectsAgentEntityTypesDeleteCall {
18962	c := &ProjectsAgentEntityTypesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18963	c.name = name
18964	return c
18965}
18966
18967// Fields allows partial responses to be retrieved. See
18968// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18969// for more information.
18970func (c *ProjectsAgentEntityTypesDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesDeleteCall {
18971	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18972	return c
18973}
18974
18975// Context sets the context to be used in this call's Do method. Any
18976// pending HTTP request will be aborted if the provided context is
18977// canceled.
18978func (c *ProjectsAgentEntityTypesDeleteCall) Context(ctx context.Context) *ProjectsAgentEntityTypesDeleteCall {
18979	c.ctx_ = ctx
18980	return c
18981}
18982
18983// Header returns an http.Header that can be modified by the caller to
18984// add HTTP headers to the request.
18985func (c *ProjectsAgentEntityTypesDeleteCall) Header() http.Header {
18986	if c.header_ == nil {
18987		c.header_ = make(http.Header)
18988	}
18989	return c.header_
18990}
18991
18992func (c *ProjectsAgentEntityTypesDeleteCall) doRequest(alt string) (*http.Response, error) {
18993	reqHeaders := make(http.Header)
18994	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
18995	for k, v := range c.header_ {
18996		reqHeaders[k] = v
18997	}
18998	reqHeaders.Set("User-Agent", c.s.userAgent())
18999	var body io.Reader = nil
19000	c.urlParams_.Set("alt", alt)
19001	c.urlParams_.Set("prettyPrint", "false")
19002	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
19003	urls += "?" + c.urlParams_.Encode()
19004	req, err := http.NewRequest("DELETE", urls, body)
19005	if err != nil {
19006		return nil, err
19007	}
19008	req.Header = reqHeaders
19009	googleapi.Expand(req.URL, map[string]string{
19010		"name": c.name,
19011	})
19012	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19013}
19014
19015// Do executes the "dialogflow.projects.agent.entityTypes.delete" call.
19016// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
19017// non-2xx status code is an error. Response headers are in either
19018// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
19019// returned at all) in error.(*googleapi.Error).Header. Use
19020// googleapi.IsNotModified to check whether the returned error was
19021// because http.StatusNotModified was returned.
19022func (c *ProjectsAgentEntityTypesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
19023	gensupport.SetOptions(c.urlParams_, opts...)
19024	res, err := c.doRequest("json")
19025	if res != nil && res.StatusCode == http.StatusNotModified {
19026		if res.Body != nil {
19027			res.Body.Close()
19028		}
19029		return nil, &googleapi.Error{
19030			Code:   res.StatusCode,
19031			Header: res.Header,
19032		}
19033	}
19034	if err != nil {
19035		return nil, err
19036	}
19037	defer googleapi.CloseBody(res)
19038	if err := googleapi.CheckResponse(res); err != nil {
19039		return nil, err
19040	}
19041	ret := &GoogleProtobufEmpty{
19042		ServerResponse: googleapi.ServerResponse{
19043			Header:         res.Header,
19044			HTTPStatusCode: res.StatusCode,
19045		},
19046	}
19047	target := &ret
19048	if err := gensupport.DecodeResponse(target, res); err != nil {
19049		return nil, err
19050	}
19051	return ret, nil
19052	// {
19053	//   "description": "Deletes the specified entity type.",
19054	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes/{entityTypesId}",
19055	//   "httpMethod": "DELETE",
19056	//   "id": "dialogflow.projects.agent.entityTypes.delete",
19057	//   "parameterOrder": [
19058	//     "name"
19059	//   ],
19060	//   "parameters": {
19061	//     "name": {
19062	//       "description": "Required. The name of the entity type to delete. Format: `projects//agent/entityTypes/`.",
19063	//       "location": "path",
19064	//       "pattern": "^projects/[^/]+/agent/entityTypes/[^/]+$",
19065	//       "required": true,
19066	//       "type": "string"
19067	//     }
19068	//   },
19069	//   "path": "v2/{+name}",
19070	//   "response": {
19071	//     "$ref": "GoogleProtobufEmpty"
19072	//   },
19073	//   "scopes": [
19074	//     "https://www.googleapis.com/auth/cloud-platform",
19075	//     "https://www.googleapis.com/auth/dialogflow"
19076	//   ]
19077	// }
19078
19079}
19080
19081// method id "dialogflow.projects.agent.entityTypes.get":
19082
19083type ProjectsAgentEntityTypesGetCall struct {
19084	s            *Service
19085	name         string
19086	urlParams_   gensupport.URLParams
19087	ifNoneMatch_ string
19088	ctx_         context.Context
19089	header_      http.Header
19090}
19091
19092// Get: Retrieves the specified entity type.
19093//
19094// - name: The name of the entity type. Format:
19095//   `projects//agent/entityTypes/`.
19096func (r *ProjectsAgentEntityTypesService) Get(name string) *ProjectsAgentEntityTypesGetCall {
19097	c := &ProjectsAgentEntityTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19098	c.name = name
19099	return c
19100}
19101
19102// LanguageCode sets the optional parameter "languageCode": The language
19103// used to access language-specific data. If not specified, the agent's
19104// default language is used. For more information, see Multilingual
19105// intent and entity data
19106// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
19107func (c *ProjectsAgentEntityTypesGetCall) LanguageCode(languageCode string) *ProjectsAgentEntityTypesGetCall {
19108	c.urlParams_.Set("languageCode", languageCode)
19109	return c
19110}
19111
19112// Fields allows partial responses to be retrieved. See
19113// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19114// for more information.
19115func (c *ProjectsAgentEntityTypesGetCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesGetCall {
19116	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19117	return c
19118}
19119
19120// IfNoneMatch sets the optional parameter which makes the operation
19121// fail if the object's ETag matches the given value. This is useful for
19122// getting updates only after the object has changed since the last
19123// request. Use googleapi.IsNotModified to check whether the response
19124// error from Do is the result of In-None-Match.
19125func (c *ProjectsAgentEntityTypesGetCall) IfNoneMatch(entityTag string) *ProjectsAgentEntityTypesGetCall {
19126	c.ifNoneMatch_ = entityTag
19127	return c
19128}
19129
19130// Context sets the context to be used in this call's Do method. Any
19131// pending HTTP request will be aborted if the provided context is
19132// canceled.
19133func (c *ProjectsAgentEntityTypesGetCall) Context(ctx context.Context) *ProjectsAgentEntityTypesGetCall {
19134	c.ctx_ = ctx
19135	return c
19136}
19137
19138// Header returns an http.Header that can be modified by the caller to
19139// add HTTP headers to the request.
19140func (c *ProjectsAgentEntityTypesGetCall) Header() http.Header {
19141	if c.header_ == nil {
19142		c.header_ = make(http.Header)
19143	}
19144	return c.header_
19145}
19146
19147func (c *ProjectsAgentEntityTypesGetCall) doRequest(alt string) (*http.Response, error) {
19148	reqHeaders := make(http.Header)
19149	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
19150	for k, v := range c.header_ {
19151		reqHeaders[k] = v
19152	}
19153	reqHeaders.Set("User-Agent", c.s.userAgent())
19154	if c.ifNoneMatch_ != "" {
19155		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19156	}
19157	var body io.Reader = nil
19158	c.urlParams_.Set("alt", alt)
19159	c.urlParams_.Set("prettyPrint", "false")
19160	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
19161	urls += "?" + c.urlParams_.Encode()
19162	req, err := http.NewRequest("GET", urls, body)
19163	if err != nil {
19164		return nil, err
19165	}
19166	req.Header = reqHeaders
19167	googleapi.Expand(req.URL, map[string]string{
19168		"name": c.name,
19169	})
19170	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19171}
19172
19173// Do executes the "dialogflow.projects.agent.entityTypes.get" call.
19174// Exactly one of *GoogleCloudDialogflowV2EntityType or error will be
19175// non-nil. Any non-2xx status code is an error. Response headers are in
19176// either *GoogleCloudDialogflowV2EntityType.ServerResponse.Header or
19177// (if a response was returned at all) in
19178// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
19179// whether the returned error was because http.StatusNotModified was
19180// returned.
19181func (c *ProjectsAgentEntityTypesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EntityType, error) {
19182	gensupport.SetOptions(c.urlParams_, opts...)
19183	res, err := c.doRequest("json")
19184	if res != nil && res.StatusCode == http.StatusNotModified {
19185		if res.Body != nil {
19186			res.Body.Close()
19187		}
19188		return nil, &googleapi.Error{
19189			Code:   res.StatusCode,
19190			Header: res.Header,
19191		}
19192	}
19193	if err != nil {
19194		return nil, err
19195	}
19196	defer googleapi.CloseBody(res)
19197	if err := googleapi.CheckResponse(res); err != nil {
19198		return nil, err
19199	}
19200	ret := &GoogleCloudDialogflowV2EntityType{
19201		ServerResponse: googleapi.ServerResponse{
19202			Header:         res.Header,
19203			HTTPStatusCode: res.StatusCode,
19204		},
19205	}
19206	target := &ret
19207	if err := gensupport.DecodeResponse(target, res); err != nil {
19208		return nil, err
19209	}
19210	return ret, nil
19211	// {
19212	//   "description": "Retrieves the specified entity type.",
19213	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes/{entityTypesId}",
19214	//   "httpMethod": "GET",
19215	//   "id": "dialogflow.projects.agent.entityTypes.get",
19216	//   "parameterOrder": [
19217	//     "name"
19218	//   ],
19219	//   "parameters": {
19220	//     "languageCode": {
19221	//       "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).",
19222	//       "location": "query",
19223	//       "type": "string"
19224	//     },
19225	//     "name": {
19226	//       "description": "Required. The name of the entity type. Format: `projects//agent/entityTypes/`.",
19227	//       "location": "path",
19228	//       "pattern": "^projects/[^/]+/agent/entityTypes/[^/]+$",
19229	//       "required": true,
19230	//       "type": "string"
19231	//     }
19232	//   },
19233	//   "path": "v2/{+name}",
19234	//   "response": {
19235	//     "$ref": "GoogleCloudDialogflowV2EntityType"
19236	//   },
19237	//   "scopes": [
19238	//     "https://www.googleapis.com/auth/cloud-platform",
19239	//     "https://www.googleapis.com/auth/dialogflow"
19240	//   ]
19241	// }
19242
19243}
19244
19245// method id "dialogflow.projects.agent.entityTypes.list":
19246
19247type ProjectsAgentEntityTypesListCall struct {
19248	s            *Service
19249	parent       string
19250	urlParams_   gensupport.URLParams
19251	ifNoneMatch_ string
19252	ctx_         context.Context
19253	header_      http.Header
19254}
19255
19256// List: Returns the list of all entity types in the specified agent.
19257//
19258// - parent: The agent to list all entity types from. Format:
19259//   `projects//agent`.
19260func (r *ProjectsAgentEntityTypesService) List(parent string) *ProjectsAgentEntityTypesListCall {
19261	c := &ProjectsAgentEntityTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19262	c.parent = parent
19263	return c
19264}
19265
19266// LanguageCode sets the optional parameter "languageCode": The language
19267// used to access language-specific data. If not specified, the agent's
19268// default language is used. For more information, see Multilingual
19269// intent and entity data
19270// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
19271func (c *ProjectsAgentEntityTypesListCall) LanguageCode(languageCode string) *ProjectsAgentEntityTypesListCall {
19272	c.urlParams_.Set("languageCode", languageCode)
19273	return c
19274}
19275
19276// PageSize sets the optional parameter "pageSize": The maximum number
19277// of items to return in a single page. By default 100 and at most 1000.
19278func (c *ProjectsAgentEntityTypesListCall) PageSize(pageSize int64) *ProjectsAgentEntityTypesListCall {
19279	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
19280	return c
19281}
19282
19283// PageToken sets the optional parameter "pageToken": The
19284// next_page_token value returned from a previous list request.
19285func (c *ProjectsAgentEntityTypesListCall) PageToken(pageToken string) *ProjectsAgentEntityTypesListCall {
19286	c.urlParams_.Set("pageToken", pageToken)
19287	return c
19288}
19289
19290// Fields allows partial responses to be retrieved. See
19291// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19292// for more information.
19293func (c *ProjectsAgentEntityTypesListCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesListCall {
19294	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19295	return c
19296}
19297
19298// IfNoneMatch sets the optional parameter which makes the operation
19299// fail if the object's ETag matches the given value. This is useful for
19300// getting updates only after the object has changed since the last
19301// request. Use googleapi.IsNotModified to check whether the response
19302// error from Do is the result of In-None-Match.
19303func (c *ProjectsAgentEntityTypesListCall) IfNoneMatch(entityTag string) *ProjectsAgentEntityTypesListCall {
19304	c.ifNoneMatch_ = entityTag
19305	return c
19306}
19307
19308// Context sets the context to be used in this call's Do method. Any
19309// pending HTTP request will be aborted if the provided context is
19310// canceled.
19311func (c *ProjectsAgentEntityTypesListCall) Context(ctx context.Context) *ProjectsAgentEntityTypesListCall {
19312	c.ctx_ = ctx
19313	return c
19314}
19315
19316// Header returns an http.Header that can be modified by the caller to
19317// add HTTP headers to the request.
19318func (c *ProjectsAgentEntityTypesListCall) Header() http.Header {
19319	if c.header_ == nil {
19320		c.header_ = make(http.Header)
19321	}
19322	return c.header_
19323}
19324
19325func (c *ProjectsAgentEntityTypesListCall) doRequest(alt string) (*http.Response, error) {
19326	reqHeaders := make(http.Header)
19327	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
19328	for k, v := range c.header_ {
19329		reqHeaders[k] = v
19330	}
19331	reqHeaders.Set("User-Agent", c.s.userAgent())
19332	if c.ifNoneMatch_ != "" {
19333		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19334	}
19335	var body io.Reader = nil
19336	c.urlParams_.Set("alt", alt)
19337	c.urlParams_.Set("prettyPrint", "false")
19338	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
19339	urls += "?" + c.urlParams_.Encode()
19340	req, err := http.NewRequest("GET", urls, body)
19341	if err != nil {
19342		return nil, err
19343	}
19344	req.Header = reqHeaders
19345	googleapi.Expand(req.URL, map[string]string{
19346		"parent": c.parent,
19347	})
19348	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19349}
19350
19351// Do executes the "dialogflow.projects.agent.entityTypes.list" call.
19352// Exactly one of *GoogleCloudDialogflowV2ListEntityTypesResponse or
19353// error will be non-nil. Any non-2xx status code is an error. Response
19354// headers are in either
19355// *GoogleCloudDialogflowV2ListEntityTypesResponse.ServerResponse.Header
19356// or (if a response was returned at all) in
19357// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
19358// whether the returned error was because http.StatusNotModified was
19359// returned.
19360func (c *ProjectsAgentEntityTypesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListEntityTypesResponse, error) {
19361	gensupport.SetOptions(c.urlParams_, opts...)
19362	res, err := c.doRequest("json")
19363	if res != nil && res.StatusCode == http.StatusNotModified {
19364		if res.Body != nil {
19365			res.Body.Close()
19366		}
19367		return nil, &googleapi.Error{
19368			Code:   res.StatusCode,
19369			Header: res.Header,
19370		}
19371	}
19372	if err != nil {
19373		return nil, err
19374	}
19375	defer googleapi.CloseBody(res)
19376	if err := googleapi.CheckResponse(res); err != nil {
19377		return nil, err
19378	}
19379	ret := &GoogleCloudDialogflowV2ListEntityTypesResponse{
19380		ServerResponse: googleapi.ServerResponse{
19381			Header:         res.Header,
19382			HTTPStatusCode: res.StatusCode,
19383		},
19384	}
19385	target := &ret
19386	if err := gensupport.DecodeResponse(target, res); err != nil {
19387		return nil, err
19388	}
19389	return ret, nil
19390	// {
19391	//   "description": "Returns the list of all entity types in the specified agent.",
19392	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes",
19393	//   "httpMethod": "GET",
19394	//   "id": "dialogflow.projects.agent.entityTypes.list",
19395	//   "parameterOrder": [
19396	//     "parent"
19397	//   ],
19398	//   "parameters": {
19399	//     "languageCode": {
19400	//       "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).",
19401	//       "location": "query",
19402	//       "type": "string"
19403	//     },
19404	//     "pageSize": {
19405	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
19406	//       "format": "int32",
19407	//       "location": "query",
19408	//       "type": "integer"
19409	//     },
19410	//     "pageToken": {
19411	//       "description": "Optional. The next_page_token value returned from a previous list request.",
19412	//       "location": "query",
19413	//       "type": "string"
19414	//     },
19415	//     "parent": {
19416	//       "description": "Required. The agent to list all entity types from. Format: `projects//agent`.",
19417	//       "location": "path",
19418	//       "pattern": "^projects/[^/]+/agent$",
19419	//       "required": true,
19420	//       "type": "string"
19421	//     }
19422	//   },
19423	//   "path": "v2/{+parent}/entityTypes",
19424	//   "response": {
19425	//     "$ref": "GoogleCloudDialogflowV2ListEntityTypesResponse"
19426	//   },
19427	//   "scopes": [
19428	//     "https://www.googleapis.com/auth/cloud-platform",
19429	//     "https://www.googleapis.com/auth/dialogflow"
19430	//   ]
19431	// }
19432
19433}
19434
19435// Pages invokes f for each page of results.
19436// A non-nil error returned from f will halt the iteration.
19437// The provided context supersedes any context provided to the Context method.
19438func (c *ProjectsAgentEntityTypesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListEntityTypesResponse) error) error {
19439	c.ctx_ = ctx
19440	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
19441	for {
19442		x, err := c.Do()
19443		if err != nil {
19444			return err
19445		}
19446		if err := f(x); err != nil {
19447			return err
19448		}
19449		if x.NextPageToken == "" {
19450			return nil
19451		}
19452		c.PageToken(x.NextPageToken)
19453	}
19454}
19455
19456// method id "dialogflow.projects.agent.entityTypes.patch":
19457
19458type ProjectsAgentEntityTypesPatchCall struct {
19459	s                                 *Service
19460	nameid                            string
19461	googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType
19462	urlParams_                        gensupport.URLParams
19463	ctx_                              context.Context
19464	header_                           http.Header
19465}
19466
19467// Patch: Updates the specified entity type.
19468//
19469// - name: The unique identifier of the entity type. Required for
19470//   EntityTypes.UpdateEntityType and EntityTypes.BatchUpdateEntityTypes
19471//   methods. Format: `projects//agent/entityTypes/`.
19472func (r *ProjectsAgentEntityTypesService) Patch(nameid string, googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType) *ProjectsAgentEntityTypesPatchCall {
19473	c := &ProjectsAgentEntityTypesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19474	c.nameid = nameid
19475	c.googleclouddialogflowv2entitytype = googleclouddialogflowv2entitytype
19476	return c
19477}
19478
19479// LanguageCode sets the optional parameter "languageCode": The language
19480// used to access language-specific data. If not specified, the agent's
19481// default language is used. For more information, see Multilingual
19482// intent and entity data
19483// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
19484func (c *ProjectsAgentEntityTypesPatchCall) LanguageCode(languageCode string) *ProjectsAgentEntityTypesPatchCall {
19485	c.urlParams_.Set("languageCode", languageCode)
19486	return c
19487}
19488
19489// UpdateMask sets the optional parameter "updateMask": The mask to
19490// control which fields get updated.
19491func (c *ProjectsAgentEntityTypesPatchCall) UpdateMask(updateMask string) *ProjectsAgentEntityTypesPatchCall {
19492	c.urlParams_.Set("updateMask", updateMask)
19493	return c
19494}
19495
19496// Fields allows partial responses to be retrieved. See
19497// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19498// for more information.
19499func (c *ProjectsAgentEntityTypesPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesPatchCall {
19500	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19501	return c
19502}
19503
19504// Context sets the context to be used in this call's Do method. Any
19505// pending HTTP request will be aborted if the provided context is
19506// canceled.
19507func (c *ProjectsAgentEntityTypesPatchCall) Context(ctx context.Context) *ProjectsAgentEntityTypesPatchCall {
19508	c.ctx_ = ctx
19509	return c
19510}
19511
19512// Header returns an http.Header that can be modified by the caller to
19513// add HTTP headers to the request.
19514func (c *ProjectsAgentEntityTypesPatchCall) Header() http.Header {
19515	if c.header_ == nil {
19516		c.header_ = make(http.Header)
19517	}
19518	return c.header_
19519}
19520
19521func (c *ProjectsAgentEntityTypesPatchCall) doRequest(alt string) (*http.Response, error) {
19522	reqHeaders := make(http.Header)
19523	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
19524	for k, v := range c.header_ {
19525		reqHeaders[k] = v
19526	}
19527	reqHeaders.Set("User-Agent", c.s.userAgent())
19528	var body io.Reader = nil
19529	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2entitytype)
19530	if err != nil {
19531		return nil, err
19532	}
19533	reqHeaders.Set("Content-Type", "application/json")
19534	c.urlParams_.Set("alt", alt)
19535	c.urlParams_.Set("prettyPrint", "false")
19536	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
19537	urls += "?" + c.urlParams_.Encode()
19538	req, err := http.NewRequest("PATCH", urls, body)
19539	if err != nil {
19540		return nil, err
19541	}
19542	req.Header = reqHeaders
19543	googleapi.Expand(req.URL, map[string]string{
19544		"name": c.nameid,
19545	})
19546	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19547}
19548
19549// Do executes the "dialogflow.projects.agent.entityTypes.patch" call.
19550// Exactly one of *GoogleCloudDialogflowV2EntityType or error will be
19551// non-nil. Any non-2xx status code is an error. Response headers are in
19552// either *GoogleCloudDialogflowV2EntityType.ServerResponse.Header or
19553// (if a response was returned at all) in
19554// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
19555// whether the returned error was because http.StatusNotModified was
19556// returned.
19557func (c *ProjectsAgentEntityTypesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EntityType, error) {
19558	gensupport.SetOptions(c.urlParams_, opts...)
19559	res, err := c.doRequest("json")
19560	if res != nil && res.StatusCode == http.StatusNotModified {
19561		if res.Body != nil {
19562			res.Body.Close()
19563		}
19564		return nil, &googleapi.Error{
19565			Code:   res.StatusCode,
19566			Header: res.Header,
19567		}
19568	}
19569	if err != nil {
19570		return nil, err
19571	}
19572	defer googleapi.CloseBody(res)
19573	if err := googleapi.CheckResponse(res); err != nil {
19574		return nil, err
19575	}
19576	ret := &GoogleCloudDialogflowV2EntityType{
19577		ServerResponse: googleapi.ServerResponse{
19578			Header:         res.Header,
19579			HTTPStatusCode: res.StatusCode,
19580		},
19581	}
19582	target := &ret
19583	if err := gensupport.DecodeResponse(target, res); err != nil {
19584		return nil, err
19585	}
19586	return ret, nil
19587	// {
19588	//   "description": "Updates the specified entity type.",
19589	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes/{entityTypesId}",
19590	//   "httpMethod": "PATCH",
19591	//   "id": "dialogflow.projects.agent.entityTypes.patch",
19592	//   "parameterOrder": [
19593	//     "name"
19594	//   ],
19595	//   "parameters": {
19596	//     "languageCode": {
19597	//       "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).",
19598	//       "location": "query",
19599	//       "type": "string"
19600	//     },
19601	//     "name": {
19602	//       "description": "The unique identifier of the entity type. Required for EntityTypes.UpdateEntityType and EntityTypes.BatchUpdateEntityTypes methods. Format: `projects//agent/entityTypes/`.",
19603	//       "location": "path",
19604	//       "pattern": "^projects/[^/]+/agent/entityTypes/[^/]+$",
19605	//       "required": true,
19606	//       "type": "string"
19607	//     },
19608	//     "updateMask": {
19609	//       "description": "Optional. The mask to control which fields get updated.",
19610	//       "format": "google-fieldmask",
19611	//       "location": "query",
19612	//       "type": "string"
19613	//     }
19614	//   },
19615	//   "path": "v2/{+name}",
19616	//   "request": {
19617	//     "$ref": "GoogleCloudDialogflowV2EntityType"
19618	//   },
19619	//   "response": {
19620	//     "$ref": "GoogleCloudDialogflowV2EntityType"
19621	//   },
19622	//   "scopes": [
19623	//     "https://www.googleapis.com/auth/cloud-platform",
19624	//     "https://www.googleapis.com/auth/dialogflow"
19625	//   ]
19626	// }
19627
19628}
19629
19630// method id "dialogflow.projects.agent.entityTypes.entities.batchCreate":
19631
19632type ProjectsAgentEntityTypesEntitiesBatchCreateCall struct {
19633	s                                                 *Service
19634	parent                                            string
19635	googleclouddialogflowv2batchcreateentitiesrequest *GoogleCloudDialogflowV2BatchCreateEntitiesRequest
19636	urlParams_                                        gensupport.URLParams
19637	ctx_                                              context.Context
19638	header_                                           http.Header
19639}
19640
19641// BatchCreate: Creates multiple new entities in the specified entity
19642// type. Operation
19643//
19644// - parent: The name of the entity type to create entities in. Format:
19645//   `projects//agent/entityTypes/`.
19646func (r *ProjectsAgentEntityTypesEntitiesService) BatchCreate(parent string, googleclouddialogflowv2batchcreateentitiesrequest *GoogleCloudDialogflowV2BatchCreateEntitiesRequest) *ProjectsAgentEntityTypesEntitiesBatchCreateCall {
19647	c := &ProjectsAgentEntityTypesEntitiesBatchCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19648	c.parent = parent
19649	c.googleclouddialogflowv2batchcreateentitiesrequest = googleclouddialogflowv2batchcreateentitiesrequest
19650	return c
19651}
19652
19653// Fields allows partial responses to be retrieved. See
19654// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19655// for more information.
19656func (c *ProjectsAgentEntityTypesEntitiesBatchCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesEntitiesBatchCreateCall {
19657	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19658	return c
19659}
19660
19661// Context sets the context to be used in this call's Do method. Any
19662// pending HTTP request will be aborted if the provided context is
19663// canceled.
19664func (c *ProjectsAgentEntityTypesEntitiesBatchCreateCall) Context(ctx context.Context) *ProjectsAgentEntityTypesEntitiesBatchCreateCall {
19665	c.ctx_ = ctx
19666	return c
19667}
19668
19669// Header returns an http.Header that can be modified by the caller to
19670// add HTTP headers to the request.
19671func (c *ProjectsAgentEntityTypesEntitiesBatchCreateCall) Header() http.Header {
19672	if c.header_ == nil {
19673		c.header_ = make(http.Header)
19674	}
19675	return c.header_
19676}
19677
19678func (c *ProjectsAgentEntityTypesEntitiesBatchCreateCall) doRequest(alt string) (*http.Response, error) {
19679	reqHeaders := make(http.Header)
19680	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
19681	for k, v := range c.header_ {
19682		reqHeaders[k] = v
19683	}
19684	reqHeaders.Set("User-Agent", c.s.userAgent())
19685	var body io.Reader = nil
19686	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchcreateentitiesrequest)
19687	if err != nil {
19688		return nil, err
19689	}
19690	reqHeaders.Set("Content-Type", "application/json")
19691	c.urlParams_.Set("alt", alt)
19692	c.urlParams_.Set("prettyPrint", "false")
19693	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entities:batchCreate")
19694	urls += "?" + c.urlParams_.Encode()
19695	req, err := http.NewRequest("POST", urls, body)
19696	if err != nil {
19697		return nil, err
19698	}
19699	req.Header = reqHeaders
19700	googleapi.Expand(req.URL, map[string]string{
19701		"parent": c.parent,
19702	})
19703	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19704}
19705
19706// Do executes the "dialogflow.projects.agent.entityTypes.entities.batchCreate" call.
19707// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
19708// Any non-2xx status code is an error. Response headers are in either
19709// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
19710// was returned at all) in error.(*googleapi.Error).Header. Use
19711// googleapi.IsNotModified to check whether the returned error was
19712// because http.StatusNotModified was returned.
19713func (c *ProjectsAgentEntityTypesEntitiesBatchCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
19714	gensupport.SetOptions(c.urlParams_, opts...)
19715	res, err := c.doRequest("json")
19716	if res != nil && res.StatusCode == http.StatusNotModified {
19717		if res.Body != nil {
19718			res.Body.Close()
19719		}
19720		return nil, &googleapi.Error{
19721			Code:   res.StatusCode,
19722			Header: res.Header,
19723		}
19724	}
19725	if err != nil {
19726		return nil, err
19727	}
19728	defer googleapi.CloseBody(res)
19729	if err := googleapi.CheckResponse(res); err != nil {
19730		return nil, err
19731	}
19732	ret := &GoogleLongrunningOperation{
19733		ServerResponse: googleapi.ServerResponse{
19734			Header:         res.Header,
19735			HTTPStatusCode: res.StatusCode,
19736		},
19737	}
19738	target := &ret
19739	if err := gensupport.DecodeResponse(target, res); err != nil {
19740		return nil, err
19741	}
19742	return ret, nil
19743	// {
19744	//   "description": "Creates multiple new entities in the specified entity type. Operation ",
19745	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes/{entityTypesId}/entities:batchCreate",
19746	//   "httpMethod": "POST",
19747	//   "id": "dialogflow.projects.agent.entityTypes.entities.batchCreate",
19748	//   "parameterOrder": [
19749	//     "parent"
19750	//   ],
19751	//   "parameters": {
19752	//     "parent": {
19753	//       "description": "Required. The name of the entity type to create entities in. Format: `projects//agent/entityTypes/`.",
19754	//       "location": "path",
19755	//       "pattern": "^projects/[^/]+/agent/entityTypes/[^/]+$",
19756	//       "required": true,
19757	//       "type": "string"
19758	//     }
19759	//   },
19760	//   "path": "v2/{+parent}/entities:batchCreate",
19761	//   "request": {
19762	//     "$ref": "GoogleCloudDialogflowV2BatchCreateEntitiesRequest"
19763	//   },
19764	//   "response": {
19765	//     "$ref": "GoogleLongrunningOperation"
19766	//   },
19767	//   "scopes": [
19768	//     "https://www.googleapis.com/auth/cloud-platform",
19769	//     "https://www.googleapis.com/auth/dialogflow"
19770	//   ]
19771	// }
19772
19773}
19774
19775// method id "dialogflow.projects.agent.entityTypes.entities.batchDelete":
19776
19777type ProjectsAgentEntityTypesEntitiesBatchDeleteCall struct {
19778	s                                                 *Service
19779	parent                                            string
19780	googleclouddialogflowv2batchdeleteentitiesrequest *GoogleCloudDialogflowV2BatchDeleteEntitiesRequest
19781	urlParams_                                        gensupport.URLParams
19782	ctx_                                              context.Context
19783	header_                                           http.Header
19784}
19785
19786// BatchDelete: Deletes entities in the specified entity type. Operation
19787//
19788// - parent: The name of the entity type to delete entries for. Format:
19789//   `projects//agent/entityTypes/`.
19790func (r *ProjectsAgentEntityTypesEntitiesService) BatchDelete(parent string, googleclouddialogflowv2batchdeleteentitiesrequest *GoogleCloudDialogflowV2BatchDeleteEntitiesRequest) *ProjectsAgentEntityTypesEntitiesBatchDeleteCall {
19791	c := &ProjectsAgentEntityTypesEntitiesBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19792	c.parent = parent
19793	c.googleclouddialogflowv2batchdeleteentitiesrequest = googleclouddialogflowv2batchdeleteentitiesrequest
19794	return c
19795}
19796
19797// Fields allows partial responses to be retrieved. See
19798// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19799// for more information.
19800func (c *ProjectsAgentEntityTypesEntitiesBatchDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesEntitiesBatchDeleteCall {
19801	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19802	return c
19803}
19804
19805// Context sets the context to be used in this call's Do method. Any
19806// pending HTTP request will be aborted if the provided context is
19807// canceled.
19808func (c *ProjectsAgentEntityTypesEntitiesBatchDeleteCall) Context(ctx context.Context) *ProjectsAgentEntityTypesEntitiesBatchDeleteCall {
19809	c.ctx_ = ctx
19810	return c
19811}
19812
19813// Header returns an http.Header that can be modified by the caller to
19814// add HTTP headers to the request.
19815func (c *ProjectsAgentEntityTypesEntitiesBatchDeleteCall) Header() http.Header {
19816	if c.header_ == nil {
19817		c.header_ = make(http.Header)
19818	}
19819	return c.header_
19820}
19821
19822func (c *ProjectsAgentEntityTypesEntitiesBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
19823	reqHeaders := make(http.Header)
19824	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
19825	for k, v := range c.header_ {
19826		reqHeaders[k] = v
19827	}
19828	reqHeaders.Set("User-Agent", c.s.userAgent())
19829	var body io.Reader = nil
19830	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchdeleteentitiesrequest)
19831	if err != nil {
19832		return nil, err
19833	}
19834	reqHeaders.Set("Content-Type", "application/json")
19835	c.urlParams_.Set("alt", alt)
19836	c.urlParams_.Set("prettyPrint", "false")
19837	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entities:batchDelete")
19838	urls += "?" + c.urlParams_.Encode()
19839	req, err := http.NewRequest("POST", urls, body)
19840	if err != nil {
19841		return nil, err
19842	}
19843	req.Header = reqHeaders
19844	googleapi.Expand(req.URL, map[string]string{
19845		"parent": c.parent,
19846	})
19847	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19848}
19849
19850// Do executes the "dialogflow.projects.agent.entityTypes.entities.batchDelete" call.
19851// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
19852// Any non-2xx status code is an error. Response headers are in either
19853// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
19854// was returned at all) in error.(*googleapi.Error).Header. Use
19855// googleapi.IsNotModified to check whether the returned error was
19856// because http.StatusNotModified was returned.
19857func (c *ProjectsAgentEntityTypesEntitiesBatchDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
19858	gensupport.SetOptions(c.urlParams_, opts...)
19859	res, err := c.doRequest("json")
19860	if res != nil && res.StatusCode == http.StatusNotModified {
19861		if res.Body != nil {
19862			res.Body.Close()
19863		}
19864		return nil, &googleapi.Error{
19865			Code:   res.StatusCode,
19866			Header: res.Header,
19867		}
19868	}
19869	if err != nil {
19870		return nil, err
19871	}
19872	defer googleapi.CloseBody(res)
19873	if err := googleapi.CheckResponse(res); err != nil {
19874		return nil, err
19875	}
19876	ret := &GoogleLongrunningOperation{
19877		ServerResponse: googleapi.ServerResponse{
19878			Header:         res.Header,
19879			HTTPStatusCode: res.StatusCode,
19880		},
19881	}
19882	target := &ret
19883	if err := gensupport.DecodeResponse(target, res); err != nil {
19884		return nil, err
19885	}
19886	return ret, nil
19887	// {
19888	//   "description": "Deletes entities in the specified entity type. Operation ",
19889	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes/{entityTypesId}/entities:batchDelete",
19890	//   "httpMethod": "POST",
19891	//   "id": "dialogflow.projects.agent.entityTypes.entities.batchDelete",
19892	//   "parameterOrder": [
19893	//     "parent"
19894	//   ],
19895	//   "parameters": {
19896	//     "parent": {
19897	//       "description": "Required. The name of the entity type to delete entries for. Format: `projects//agent/entityTypes/`.",
19898	//       "location": "path",
19899	//       "pattern": "^projects/[^/]+/agent/entityTypes/[^/]+$",
19900	//       "required": true,
19901	//       "type": "string"
19902	//     }
19903	//   },
19904	//   "path": "v2/{+parent}/entities:batchDelete",
19905	//   "request": {
19906	//     "$ref": "GoogleCloudDialogflowV2BatchDeleteEntitiesRequest"
19907	//   },
19908	//   "response": {
19909	//     "$ref": "GoogleLongrunningOperation"
19910	//   },
19911	//   "scopes": [
19912	//     "https://www.googleapis.com/auth/cloud-platform",
19913	//     "https://www.googleapis.com/auth/dialogflow"
19914	//   ]
19915	// }
19916
19917}
19918
19919// method id "dialogflow.projects.agent.entityTypes.entities.batchUpdate":
19920
19921type ProjectsAgentEntityTypesEntitiesBatchUpdateCall struct {
19922	s                                                 *Service
19923	parent                                            string
19924	googleclouddialogflowv2batchupdateentitiesrequest *GoogleCloudDialogflowV2BatchUpdateEntitiesRequest
19925	urlParams_                                        gensupport.URLParams
19926	ctx_                                              context.Context
19927	header_                                           http.Header
19928}
19929
19930// BatchUpdate: Updates or creates multiple entities in the specified
19931// entity type. This method does not affect entities in the entity type
19932// that aren't explicitly specified in the request. Operation
19933//
19934// - parent: The name of the entity type to update or create entities
19935//   in. Format: `projects//agent/entityTypes/`.
19936func (r *ProjectsAgentEntityTypesEntitiesService) BatchUpdate(parent string, googleclouddialogflowv2batchupdateentitiesrequest *GoogleCloudDialogflowV2BatchUpdateEntitiesRequest) *ProjectsAgentEntityTypesEntitiesBatchUpdateCall {
19937	c := &ProjectsAgentEntityTypesEntitiesBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19938	c.parent = parent
19939	c.googleclouddialogflowv2batchupdateentitiesrequest = googleclouddialogflowv2batchupdateentitiesrequest
19940	return c
19941}
19942
19943// Fields allows partial responses to be retrieved. See
19944// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19945// for more information.
19946func (c *ProjectsAgentEntityTypesEntitiesBatchUpdateCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesEntitiesBatchUpdateCall {
19947	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19948	return c
19949}
19950
19951// Context sets the context to be used in this call's Do method. Any
19952// pending HTTP request will be aborted if the provided context is
19953// canceled.
19954func (c *ProjectsAgentEntityTypesEntitiesBatchUpdateCall) Context(ctx context.Context) *ProjectsAgentEntityTypesEntitiesBatchUpdateCall {
19955	c.ctx_ = ctx
19956	return c
19957}
19958
19959// Header returns an http.Header that can be modified by the caller to
19960// add HTTP headers to the request.
19961func (c *ProjectsAgentEntityTypesEntitiesBatchUpdateCall) Header() http.Header {
19962	if c.header_ == nil {
19963		c.header_ = make(http.Header)
19964	}
19965	return c.header_
19966}
19967
19968func (c *ProjectsAgentEntityTypesEntitiesBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
19969	reqHeaders := make(http.Header)
19970	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
19971	for k, v := range c.header_ {
19972		reqHeaders[k] = v
19973	}
19974	reqHeaders.Set("User-Agent", c.s.userAgent())
19975	var body io.Reader = nil
19976	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchupdateentitiesrequest)
19977	if err != nil {
19978		return nil, err
19979	}
19980	reqHeaders.Set("Content-Type", "application/json")
19981	c.urlParams_.Set("alt", alt)
19982	c.urlParams_.Set("prettyPrint", "false")
19983	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entities:batchUpdate")
19984	urls += "?" + c.urlParams_.Encode()
19985	req, err := http.NewRequest("POST", urls, body)
19986	if err != nil {
19987		return nil, err
19988	}
19989	req.Header = reqHeaders
19990	googleapi.Expand(req.URL, map[string]string{
19991		"parent": c.parent,
19992	})
19993	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19994}
19995
19996// Do executes the "dialogflow.projects.agent.entityTypes.entities.batchUpdate" call.
19997// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
19998// Any non-2xx status code is an error. Response headers are in either
19999// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
20000// was returned at all) in error.(*googleapi.Error).Header. Use
20001// googleapi.IsNotModified to check whether the returned error was
20002// because http.StatusNotModified was returned.
20003func (c *ProjectsAgentEntityTypesEntitiesBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
20004	gensupport.SetOptions(c.urlParams_, opts...)
20005	res, err := c.doRequest("json")
20006	if res != nil && res.StatusCode == http.StatusNotModified {
20007		if res.Body != nil {
20008			res.Body.Close()
20009		}
20010		return nil, &googleapi.Error{
20011			Code:   res.StatusCode,
20012			Header: res.Header,
20013		}
20014	}
20015	if err != nil {
20016		return nil, err
20017	}
20018	defer googleapi.CloseBody(res)
20019	if err := googleapi.CheckResponse(res); err != nil {
20020		return nil, err
20021	}
20022	ret := &GoogleLongrunningOperation{
20023		ServerResponse: googleapi.ServerResponse{
20024			Header:         res.Header,
20025			HTTPStatusCode: res.StatusCode,
20026		},
20027	}
20028	target := &ret
20029	if err := gensupport.DecodeResponse(target, res); err != nil {
20030		return nil, err
20031	}
20032	return ret, nil
20033	// {
20034	//   "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. Operation ",
20035	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes/{entityTypesId}/entities:batchUpdate",
20036	//   "httpMethod": "POST",
20037	//   "id": "dialogflow.projects.agent.entityTypes.entities.batchUpdate",
20038	//   "parameterOrder": [
20039	//     "parent"
20040	//   ],
20041	//   "parameters": {
20042	//     "parent": {
20043	//       "description": "Required. The name of the entity type to update or create entities in. Format: `projects//agent/entityTypes/`.",
20044	//       "location": "path",
20045	//       "pattern": "^projects/[^/]+/agent/entityTypes/[^/]+$",
20046	//       "required": true,
20047	//       "type": "string"
20048	//     }
20049	//   },
20050	//   "path": "v2/{+parent}/entities:batchUpdate",
20051	//   "request": {
20052	//     "$ref": "GoogleCloudDialogflowV2BatchUpdateEntitiesRequest"
20053	//   },
20054	//   "response": {
20055	//     "$ref": "GoogleLongrunningOperation"
20056	//   },
20057	//   "scopes": [
20058	//     "https://www.googleapis.com/auth/cloud-platform",
20059	//     "https://www.googleapis.com/auth/dialogflow"
20060	//   ]
20061	// }
20062
20063}
20064
20065// method id "dialogflow.projects.agent.environments.list":
20066
20067type ProjectsAgentEnvironmentsListCall struct {
20068	s            *Service
20069	parent       string
20070	urlParams_   gensupport.URLParams
20071	ifNoneMatch_ string
20072	ctx_         context.Context
20073	header_      http.Header
20074}
20075
20076// List: Returns the list of all non-draft environments of the specified
20077// agent.
20078//
20079// - parent: The agent to list all environments from. Format:
20080//   `projects//agent`.
20081func (r *ProjectsAgentEnvironmentsService) List(parent string) *ProjectsAgentEnvironmentsListCall {
20082	c := &ProjectsAgentEnvironmentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20083	c.parent = parent
20084	return c
20085}
20086
20087// PageSize sets the optional parameter "pageSize": The maximum number
20088// of items to return in a single page. By default 100 and at most 1000.
20089func (c *ProjectsAgentEnvironmentsListCall) PageSize(pageSize int64) *ProjectsAgentEnvironmentsListCall {
20090	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
20091	return c
20092}
20093
20094// PageToken sets the optional parameter "pageToken": The
20095// next_page_token value returned from a previous list request.
20096func (c *ProjectsAgentEnvironmentsListCall) PageToken(pageToken string) *ProjectsAgentEnvironmentsListCall {
20097	c.urlParams_.Set("pageToken", pageToken)
20098	return c
20099}
20100
20101// Fields allows partial responses to be retrieved. See
20102// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20103// for more information.
20104func (c *ProjectsAgentEnvironmentsListCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsListCall {
20105	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20106	return c
20107}
20108
20109// IfNoneMatch sets the optional parameter which makes the operation
20110// fail if the object's ETag matches the given value. This is useful for
20111// getting updates only after the object has changed since the last
20112// request. Use googleapi.IsNotModified to check whether the response
20113// error from Do is the result of In-None-Match.
20114func (c *ProjectsAgentEnvironmentsListCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsListCall {
20115	c.ifNoneMatch_ = entityTag
20116	return c
20117}
20118
20119// Context sets the context to be used in this call's Do method. Any
20120// pending HTTP request will be aborted if the provided context is
20121// canceled.
20122func (c *ProjectsAgentEnvironmentsListCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsListCall {
20123	c.ctx_ = ctx
20124	return c
20125}
20126
20127// Header returns an http.Header that can be modified by the caller to
20128// add HTTP headers to the request.
20129func (c *ProjectsAgentEnvironmentsListCall) Header() http.Header {
20130	if c.header_ == nil {
20131		c.header_ = make(http.Header)
20132	}
20133	return c.header_
20134}
20135
20136func (c *ProjectsAgentEnvironmentsListCall) doRequest(alt string) (*http.Response, error) {
20137	reqHeaders := make(http.Header)
20138	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
20139	for k, v := range c.header_ {
20140		reqHeaders[k] = v
20141	}
20142	reqHeaders.Set("User-Agent", c.s.userAgent())
20143	if c.ifNoneMatch_ != "" {
20144		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20145	}
20146	var body io.Reader = nil
20147	c.urlParams_.Set("alt", alt)
20148	c.urlParams_.Set("prettyPrint", "false")
20149	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/environments")
20150	urls += "?" + c.urlParams_.Encode()
20151	req, err := http.NewRequest("GET", urls, body)
20152	if err != nil {
20153		return nil, err
20154	}
20155	req.Header = reqHeaders
20156	googleapi.Expand(req.URL, map[string]string{
20157		"parent": c.parent,
20158	})
20159	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20160}
20161
20162// Do executes the "dialogflow.projects.agent.environments.list" call.
20163// Exactly one of *GoogleCloudDialogflowV2ListEnvironmentsResponse or
20164// error will be non-nil. Any non-2xx status code is an error. Response
20165// headers are in either
20166// *GoogleCloudDialogflowV2ListEnvironmentsResponse.ServerResponse.Header
20167//  or (if a response was returned at all) in
20168// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
20169// whether the returned error was because http.StatusNotModified was
20170// returned.
20171func (c *ProjectsAgentEnvironmentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListEnvironmentsResponse, error) {
20172	gensupport.SetOptions(c.urlParams_, opts...)
20173	res, err := c.doRequest("json")
20174	if res != nil && res.StatusCode == http.StatusNotModified {
20175		if res.Body != nil {
20176			res.Body.Close()
20177		}
20178		return nil, &googleapi.Error{
20179			Code:   res.StatusCode,
20180			Header: res.Header,
20181		}
20182	}
20183	if err != nil {
20184		return nil, err
20185	}
20186	defer googleapi.CloseBody(res)
20187	if err := googleapi.CheckResponse(res); err != nil {
20188		return nil, err
20189	}
20190	ret := &GoogleCloudDialogflowV2ListEnvironmentsResponse{
20191		ServerResponse: googleapi.ServerResponse{
20192			Header:         res.Header,
20193			HTTPStatusCode: res.StatusCode,
20194		},
20195	}
20196	target := &ret
20197	if err := gensupport.DecodeResponse(target, res); err != nil {
20198		return nil, err
20199	}
20200	return ret, nil
20201	// {
20202	//   "description": "Returns the list of all non-draft environments of the specified agent.",
20203	//   "flatPath": "v2/projects/{projectsId}/agent/environments",
20204	//   "httpMethod": "GET",
20205	//   "id": "dialogflow.projects.agent.environments.list",
20206	//   "parameterOrder": [
20207	//     "parent"
20208	//   ],
20209	//   "parameters": {
20210	//     "pageSize": {
20211	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
20212	//       "format": "int32",
20213	//       "location": "query",
20214	//       "type": "integer"
20215	//     },
20216	//     "pageToken": {
20217	//       "description": "Optional. The next_page_token value returned from a previous list request.",
20218	//       "location": "query",
20219	//       "type": "string"
20220	//     },
20221	//     "parent": {
20222	//       "description": "Required. The agent to list all environments from. Format: `projects//agent`.",
20223	//       "location": "path",
20224	//       "pattern": "^projects/[^/]+/agent$",
20225	//       "required": true,
20226	//       "type": "string"
20227	//     }
20228	//   },
20229	//   "path": "v2/{+parent}/environments",
20230	//   "response": {
20231	//     "$ref": "GoogleCloudDialogflowV2ListEnvironmentsResponse"
20232	//   },
20233	//   "scopes": [
20234	//     "https://www.googleapis.com/auth/cloud-platform",
20235	//     "https://www.googleapis.com/auth/dialogflow"
20236	//   ]
20237	// }
20238
20239}
20240
20241// Pages invokes f for each page of results.
20242// A non-nil error returned from f will halt the iteration.
20243// The provided context supersedes any context provided to the Context method.
20244func (c *ProjectsAgentEnvironmentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListEnvironmentsResponse) error) error {
20245	c.ctx_ = ctx
20246	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
20247	for {
20248		x, err := c.Do()
20249		if err != nil {
20250			return err
20251		}
20252		if err := f(x); err != nil {
20253			return err
20254		}
20255		if x.NextPageToken == "" {
20256			return nil
20257		}
20258		c.PageToken(x.NextPageToken)
20259	}
20260}
20261
20262// method id "dialogflow.projects.agent.environments.intents.list":
20263
20264type ProjectsAgentEnvironmentsIntentsListCall struct {
20265	s            *Service
20266	parent       string
20267	urlParams_   gensupport.URLParams
20268	ifNoneMatch_ string
20269	ctx_         context.Context
20270	header_      http.Header
20271}
20272
20273// List: Returns the list of all intents in the specified agent.
20274//
20275// - parent: The agent to list all intents from. Format:
20276//   `projects//agent`.
20277func (r *ProjectsAgentEnvironmentsIntentsService) List(parent string) *ProjectsAgentEnvironmentsIntentsListCall {
20278	c := &ProjectsAgentEnvironmentsIntentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20279	c.parent = parent
20280	return c
20281}
20282
20283// IntentView sets the optional parameter "intentView": The resource
20284// view to apply to the returned intent.
20285//
20286// Possible values:
20287//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
20288// in the response.
20289//   "INTENT_VIEW_FULL" - All fields are populated.
20290func (c *ProjectsAgentEnvironmentsIntentsListCall) IntentView(intentView string) *ProjectsAgentEnvironmentsIntentsListCall {
20291	c.urlParams_.Set("intentView", intentView)
20292	return c
20293}
20294
20295// LanguageCode sets the optional parameter "languageCode": The language
20296// used to access language-specific data. If not specified, the agent's
20297// default language is used. For more information, see Multilingual
20298// intent and entity data
20299// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
20300func (c *ProjectsAgentEnvironmentsIntentsListCall) LanguageCode(languageCode string) *ProjectsAgentEnvironmentsIntentsListCall {
20301	c.urlParams_.Set("languageCode", languageCode)
20302	return c
20303}
20304
20305// PageSize sets the optional parameter "pageSize": The maximum number
20306// of items to return in a single page. By default 100 and at most 1000.
20307func (c *ProjectsAgentEnvironmentsIntentsListCall) PageSize(pageSize int64) *ProjectsAgentEnvironmentsIntentsListCall {
20308	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
20309	return c
20310}
20311
20312// PageToken sets the optional parameter "pageToken": The
20313// next_page_token value returned from a previous list request.
20314func (c *ProjectsAgentEnvironmentsIntentsListCall) PageToken(pageToken string) *ProjectsAgentEnvironmentsIntentsListCall {
20315	c.urlParams_.Set("pageToken", pageToken)
20316	return c
20317}
20318
20319// Fields allows partial responses to be retrieved. See
20320// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20321// for more information.
20322func (c *ProjectsAgentEnvironmentsIntentsListCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsIntentsListCall {
20323	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20324	return c
20325}
20326
20327// IfNoneMatch sets the optional parameter which makes the operation
20328// fail if the object's ETag matches the given value. This is useful for
20329// getting updates only after the object has changed since the last
20330// request. Use googleapi.IsNotModified to check whether the response
20331// error from Do is the result of In-None-Match.
20332func (c *ProjectsAgentEnvironmentsIntentsListCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsIntentsListCall {
20333	c.ifNoneMatch_ = entityTag
20334	return c
20335}
20336
20337// Context sets the context to be used in this call's Do method. Any
20338// pending HTTP request will be aborted if the provided context is
20339// canceled.
20340func (c *ProjectsAgentEnvironmentsIntentsListCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsIntentsListCall {
20341	c.ctx_ = ctx
20342	return c
20343}
20344
20345// Header returns an http.Header that can be modified by the caller to
20346// add HTTP headers to the request.
20347func (c *ProjectsAgentEnvironmentsIntentsListCall) Header() http.Header {
20348	if c.header_ == nil {
20349		c.header_ = make(http.Header)
20350	}
20351	return c.header_
20352}
20353
20354func (c *ProjectsAgentEnvironmentsIntentsListCall) doRequest(alt string) (*http.Response, error) {
20355	reqHeaders := make(http.Header)
20356	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
20357	for k, v := range c.header_ {
20358		reqHeaders[k] = v
20359	}
20360	reqHeaders.Set("User-Agent", c.s.userAgent())
20361	if c.ifNoneMatch_ != "" {
20362		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20363	}
20364	var body io.Reader = nil
20365	c.urlParams_.Set("alt", alt)
20366	c.urlParams_.Set("prettyPrint", "false")
20367	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents")
20368	urls += "?" + c.urlParams_.Encode()
20369	req, err := http.NewRequest("GET", urls, body)
20370	if err != nil {
20371		return nil, err
20372	}
20373	req.Header = reqHeaders
20374	googleapi.Expand(req.URL, map[string]string{
20375		"parent": c.parent,
20376	})
20377	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20378}
20379
20380// Do executes the "dialogflow.projects.agent.environments.intents.list" call.
20381// Exactly one of *GoogleCloudDialogflowV2ListIntentsResponse or error
20382// will be non-nil. Any non-2xx status code is an error. Response
20383// headers are in either
20384// *GoogleCloudDialogflowV2ListIntentsResponse.ServerResponse.Header or
20385// (if a response was returned at all) in
20386// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
20387// whether the returned error was because http.StatusNotModified was
20388// returned.
20389func (c *ProjectsAgentEnvironmentsIntentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListIntentsResponse, error) {
20390	gensupport.SetOptions(c.urlParams_, opts...)
20391	res, err := c.doRequest("json")
20392	if res != nil && res.StatusCode == http.StatusNotModified {
20393		if res.Body != nil {
20394			res.Body.Close()
20395		}
20396		return nil, &googleapi.Error{
20397			Code:   res.StatusCode,
20398			Header: res.Header,
20399		}
20400	}
20401	if err != nil {
20402		return nil, err
20403	}
20404	defer googleapi.CloseBody(res)
20405	if err := googleapi.CheckResponse(res); err != nil {
20406		return nil, err
20407	}
20408	ret := &GoogleCloudDialogflowV2ListIntentsResponse{
20409		ServerResponse: googleapi.ServerResponse{
20410			Header:         res.Header,
20411			HTTPStatusCode: res.StatusCode,
20412		},
20413	}
20414	target := &ret
20415	if err := gensupport.DecodeResponse(target, res); err != nil {
20416		return nil, err
20417	}
20418	return ret, nil
20419	// {
20420	//   "description": "Returns the list of all intents in the specified agent.",
20421	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/intents",
20422	//   "httpMethod": "GET",
20423	//   "id": "dialogflow.projects.agent.environments.intents.list",
20424	//   "parameterOrder": [
20425	//     "parent"
20426	//   ],
20427	//   "parameters": {
20428	//     "intentView": {
20429	//       "description": "Optional. The resource view to apply to the returned intent.",
20430	//       "enum": [
20431	//         "INTENT_VIEW_UNSPECIFIED",
20432	//         "INTENT_VIEW_FULL"
20433	//       ],
20434	//       "enumDescriptions": [
20435	//         "Training phrases field is not populated in the response.",
20436	//         "All fields are populated."
20437	//       ],
20438	//       "location": "query",
20439	//       "type": "string"
20440	//     },
20441	//     "languageCode": {
20442	//       "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).",
20443	//       "location": "query",
20444	//       "type": "string"
20445	//     },
20446	//     "pageSize": {
20447	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
20448	//       "format": "int32",
20449	//       "location": "query",
20450	//       "type": "integer"
20451	//     },
20452	//     "pageToken": {
20453	//       "description": "Optional. The next_page_token value returned from a previous list request.",
20454	//       "location": "query",
20455	//       "type": "string"
20456	//     },
20457	//     "parent": {
20458	//       "description": "Required. The agent to list all intents from. Format: `projects//agent`.",
20459	//       "location": "path",
20460	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+$",
20461	//       "required": true,
20462	//       "type": "string"
20463	//     }
20464	//   },
20465	//   "path": "v2/{+parent}/intents",
20466	//   "response": {
20467	//     "$ref": "GoogleCloudDialogflowV2ListIntentsResponse"
20468	//   },
20469	//   "scopes": [
20470	//     "https://www.googleapis.com/auth/cloud-platform",
20471	//     "https://www.googleapis.com/auth/dialogflow"
20472	//   ]
20473	// }
20474
20475}
20476
20477// Pages invokes f for each page of results.
20478// A non-nil error returned from f will halt the iteration.
20479// The provided context supersedes any context provided to the Context method.
20480func (c *ProjectsAgentEnvironmentsIntentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListIntentsResponse) error) error {
20481	c.ctx_ = ctx
20482	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
20483	for {
20484		x, err := c.Do()
20485		if err != nil {
20486			return err
20487		}
20488		if err := f(x); err != nil {
20489			return err
20490		}
20491		if x.NextPageToken == "" {
20492			return nil
20493		}
20494		c.PageToken(x.NextPageToken)
20495	}
20496}
20497
20498// method id "dialogflow.projects.agent.environments.users.sessions.deleteContexts":
20499
20500type ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall struct {
20501	s          *Service
20502	parent     string
20503	urlParams_ gensupport.URLParams
20504	ctx_       context.Context
20505	header_    http.Header
20506}
20507
20508// DeleteContexts: Deletes all active contexts in the specified session.
20509//
20510// - parent: The name of the session to delete all contexts from.
20511//   Format: `projects//agent/sessions/` or
20512//   `projects//agent/environments//users//sessions/`. If `Environment
20513//   ID` is not specified we assume default 'draft' environment. If
20514//   `User ID` is not specified, we assume default '-' user.
20515func (r *ProjectsAgentEnvironmentsUsersSessionsService) DeleteContexts(parent string) *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall {
20516	c := &ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20517	c.parent = parent
20518	return c
20519}
20520
20521// Fields allows partial responses to be retrieved. See
20522// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20523// for more information.
20524func (c *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall {
20525	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20526	return c
20527}
20528
20529// Context sets the context to be used in this call's Do method. Any
20530// pending HTTP request will be aborted if the provided context is
20531// canceled.
20532func (c *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall {
20533	c.ctx_ = ctx
20534	return c
20535}
20536
20537// Header returns an http.Header that can be modified by the caller to
20538// add HTTP headers to the request.
20539func (c *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall) Header() http.Header {
20540	if c.header_ == nil {
20541		c.header_ = make(http.Header)
20542	}
20543	return c.header_
20544}
20545
20546func (c *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall) doRequest(alt string) (*http.Response, error) {
20547	reqHeaders := make(http.Header)
20548	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
20549	for k, v := range c.header_ {
20550		reqHeaders[k] = v
20551	}
20552	reqHeaders.Set("User-Agent", c.s.userAgent())
20553	var body io.Reader = nil
20554	c.urlParams_.Set("alt", alt)
20555	c.urlParams_.Set("prettyPrint", "false")
20556	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
20557	urls += "?" + c.urlParams_.Encode()
20558	req, err := http.NewRequest("DELETE", urls, body)
20559	if err != nil {
20560		return nil, err
20561	}
20562	req.Header = reqHeaders
20563	googleapi.Expand(req.URL, map[string]string{
20564		"parent": c.parent,
20565	})
20566	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20567}
20568
20569// Do executes the "dialogflow.projects.agent.environments.users.sessions.deleteContexts" call.
20570// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
20571// non-2xx status code is an error. Response headers are in either
20572// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
20573// returned at all) in error.(*googleapi.Error).Header. Use
20574// googleapi.IsNotModified to check whether the returned error was
20575// because http.StatusNotModified was returned.
20576func (c *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
20577	gensupport.SetOptions(c.urlParams_, opts...)
20578	res, err := c.doRequest("json")
20579	if res != nil && res.StatusCode == http.StatusNotModified {
20580		if res.Body != nil {
20581			res.Body.Close()
20582		}
20583		return nil, &googleapi.Error{
20584			Code:   res.StatusCode,
20585			Header: res.Header,
20586		}
20587	}
20588	if err != nil {
20589		return nil, err
20590	}
20591	defer googleapi.CloseBody(res)
20592	if err := googleapi.CheckResponse(res); err != nil {
20593		return nil, err
20594	}
20595	ret := &GoogleProtobufEmpty{
20596		ServerResponse: googleapi.ServerResponse{
20597			Header:         res.Header,
20598			HTTPStatusCode: res.StatusCode,
20599		},
20600	}
20601	target := &ret
20602	if err := gensupport.DecodeResponse(target, res); err != nil {
20603		return nil, err
20604	}
20605	return ret, nil
20606	// {
20607	//   "description": "Deletes all active contexts in the specified session.",
20608	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts",
20609	//   "httpMethod": "DELETE",
20610	//   "id": "dialogflow.projects.agent.environments.users.sessions.deleteContexts",
20611	//   "parameterOrder": [
20612	//     "parent"
20613	//   ],
20614	//   "parameters": {
20615	//     "parent": {
20616	//       "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.",
20617	//       "location": "path",
20618	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
20619	//       "required": true,
20620	//       "type": "string"
20621	//     }
20622	//   },
20623	//   "path": "v2/{+parent}/contexts",
20624	//   "response": {
20625	//     "$ref": "GoogleProtobufEmpty"
20626	//   },
20627	//   "scopes": [
20628	//     "https://www.googleapis.com/auth/cloud-platform",
20629	//     "https://www.googleapis.com/auth/dialogflow"
20630	//   ]
20631	// }
20632
20633}
20634
20635// method id "dialogflow.projects.agent.environments.users.sessions.detectIntent":
20636
20637type ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall struct {
20638	s                                          *Service
20639	sessionid                                  string
20640	googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest
20641	urlParams_                                 gensupport.URLParams
20642	ctx_                                       context.Context
20643	header_                                    http.Header
20644}
20645
20646// DetectIntent: Processes a natural language query and returns
20647// structured, actionable data as a result. This method is not
20648// idempotent, because it may cause contexts and session entity types to
20649// be updated, which in turn might affect results of future queries.
20650// Note: Always use agent versions for production traffic. See Versions
20651// and environments
20652// (https://cloud.google.com/dialogflow/es/docs/agents-versions).
20653//
20654// - session: The name of the session this query is sent to. Format:
20655//   `projects//agent/sessions/`, or
20656//   `projects//agent/environments//users//sessions/`. If `Environment
20657//   ID` is not specified, we assume default 'draft' environment
20658//   (`Environment ID` might be referred to as environment name at some
20659//   places). If `User ID` is not specified, we are using "-". It's up
20660//   to the API caller to choose an appropriate `Session ID` and `User
20661//   Id`. They can be a random number or some type of user and session
20662//   identifiers (preferably hashed). The length of the `Session ID` and
20663//   `User ID` must not exceed 36 characters. For more information, see
20664//   the API interactions guide
20665//   (https://cloud.google.com/dialogflow/docs/api-overview). Note:
20666//   Always use agent versions for production traffic. See Versions and
20667//   environments
20668//   (https://cloud.google.com/dialogflow/es/docs/agents-versions).
20669func (r *ProjectsAgentEnvironmentsUsersSessionsService) DetectIntent(sessionid string, googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest) *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall {
20670	c := &ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20671	c.sessionid = sessionid
20672	c.googleclouddialogflowv2detectintentrequest = googleclouddialogflowv2detectintentrequest
20673	return c
20674}
20675
20676// Fields allows partial responses to be retrieved. See
20677// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20678// for more information.
20679func (c *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall {
20680	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20681	return c
20682}
20683
20684// Context sets the context to be used in this call's Do method. Any
20685// pending HTTP request will be aborted if the provided context is
20686// canceled.
20687func (c *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall {
20688	c.ctx_ = ctx
20689	return c
20690}
20691
20692// Header returns an http.Header that can be modified by the caller to
20693// add HTTP headers to the request.
20694func (c *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall) Header() http.Header {
20695	if c.header_ == nil {
20696		c.header_ = make(http.Header)
20697	}
20698	return c.header_
20699}
20700
20701func (c *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall) doRequest(alt string) (*http.Response, error) {
20702	reqHeaders := make(http.Header)
20703	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
20704	for k, v := range c.header_ {
20705		reqHeaders[k] = v
20706	}
20707	reqHeaders.Set("User-Agent", c.s.userAgent())
20708	var body io.Reader = nil
20709	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2detectintentrequest)
20710	if err != nil {
20711		return nil, err
20712	}
20713	reqHeaders.Set("Content-Type", "application/json")
20714	c.urlParams_.Set("alt", alt)
20715	c.urlParams_.Set("prettyPrint", "false")
20716	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+session}:detectIntent")
20717	urls += "?" + c.urlParams_.Encode()
20718	req, err := http.NewRequest("POST", urls, body)
20719	if err != nil {
20720		return nil, err
20721	}
20722	req.Header = reqHeaders
20723	googleapi.Expand(req.URL, map[string]string{
20724		"session": c.sessionid,
20725	})
20726	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20727}
20728
20729// Do executes the "dialogflow.projects.agent.environments.users.sessions.detectIntent" call.
20730// Exactly one of *GoogleCloudDialogflowV2DetectIntentResponse or error
20731// will be non-nil. Any non-2xx status code is an error. Response
20732// headers are in either
20733// *GoogleCloudDialogflowV2DetectIntentResponse.ServerResponse.Header or
20734// (if a response was returned at all) in
20735// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
20736// whether the returned error was because http.StatusNotModified was
20737// returned.
20738func (c *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2DetectIntentResponse, error) {
20739	gensupport.SetOptions(c.urlParams_, opts...)
20740	res, err := c.doRequest("json")
20741	if res != nil && res.StatusCode == http.StatusNotModified {
20742		if res.Body != nil {
20743			res.Body.Close()
20744		}
20745		return nil, &googleapi.Error{
20746			Code:   res.StatusCode,
20747			Header: res.Header,
20748		}
20749	}
20750	if err != nil {
20751		return nil, err
20752	}
20753	defer googleapi.CloseBody(res)
20754	if err := googleapi.CheckResponse(res); err != nil {
20755		return nil, err
20756	}
20757	ret := &GoogleCloudDialogflowV2DetectIntentResponse{
20758		ServerResponse: googleapi.ServerResponse{
20759			Header:         res.Header,
20760			HTTPStatusCode: res.StatusCode,
20761		},
20762	}
20763	target := &ret
20764	if err := gensupport.DecodeResponse(target, res); err != nil {
20765		return nil, err
20766	}
20767	return ret, nil
20768	// {
20769	//   "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. Note: Always use agent versions for production traffic. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
20770	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}:detectIntent",
20771	//   "httpMethod": "POST",
20772	//   "id": "dialogflow.projects.agent.environments.users.sessions.detectIntent",
20773	//   "parameterOrder": [
20774	//     "session"
20775	//   ],
20776	//   "parameters": {
20777	//     "session": {
20778	//       "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).",
20779	//       "location": "path",
20780	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
20781	//       "required": true,
20782	//       "type": "string"
20783	//     }
20784	//   },
20785	//   "path": "v2/{+session}:detectIntent",
20786	//   "request": {
20787	//     "$ref": "GoogleCloudDialogflowV2DetectIntentRequest"
20788	//   },
20789	//   "response": {
20790	//     "$ref": "GoogleCloudDialogflowV2DetectIntentResponse"
20791	//   },
20792	//   "scopes": [
20793	//     "https://www.googleapis.com/auth/cloud-platform",
20794	//     "https://www.googleapis.com/auth/dialogflow"
20795	//   ]
20796	// }
20797
20798}
20799
20800// method id "dialogflow.projects.agent.environments.users.sessions.contexts.create":
20801
20802type ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall struct {
20803	s                              *Service
20804	parent                         string
20805	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
20806	urlParams_                     gensupport.URLParams
20807	ctx_                           context.Context
20808	header_                        http.Header
20809}
20810
20811// Create: Creates a context. If the specified context already exists,
20812// overrides the context.
20813//
20814// - parent: The session to create a context for. Format:
20815//   `projects//agent/sessions/` or
20816//   `projects//agent/environments//users//sessions/`. If `Environment
20817//   ID` is not specified, we assume default 'draft' environment. If
20818//   `User ID` is not specified, we assume default '-' user.
20819func (r *ProjectsAgentEnvironmentsUsersSessionsContextsService) Create(parent string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall {
20820	c := &ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20821	c.parent = parent
20822	c.googleclouddialogflowv2context = googleclouddialogflowv2context
20823	return c
20824}
20825
20826// Fields allows partial responses to be retrieved. See
20827// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20828// for more information.
20829func (c *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall {
20830	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20831	return c
20832}
20833
20834// Context sets the context to be used in this call's Do method. Any
20835// pending HTTP request will be aborted if the provided context is
20836// canceled.
20837func (c *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall {
20838	c.ctx_ = ctx
20839	return c
20840}
20841
20842// Header returns an http.Header that can be modified by the caller to
20843// add HTTP headers to the request.
20844func (c *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall) Header() http.Header {
20845	if c.header_ == nil {
20846		c.header_ = make(http.Header)
20847	}
20848	return c.header_
20849}
20850
20851func (c *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall) doRequest(alt string) (*http.Response, error) {
20852	reqHeaders := make(http.Header)
20853	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
20854	for k, v := range c.header_ {
20855		reqHeaders[k] = v
20856	}
20857	reqHeaders.Set("User-Agent", c.s.userAgent())
20858	var body io.Reader = nil
20859	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
20860	if err != nil {
20861		return nil, err
20862	}
20863	reqHeaders.Set("Content-Type", "application/json")
20864	c.urlParams_.Set("alt", alt)
20865	c.urlParams_.Set("prettyPrint", "false")
20866	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
20867	urls += "?" + c.urlParams_.Encode()
20868	req, err := http.NewRequest("POST", urls, body)
20869	if err != nil {
20870		return nil, err
20871	}
20872	req.Header = reqHeaders
20873	googleapi.Expand(req.URL, map[string]string{
20874		"parent": c.parent,
20875	})
20876	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20877}
20878
20879// Do executes the "dialogflow.projects.agent.environments.users.sessions.contexts.create" call.
20880// Exactly one of *GoogleCloudDialogflowV2Context or error will be
20881// non-nil. Any non-2xx status code is an error. Response headers are in
20882// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
20883// response was returned at all) in error.(*googleapi.Error).Header. Use
20884// googleapi.IsNotModified to check whether the returned error was
20885// because http.StatusNotModified was returned.
20886func (c *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
20887	gensupport.SetOptions(c.urlParams_, opts...)
20888	res, err := c.doRequest("json")
20889	if res != nil && res.StatusCode == http.StatusNotModified {
20890		if res.Body != nil {
20891			res.Body.Close()
20892		}
20893		return nil, &googleapi.Error{
20894			Code:   res.StatusCode,
20895			Header: res.Header,
20896		}
20897	}
20898	if err != nil {
20899		return nil, err
20900	}
20901	defer googleapi.CloseBody(res)
20902	if err := googleapi.CheckResponse(res); err != nil {
20903		return nil, err
20904	}
20905	ret := &GoogleCloudDialogflowV2Context{
20906		ServerResponse: googleapi.ServerResponse{
20907			Header:         res.Header,
20908			HTTPStatusCode: res.StatusCode,
20909		},
20910	}
20911	target := &ret
20912	if err := gensupport.DecodeResponse(target, res); err != nil {
20913		return nil, err
20914	}
20915	return ret, nil
20916	// {
20917	//   "description": "Creates a context. If the specified context already exists, overrides the context.",
20918	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts",
20919	//   "httpMethod": "POST",
20920	//   "id": "dialogflow.projects.agent.environments.users.sessions.contexts.create",
20921	//   "parameterOrder": [
20922	//     "parent"
20923	//   ],
20924	//   "parameters": {
20925	//     "parent": {
20926	//       "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.",
20927	//       "location": "path",
20928	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
20929	//       "required": true,
20930	//       "type": "string"
20931	//     }
20932	//   },
20933	//   "path": "v2/{+parent}/contexts",
20934	//   "request": {
20935	//     "$ref": "GoogleCloudDialogflowV2Context"
20936	//   },
20937	//   "response": {
20938	//     "$ref": "GoogleCloudDialogflowV2Context"
20939	//   },
20940	//   "scopes": [
20941	//     "https://www.googleapis.com/auth/cloud-platform",
20942	//     "https://www.googleapis.com/auth/dialogflow"
20943	//   ]
20944	// }
20945
20946}
20947
20948// method id "dialogflow.projects.agent.environments.users.sessions.contexts.delete":
20949
20950type ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall struct {
20951	s          *Service
20952	name       string
20953	urlParams_ gensupport.URLParams
20954	ctx_       context.Context
20955	header_    http.Header
20956}
20957
20958// Delete: Deletes the specified context.
20959//
20960// - name: The name of the context to delete. Format:
20961//   `projects//agent/sessions//contexts/` or
20962//   `projects//agent/environments//users//sessions//contexts/`. If
20963//   `Environment ID` is not specified, we assume default 'draft'
20964//   environment. If `User ID` is not specified, we assume default '-'
20965//   user.
20966func (r *ProjectsAgentEnvironmentsUsersSessionsContextsService) Delete(name string) *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall {
20967	c := &ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20968	c.name = name
20969	return c
20970}
20971
20972// Fields allows partial responses to be retrieved. See
20973// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20974// for more information.
20975func (c *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall {
20976	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20977	return c
20978}
20979
20980// Context sets the context to be used in this call's Do method. Any
20981// pending HTTP request will be aborted if the provided context is
20982// canceled.
20983func (c *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall {
20984	c.ctx_ = ctx
20985	return c
20986}
20987
20988// Header returns an http.Header that can be modified by the caller to
20989// add HTTP headers to the request.
20990func (c *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall) Header() http.Header {
20991	if c.header_ == nil {
20992		c.header_ = make(http.Header)
20993	}
20994	return c.header_
20995}
20996
20997func (c *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall) doRequest(alt string) (*http.Response, error) {
20998	reqHeaders := make(http.Header)
20999	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
21000	for k, v := range c.header_ {
21001		reqHeaders[k] = v
21002	}
21003	reqHeaders.Set("User-Agent", c.s.userAgent())
21004	var body io.Reader = nil
21005	c.urlParams_.Set("alt", alt)
21006	c.urlParams_.Set("prettyPrint", "false")
21007	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
21008	urls += "?" + c.urlParams_.Encode()
21009	req, err := http.NewRequest("DELETE", urls, body)
21010	if err != nil {
21011		return nil, err
21012	}
21013	req.Header = reqHeaders
21014	googleapi.Expand(req.URL, map[string]string{
21015		"name": c.name,
21016	})
21017	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21018}
21019
21020// Do executes the "dialogflow.projects.agent.environments.users.sessions.contexts.delete" call.
21021// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
21022// non-2xx status code is an error. Response headers are in either
21023// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
21024// returned at all) in error.(*googleapi.Error).Header. Use
21025// googleapi.IsNotModified to check whether the returned error was
21026// because http.StatusNotModified was returned.
21027func (c *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
21028	gensupport.SetOptions(c.urlParams_, opts...)
21029	res, err := c.doRequest("json")
21030	if res != nil && res.StatusCode == http.StatusNotModified {
21031		if res.Body != nil {
21032			res.Body.Close()
21033		}
21034		return nil, &googleapi.Error{
21035			Code:   res.StatusCode,
21036			Header: res.Header,
21037		}
21038	}
21039	if err != nil {
21040		return nil, err
21041	}
21042	defer googleapi.CloseBody(res)
21043	if err := googleapi.CheckResponse(res); err != nil {
21044		return nil, err
21045	}
21046	ret := &GoogleProtobufEmpty{
21047		ServerResponse: googleapi.ServerResponse{
21048			Header:         res.Header,
21049			HTTPStatusCode: res.StatusCode,
21050		},
21051	}
21052	target := &ret
21053	if err := gensupport.DecodeResponse(target, res); err != nil {
21054		return nil, err
21055	}
21056	return ret, nil
21057	// {
21058	//   "description": "Deletes the specified context.",
21059	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts/{contextsId}",
21060	//   "httpMethod": "DELETE",
21061	//   "id": "dialogflow.projects.agent.environments.users.sessions.contexts.delete",
21062	//   "parameterOrder": [
21063	//     "name"
21064	//   ],
21065	//   "parameters": {
21066	//     "name": {
21067	//       "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.",
21068	//       "location": "path",
21069	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/contexts/[^/]+$",
21070	//       "required": true,
21071	//       "type": "string"
21072	//     }
21073	//   },
21074	//   "path": "v2/{+name}",
21075	//   "response": {
21076	//     "$ref": "GoogleProtobufEmpty"
21077	//   },
21078	//   "scopes": [
21079	//     "https://www.googleapis.com/auth/cloud-platform",
21080	//     "https://www.googleapis.com/auth/dialogflow"
21081	//   ]
21082	// }
21083
21084}
21085
21086// method id "dialogflow.projects.agent.environments.users.sessions.contexts.get":
21087
21088type ProjectsAgentEnvironmentsUsersSessionsContextsGetCall struct {
21089	s            *Service
21090	name         string
21091	urlParams_   gensupport.URLParams
21092	ifNoneMatch_ string
21093	ctx_         context.Context
21094	header_      http.Header
21095}
21096
21097// Get: Retrieves the specified context.
21098//
21099// - name: The name of the context. Format:
21100//   `projects//agent/sessions//contexts/` or
21101//   `projects//agent/environments//users//sessions//contexts/`. If
21102//   `Environment ID` is not specified, we assume default 'draft'
21103//   environment. If `User ID` is not specified, we assume default '-'
21104//   user.
21105func (r *ProjectsAgentEnvironmentsUsersSessionsContextsService) Get(name string) *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall {
21106	c := &ProjectsAgentEnvironmentsUsersSessionsContextsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21107	c.name = name
21108	return c
21109}
21110
21111// Fields allows partial responses to be retrieved. See
21112// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21113// for more information.
21114func (c *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall {
21115	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21116	return c
21117}
21118
21119// IfNoneMatch sets the optional parameter which makes the operation
21120// fail if the object's ETag matches the given value. This is useful for
21121// getting updates only after the object has changed since the last
21122// request. Use googleapi.IsNotModified to check whether the response
21123// error from Do is the result of In-None-Match.
21124func (c *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall {
21125	c.ifNoneMatch_ = entityTag
21126	return c
21127}
21128
21129// Context sets the context to be used in this call's Do method. Any
21130// pending HTTP request will be aborted if the provided context is
21131// canceled.
21132func (c *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall {
21133	c.ctx_ = ctx
21134	return c
21135}
21136
21137// Header returns an http.Header that can be modified by the caller to
21138// add HTTP headers to the request.
21139func (c *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall) Header() http.Header {
21140	if c.header_ == nil {
21141		c.header_ = make(http.Header)
21142	}
21143	return c.header_
21144}
21145
21146func (c *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall) doRequest(alt string) (*http.Response, error) {
21147	reqHeaders := make(http.Header)
21148	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
21149	for k, v := range c.header_ {
21150		reqHeaders[k] = v
21151	}
21152	reqHeaders.Set("User-Agent", c.s.userAgent())
21153	if c.ifNoneMatch_ != "" {
21154		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21155	}
21156	var body io.Reader = nil
21157	c.urlParams_.Set("alt", alt)
21158	c.urlParams_.Set("prettyPrint", "false")
21159	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
21160	urls += "?" + c.urlParams_.Encode()
21161	req, err := http.NewRequest("GET", urls, body)
21162	if err != nil {
21163		return nil, err
21164	}
21165	req.Header = reqHeaders
21166	googleapi.Expand(req.URL, map[string]string{
21167		"name": c.name,
21168	})
21169	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21170}
21171
21172// Do executes the "dialogflow.projects.agent.environments.users.sessions.contexts.get" call.
21173// Exactly one of *GoogleCloudDialogflowV2Context or error will be
21174// non-nil. Any non-2xx status code is an error. Response headers are in
21175// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
21176// response was returned at all) in error.(*googleapi.Error).Header. Use
21177// googleapi.IsNotModified to check whether the returned error was
21178// because http.StatusNotModified was returned.
21179func (c *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
21180	gensupport.SetOptions(c.urlParams_, opts...)
21181	res, err := c.doRequest("json")
21182	if res != nil && res.StatusCode == http.StatusNotModified {
21183		if res.Body != nil {
21184			res.Body.Close()
21185		}
21186		return nil, &googleapi.Error{
21187			Code:   res.StatusCode,
21188			Header: res.Header,
21189		}
21190	}
21191	if err != nil {
21192		return nil, err
21193	}
21194	defer googleapi.CloseBody(res)
21195	if err := googleapi.CheckResponse(res); err != nil {
21196		return nil, err
21197	}
21198	ret := &GoogleCloudDialogflowV2Context{
21199		ServerResponse: googleapi.ServerResponse{
21200			Header:         res.Header,
21201			HTTPStatusCode: res.StatusCode,
21202		},
21203	}
21204	target := &ret
21205	if err := gensupport.DecodeResponse(target, res); err != nil {
21206		return nil, err
21207	}
21208	return ret, nil
21209	// {
21210	//   "description": "Retrieves the specified context.",
21211	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts/{contextsId}",
21212	//   "httpMethod": "GET",
21213	//   "id": "dialogflow.projects.agent.environments.users.sessions.contexts.get",
21214	//   "parameterOrder": [
21215	//     "name"
21216	//   ],
21217	//   "parameters": {
21218	//     "name": {
21219	//       "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.",
21220	//       "location": "path",
21221	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/contexts/[^/]+$",
21222	//       "required": true,
21223	//       "type": "string"
21224	//     }
21225	//   },
21226	//   "path": "v2/{+name}",
21227	//   "response": {
21228	//     "$ref": "GoogleCloudDialogflowV2Context"
21229	//   },
21230	//   "scopes": [
21231	//     "https://www.googleapis.com/auth/cloud-platform",
21232	//     "https://www.googleapis.com/auth/dialogflow"
21233	//   ]
21234	// }
21235
21236}
21237
21238// method id "dialogflow.projects.agent.environments.users.sessions.contexts.list":
21239
21240type ProjectsAgentEnvironmentsUsersSessionsContextsListCall struct {
21241	s            *Service
21242	parent       string
21243	urlParams_   gensupport.URLParams
21244	ifNoneMatch_ string
21245	ctx_         context.Context
21246	header_      http.Header
21247}
21248
21249// List: Returns the list of all contexts in the specified session.
21250//
21251// - parent: The session to list all contexts from. Format:
21252//   `projects//agent/sessions/` or
21253//   `projects//agent/environments//users//sessions/`. If `Environment
21254//   ID` is not specified, we assume default 'draft' environment. If
21255//   `User ID` is not specified, we assume default '-' user.
21256func (r *ProjectsAgentEnvironmentsUsersSessionsContextsService) List(parent string) *ProjectsAgentEnvironmentsUsersSessionsContextsListCall {
21257	c := &ProjectsAgentEnvironmentsUsersSessionsContextsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21258	c.parent = parent
21259	return c
21260}
21261
21262// PageSize sets the optional parameter "pageSize": The maximum number
21263// of items to return in a single page. By default 100 and at most 1000.
21264func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) PageSize(pageSize int64) *ProjectsAgentEnvironmentsUsersSessionsContextsListCall {
21265	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
21266	return c
21267}
21268
21269// PageToken sets the optional parameter "pageToken": The
21270// next_page_token value returned from a previous list request.
21271func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) PageToken(pageToken string) *ProjectsAgentEnvironmentsUsersSessionsContextsListCall {
21272	c.urlParams_.Set("pageToken", pageToken)
21273	return c
21274}
21275
21276// Fields allows partial responses to be retrieved. See
21277// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21278// for more information.
21279func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsContextsListCall {
21280	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21281	return c
21282}
21283
21284// IfNoneMatch sets the optional parameter which makes the operation
21285// fail if the object's ETag matches the given value. This is useful for
21286// getting updates only after the object has changed since the last
21287// request. Use googleapi.IsNotModified to check whether the response
21288// error from Do is the result of In-None-Match.
21289func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsUsersSessionsContextsListCall {
21290	c.ifNoneMatch_ = entityTag
21291	return c
21292}
21293
21294// Context sets the context to be used in this call's Do method. Any
21295// pending HTTP request will be aborted if the provided context is
21296// canceled.
21297func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsContextsListCall {
21298	c.ctx_ = ctx
21299	return c
21300}
21301
21302// Header returns an http.Header that can be modified by the caller to
21303// add HTTP headers to the request.
21304func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) Header() http.Header {
21305	if c.header_ == nil {
21306		c.header_ = make(http.Header)
21307	}
21308	return c.header_
21309}
21310
21311func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) doRequest(alt string) (*http.Response, error) {
21312	reqHeaders := make(http.Header)
21313	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
21314	for k, v := range c.header_ {
21315		reqHeaders[k] = v
21316	}
21317	reqHeaders.Set("User-Agent", c.s.userAgent())
21318	if c.ifNoneMatch_ != "" {
21319		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21320	}
21321	var body io.Reader = nil
21322	c.urlParams_.Set("alt", alt)
21323	c.urlParams_.Set("prettyPrint", "false")
21324	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
21325	urls += "?" + c.urlParams_.Encode()
21326	req, err := http.NewRequest("GET", urls, body)
21327	if err != nil {
21328		return nil, err
21329	}
21330	req.Header = reqHeaders
21331	googleapi.Expand(req.URL, map[string]string{
21332		"parent": c.parent,
21333	})
21334	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21335}
21336
21337// Do executes the "dialogflow.projects.agent.environments.users.sessions.contexts.list" call.
21338// Exactly one of *GoogleCloudDialogflowV2ListContextsResponse or error
21339// will be non-nil. Any non-2xx status code is an error. Response
21340// headers are in either
21341// *GoogleCloudDialogflowV2ListContextsResponse.ServerResponse.Header or
21342// (if a response was returned at all) in
21343// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
21344// whether the returned error was because http.StatusNotModified was
21345// returned.
21346func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListContextsResponse, error) {
21347	gensupport.SetOptions(c.urlParams_, opts...)
21348	res, err := c.doRequest("json")
21349	if res != nil && res.StatusCode == http.StatusNotModified {
21350		if res.Body != nil {
21351			res.Body.Close()
21352		}
21353		return nil, &googleapi.Error{
21354			Code:   res.StatusCode,
21355			Header: res.Header,
21356		}
21357	}
21358	if err != nil {
21359		return nil, err
21360	}
21361	defer googleapi.CloseBody(res)
21362	if err := googleapi.CheckResponse(res); err != nil {
21363		return nil, err
21364	}
21365	ret := &GoogleCloudDialogflowV2ListContextsResponse{
21366		ServerResponse: googleapi.ServerResponse{
21367			Header:         res.Header,
21368			HTTPStatusCode: res.StatusCode,
21369		},
21370	}
21371	target := &ret
21372	if err := gensupport.DecodeResponse(target, res); err != nil {
21373		return nil, err
21374	}
21375	return ret, nil
21376	// {
21377	//   "description": "Returns the list of all contexts in the specified session.",
21378	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts",
21379	//   "httpMethod": "GET",
21380	//   "id": "dialogflow.projects.agent.environments.users.sessions.contexts.list",
21381	//   "parameterOrder": [
21382	//     "parent"
21383	//   ],
21384	//   "parameters": {
21385	//     "pageSize": {
21386	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
21387	//       "format": "int32",
21388	//       "location": "query",
21389	//       "type": "integer"
21390	//     },
21391	//     "pageToken": {
21392	//       "description": "Optional. The next_page_token value returned from a previous list request.",
21393	//       "location": "query",
21394	//       "type": "string"
21395	//     },
21396	//     "parent": {
21397	//       "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.",
21398	//       "location": "path",
21399	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
21400	//       "required": true,
21401	//       "type": "string"
21402	//     }
21403	//   },
21404	//   "path": "v2/{+parent}/contexts",
21405	//   "response": {
21406	//     "$ref": "GoogleCloudDialogflowV2ListContextsResponse"
21407	//   },
21408	//   "scopes": [
21409	//     "https://www.googleapis.com/auth/cloud-platform",
21410	//     "https://www.googleapis.com/auth/dialogflow"
21411	//   ]
21412	// }
21413
21414}
21415
21416// Pages invokes f for each page of results.
21417// A non-nil error returned from f will halt the iteration.
21418// The provided context supersedes any context provided to the Context method.
21419func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListContextsResponse) error) error {
21420	c.ctx_ = ctx
21421	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
21422	for {
21423		x, err := c.Do()
21424		if err != nil {
21425			return err
21426		}
21427		if err := f(x); err != nil {
21428			return err
21429		}
21430		if x.NextPageToken == "" {
21431			return nil
21432		}
21433		c.PageToken(x.NextPageToken)
21434	}
21435}
21436
21437// method id "dialogflow.projects.agent.environments.users.sessions.contexts.patch":
21438
21439type ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall struct {
21440	s                              *Service
21441	nameid                         string
21442	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
21443	urlParams_                     gensupport.URLParams
21444	ctx_                           context.Context
21445	header_                        http.Header
21446}
21447
21448// Patch: Updates the specified context.
21449//
21450// - name: The unique identifier of the context. Format:
21451//   `projects//agent/sessions//contexts/`, or
21452//   `projects//agent/environments//users//sessions//contexts/`. The
21453//   `Context ID` is always converted to lowercase, may only contain
21454//   characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If
21455//   `Environment ID` is not specified, we assume default 'draft'
21456//   environment. If `User ID` is not specified, we assume default '-'
21457//   user. The following context names are reserved for internal use by
21458//   Dialogflow. You should not use these contexts or create contexts
21459//   with these names: * `__system_counters__` * `*_id_dialog_context` *
21460//   `*_dialog_params_size`.
21461func (r *ProjectsAgentEnvironmentsUsersSessionsContextsService) Patch(nameid string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall {
21462	c := &ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21463	c.nameid = nameid
21464	c.googleclouddialogflowv2context = googleclouddialogflowv2context
21465	return c
21466}
21467
21468// UpdateMask sets the optional parameter "updateMask": The mask to
21469// control which fields get updated.
21470func (c *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall) UpdateMask(updateMask string) *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall {
21471	c.urlParams_.Set("updateMask", updateMask)
21472	return c
21473}
21474
21475// Fields allows partial responses to be retrieved. See
21476// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21477// for more information.
21478func (c *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall {
21479	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21480	return c
21481}
21482
21483// Context sets the context to be used in this call's Do method. Any
21484// pending HTTP request will be aborted if the provided context is
21485// canceled.
21486func (c *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall {
21487	c.ctx_ = ctx
21488	return c
21489}
21490
21491// Header returns an http.Header that can be modified by the caller to
21492// add HTTP headers to the request.
21493func (c *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall) Header() http.Header {
21494	if c.header_ == nil {
21495		c.header_ = make(http.Header)
21496	}
21497	return c.header_
21498}
21499
21500func (c *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall) doRequest(alt string) (*http.Response, error) {
21501	reqHeaders := make(http.Header)
21502	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
21503	for k, v := range c.header_ {
21504		reqHeaders[k] = v
21505	}
21506	reqHeaders.Set("User-Agent", c.s.userAgent())
21507	var body io.Reader = nil
21508	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
21509	if err != nil {
21510		return nil, err
21511	}
21512	reqHeaders.Set("Content-Type", "application/json")
21513	c.urlParams_.Set("alt", alt)
21514	c.urlParams_.Set("prettyPrint", "false")
21515	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
21516	urls += "?" + c.urlParams_.Encode()
21517	req, err := http.NewRequest("PATCH", urls, body)
21518	if err != nil {
21519		return nil, err
21520	}
21521	req.Header = reqHeaders
21522	googleapi.Expand(req.URL, map[string]string{
21523		"name": c.nameid,
21524	})
21525	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21526}
21527
21528// Do executes the "dialogflow.projects.agent.environments.users.sessions.contexts.patch" call.
21529// Exactly one of *GoogleCloudDialogflowV2Context or error will be
21530// non-nil. Any non-2xx status code is an error. Response headers are in
21531// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
21532// response was returned at all) in error.(*googleapi.Error).Header. Use
21533// googleapi.IsNotModified to check whether the returned error was
21534// because http.StatusNotModified was returned.
21535func (c *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
21536	gensupport.SetOptions(c.urlParams_, opts...)
21537	res, err := c.doRequest("json")
21538	if res != nil && res.StatusCode == http.StatusNotModified {
21539		if res.Body != nil {
21540			res.Body.Close()
21541		}
21542		return nil, &googleapi.Error{
21543			Code:   res.StatusCode,
21544			Header: res.Header,
21545		}
21546	}
21547	if err != nil {
21548		return nil, err
21549	}
21550	defer googleapi.CloseBody(res)
21551	if err := googleapi.CheckResponse(res); err != nil {
21552		return nil, err
21553	}
21554	ret := &GoogleCloudDialogflowV2Context{
21555		ServerResponse: googleapi.ServerResponse{
21556			Header:         res.Header,
21557			HTTPStatusCode: res.StatusCode,
21558		},
21559	}
21560	target := &ret
21561	if err := gensupport.DecodeResponse(target, res); err != nil {
21562		return nil, err
21563	}
21564	return ret, nil
21565	// {
21566	//   "description": "Updates the specified context.",
21567	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts/{contextsId}",
21568	//   "httpMethod": "PATCH",
21569	//   "id": "dialogflow.projects.agent.environments.users.sessions.contexts.patch",
21570	//   "parameterOrder": [
21571	//     "name"
21572	//   ],
21573	//   "parameters": {
21574	//     "name": {
21575	//       "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`",
21576	//       "location": "path",
21577	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/contexts/[^/]+$",
21578	//       "required": true,
21579	//       "type": "string"
21580	//     },
21581	//     "updateMask": {
21582	//       "description": "Optional. The mask to control which fields get updated.",
21583	//       "format": "google-fieldmask",
21584	//       "location": "query",
21585	//       "type": "string"
21586	//     }
21587	//   },
21588	//   "path": "v2/{+name}",
21589	//   "request": {
21590	//     "$ref": "GoogleCloudDialogflowV2Context"
21591	//   },
21592	//   "response": {
21593	//     "$ref": "GoogleCloudDialogflowV2Context"
21594	//   },
21595	//   "scopes": [
21596	//     "https://www.googleapis.com/auth/cloud-platform",
21597	//     "https://www.googleapis.com/auth/dialogflow"
21598	//   ]
21599	// }
21600
21601}
21602
21603// method id "dialogflow.projects.agent.environments.users.sessions.entityTypes.create":
21604
21605type ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall struct {
21606	s                                        *Service
21607	parent                                   string
21608	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
21609	urlParams_                               gensupport.URLParams
21610	ctx_                                     context.Context
21611	header_                                  http.Header
21612}
21613
21614// Create: Creates a session entity type. If the specified session
21615// entity type already exists, overrides the session entity type. This
21616// method doesn't work with Google Assistant integration. Contact
21617// Dialogflow support if you need to use session entities with Google
21618// Assistant integration.
21619//
21620// - parent: The session to create a session entity type for. Format:
21621//   `projects//agent/sessions/` or
21622//   `projects//agent/environments//users// sessions/`. If `Environment
21623//   ID` is not specified, we assume default 'draft' environment. If
21624//   `User ID` is not specified, we assume default '-' user.
21625func (r *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService) Create(parent string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall {
21626	c := &ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21627	c.parent = parent
21628	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
21629	return c
21630}
21631
21632// Fields allows partial responses to be retrieved. See
21633// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21634// for more information.
21635func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall {
21636	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21637	return c
21638}
21639
21640// Context sets the context to be used in this call's Do method. Any
21641// pending HTTP request will be aborted if the provided context is
21642// canceled.
21643func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall {
21644	c.ctx_ = ctx
21645	return c
21646}
21647
21648// Header returns an http.Header that can be modified by the caller to
21649// add HTTP headers to the request.
21650func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Header() http.Header {
21651	if c.header_ == nil {
21652		c.header_ = make(http.Header)
21653	}
21654	return c.header_
21655}
21656
21657func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) doRequest(alt string) (*http.Response, error) {
21658	reqHeaders := make(http.Header)
21659	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
21660	for k, v := range c.header_ {
21661		reqHeaders[k] = v
21662	}
21663	reqHeaders.Set("User-Agent", c.s.userAgent())
21664	var body io.Reader = nil
21665	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
21666	if err != nil {
21667		return nil, err
21668	}
21669	reqHeaders.Set("Content-Type", "application/json")
21670	c.urlParams_.Set("alt", alt)
21671	c.urlParams_.Set("prettyPrint", "false")
21672	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
21673	urls += "?" + c.urlParams_.Encode()
21674	req, err := http.NewRequest("POST", urls, body)
21675	if err != nil {
21676		return nil, err
21677	}
21678	req.Header = reqHeaders
21679	googleapi.Expand(req.URL, map[string]string{
21680		"parent": c.parent,
21681	})
21682	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21683}
21684
21685// Do executes the "dialogflow.projects.agent.environments.users.sessions.entityTypes.create" call.
21686// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
21687// will be non-nil. Any non-2xx status code is an error. Response
21688// headers are in either
21689// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
21690// (if a response was returned at all) in
21691// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
21692// whether the returned error was because http.StatusNotModified was
21693// returned.
21694func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
21695	gensupport.SetOptions(c.urlParams_, opts...)
21696	res, err := c.doRequest("json")
21697	if res != nil && res.StatusCode == http.StatusNotModified {
21698		if res.Body != nil {
21699			res.Body.Close()
21700		}
21701		return nil, &googleapi.Error{
21702			Code:   res.StatusCode,
21703			Header: res.Header,
21704		}
21705	}
21706	if err != nil {
21707		return nil, err
21708	}
21709	defer googleapi.CloseBody(res)
21710	if err := googleapi.CheckResponse(res); err != nil {
21711		return nil, err
21712	}
21713	ret := &GoogleCloudDialogflowV2SessionEntityType{
21714		ServerResponse: googleapi.ServerResponse{
21715			Header:         res.Header,
21716			HTTPStatusCode: res.StatusCode,
21717		},
21718	}
21719	target := &ret
21720	if err := gensupport.DecodeResponse(target, res); err != nil {
21721		return nil, err
21722	}
21723	return ret, nil
21724	// {
21725	//   "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.",
21726	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes",
21727	//   "httpMethod": "POST",
21728	//   "id": "dialogflow.projects.agent.environments.users.sessions.entityTypes.create",
21729	//   "parameterOrder": [
21730	//     "parent"
21731	//   ],
21732	//   "parameters": {
21733	//     "parent": {
21734	//       "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.",
21735	//       "location": "path",
21736	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
21737	//       "required": true,
21738	//       "type": "string"
21739	//     }
21740	//   },
21741	//   "path": "v2/{+parent}/entityTypes",
21742	//   "request": {
21743	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
21744	//   },
21745	//   "response": {
21746	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
21747	//   },
21748	//   "scopes": [
21749	//     "https://www.googleapis.com/auth/cloud-platform",
21750	//     "https://www.googleapis.com/auth/dialogflow"
21751	//   ]
21752	// }
21753
21754}
21755
21756// method id "dialogflow.projects.agent.environments.users.sessions.entityTypes.delete":
21757
21758type ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall struct {
21759	s          *Service
21760	name       string
21761	urlParams_ gensupport.URLParams
21762	ctx_       context.Context
21763	header_    http.Header
21764}
21765
21766// Delete: Deletes the specified session entity type. This method
21767// doesn't work with Google Assistant integration. Contact Dialogflow
21768// support if you need to use session entities with Google Assistant
21769// integration.
21770//
21771// - name: The name of the entity type to delete. Format:
21772//   `projects//agent/sessions//entityTypes/` or
21773//   `projects//agent/environments//users//sessions//entityTypes/`. If
21774//   `Environment ID` is not specified, we assume default 'draft'
21775//   environment. If `User ID` is not specified, we assume default '-'
21776//   user.
21777func (r *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService) Delete(name string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall {
21778	c := &ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21779	c.name = name
21780	return c
21781}
21782
21783// Fields allows partial responses to be retrieved. See
21784// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21785// for more information.
21786func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall {
21787	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21788	return c
21789}
21790
21791// Context sets the context to be used in this call's Do method. Any
21792// pending HTTP request will be aborted if the provided context is
21793// canceled.
21794func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall {
21795	c.ctx_ = ctx
21796	return c
21797}
21798
21799// Header returns an http.Header that can be modified by the caller to
21800// add HTTP headers to the request.
21801func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Header() http.Header {
21802	if c.header_ == nil {
21803		c.header_ = make(http.Header)
21804	}
21805	return c.header_
21806}
21807
21808func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) doRequest(alt string) (*http.Response, error) {
21809	reqHeaders := make(http.Header)
21810	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
21811	for k, v := range c.header_ {
21812		reqHeaders[k] = v
21813	}
21814	reqHeaders.Set("User-Agent", c.s.userAgent())
21815	var body io.Reader = nil
21816	c.urlParams_.Set("alt", alt)
21817	c.urlParams_.Set("prettyPrint", "false")
21818	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
21819	urls += "?" + c.urlParams_.Encode()
21820	req, err := http.NewRequest("DELETE", urls, body)
21821	if err != nil {
21822		return nil, err
21823	}
21824	req.Header = reqHeaders
21825	googleapi.Expand(req.URL, map[string]string{
21826		"name": c.name,
21827	})
21828	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21829}
21830
21831// Do executes the "dialogflow.projects.agent.environments.users.sessions.entityTypes.delete" call.
21832// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
21833// non-2xx status code is an error. Response headers are in either
21834// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
21835// returned at all) in error.(*googleapi.Error).Header. Use
21836// googleapi.IsNotModified to check whether the returned error was
21837// because http.StatusNotModified was returned.
21838func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
21839	gensupport.SetOptions(c.urlParams_, opts...)
21840	res, err := c.doRequest("json")
21841	if res != nil && res.StatusCode == http.StatusNotModified {
21842		if res.Body != nil {
21843			res.Body.Close()
21844		}
21845		return nil, &googleapi.Error{
21846			Code:   res.StatusCode,
21847			Header: res.Header,
21848		}
21849	}
21850	if err != nil {
21851		return nil, err
21852	}
21853	defer googleapi.CloseBody(res)
21854	if err := googleapi.CheckResponse(res); err != nil {
21855		return nil, err
21856	}
21857	ret := &GoogleProtobufEmpty{
21858		ServerResponse: googleapi.ServerResponse{
21859			Header:         res.Header,
21860			HTTPStatusCode: res.StatusCode,
21861		},
21862	}
21863	target := &ret
21864	if err := gensupport.DecodeResponse(target, res); err != nil {
21865		return nil, err
21866	}
21867	return ret, nil
21868	// {
21869	//   "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.",
21870	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes/{entityTypesId}",
21871	//   "httpMethod": "DELETE",
21872	//   "id": "dialogflow.projects.agent.environments.users.sessions.entityTypes.delete",
21873	//   "parameterOrder": [
21874	//     "name"
21875	//   ],
21876	//   "parameters": {
21877	//     "name": {
21878	//       "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.",
21879	//       "location": "path",
21880	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/entityTypes/[^/]+$",
21881	//       "required": true,
21882	//       "type": "string"
21883	//     }
21884	//   },
21885	//   "path": "v2/{+name}",
21886	//   "response": {
21887	//     "$ref": "GoogleProtobufEmpty"
21888	//   },
21889	//   "scopes": [
21890	//     "https://www.googleapis.com/auth/cloud-platform",
21891	//     "https://www.googleapis.com/auth/dialogflow"
21892	//   ]
21893	// }
21894
21895}
21896
21897// method id "dialogflow.projects.agent.environments.users.sessions.entityTypes.get":
21898
21899type ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall struct {
21900	s            *Service
21901	name         string
21902	urlParams_   gensupport.URLParams
21903	ifNoneMatch_ string
21904	ctx_         context.Context
21905	header_      http.Header
21906}
21907
21908// Get: Retrieves the specified session entity type. This method doesn't
21909// work with Google Assistant integration. Contact Dialogflow support if
21910// you need to use session entities with Google Assistant integration.
21911//
21912// - name: The name of the session entity type. Format:
21913//   `projects//agent/sessions//entityTypes/` or
21914//   `projects//agent/environments//users//sessions//entityTypes/`. If
21915//   `Environment ID` is not specified, we assume default 'draft'
21916//   environment. If `User ID` is not specified, we assume default '-'
21917//   user.
21918func (r *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService) Get(name string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
21919	c := &ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21920	c.name = name
21921	return c
21922}
21923
21924// Fields allows partial responses to be retrieved. See
21925// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21926// for more information.
21927func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
21928	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21929	return c
21930}
21931
21932// IfNoneMatch sets the optional parameter which makes the operation
21933// fail if the object's ETag matches the given value. This is useful for
21934// getting updates only after the object has changed since the last
21935// request. Use googleapi.IsNotModified to check whether the response
21936// error from Do is the result of In-None-Match.
21937func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
21938	c.ifNoneMatch_ = entityTag
21939	return c
21940}
21941
21942// Context sets the context to be used in this call's Do method. Any
21943// pending HTTP request will be aborted if the provided context is
21944// canceled.
21945func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
21946	c.ctx_ = ctx
21947	return c
21948}
21949
21950// Header returns an http.Header that can be modified by the caller to
21951// add HTTP headers to the request.
21952func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Header() http.Header {
21953	if c.header_ == nil {
21954		c.header_ = make(http.Header)
21955	}
21956	return c.header_
21957}
21958
21959func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall) doRequest(alt string) (*http.Response, error) {
21960	reqHeaders := make(http.Header)
21961	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
21962	for k, v := range c.header_ {
21963		reqHeaders[k] = v
21964	}
21965	reqHeaders.Set("User-Agent", c.s.userAgent())
21966	if c.ifNoneMatch_ != "" {
21967		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21968	}
21969	var body io.Reader = nil
21970	c.urlParams_.Set("alt", alt)
21971	c.urlParams_.Set("prettyPrint", "false")
21972	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
21973	urls += "?" + c.urlParams_.Encode()
21974	req, err := http.NewRequest("GET", urls, body)
21975	if err != nil {
21976		return nil, err
21977	}
21978	req.Header = reqHeaders
21979	googleapi.Expand(req.URL, map[string]string{
21980		"name": c.name,
21981	})
21982	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21983}
21984
21985// Do executes the "dialogflow.projects.agent.environments.users.sessions.entityTypes.get" call.
21986// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
21987// will be non-nil. Any non-2xx status code is an error. Response
21988// headers are in either
21989// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
21990// (if a response was returned at all) in
21991// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
21992// whether the returned error was because http.StatusNotModified was
21993// returned.
21994func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
21995	gensupport.SetOptions(c.urlParams_, opts...)
21996	res, err := c.doRequest("json")
21997	if res != nil && res.StatusCode == http.StatusNotModified {
21998		if res.Body != nil {
21999			res.Body.Close()
22000		}
22001		return nil, &googleapi.Error{
22002			Code:   res.StatusCode,
22003			Header: res.Header,
22004		}
22005	}
22006	if err != nil {
22007		return nil, err
22008	}
22009	defer googleapi.CloseBody(res)
22010	if err := googleapi.CheckResponse(res); err != nil {
22011		return nil, err
22012	}
22013	ret := &GoogleCloudDialogflowV2SessionEntityType{
22014		ServerResponse: googleapi.ServerResponse{
22015			Header:         res.Header,
22016			HTTPStatusCode: res.StatusCode,
22017		},
22018	}
22019	target := &ret
22020	if err := gensupport.DecodeResponse(target, res); err != nil {
22021		return nil, err
22022	}
22023	return ret, nil
22024	// {
22025	//   "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.",
22026	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes/{entityTypesId}",
22027	//   "httpMethod": "GET",
22028	//   "id": "dialogflow.projects.agent.environments.users.sessions.entityTypes.get",
22029	//   "parameterOrder": [
22030	//     "name"
22031	//   ],
22032	//   "parameters": {
22033	//     "name": {
22034	//       "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.",
22035	//       "location": "path",
22036	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/entityTypes/[^/]+$",
22037	//       "required": true,
22038	//       "type": "string"
22039	//     }
22040	//   },
22041	//   "path": "v2/{+name}",
22042	//   "response": {
22043	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
22044	//   },
22045	//   "scopes": [
22046	//     "https://www.googleapis.com/auth/cloud-platform",
22047	//     "https://www.googleapis.com/auth/dialogflow"
22048	//   ]
22049	// }
22050
22051}
22052
22053// method id "dialogflow.projects.agent.environments.users.sessions.entityTypes.list":
22054
22055type ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall struct {
22056	s            *Service
22057	parent       string
22058	urlParams_   gensupport.URLParams
22059	ifNoneMatch_ string
22060	ctx_         context.Context
22061	header_      http.Header
22062}
22063
22064// List: Returns the list of all session entity types in the specified
22065// session. This method doesn't work with Google Assistant integration.
22066// Contact Dialogflow support if you need to use session entities with
22067// Google Assistant integration.
22068//
22069// - parent: The session to list all session entity types from. Format:
22070//   `projects//agent/sessions/` or
22071//   `projects//agent/environments//users// sessions/`. If `Environment
22072//   ID` is not specified, we assume default 'draft' environment. If
22073//   `User ID` is not specified, we assume default '-' user.
22074func (r *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService) List(parent string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall {
22075	c := &ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22076	c.parent = parent
22077	return c
22078}
22079
22080// PageSize sets the optional parameter "pageSize": The maximum number
22081// of items to return in a single page. By default 100 and at most 1000.
22082func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) PageSize(pageSize int64) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall {
22083	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
22084	return c
22085}
22086
22087// PageToken sets the optional parameter "pageToken": The
22088// next_page_token value returned from a previous list request.
22089func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) PageToken(pageToken string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall {
22090	c.urlParams_.Set("pageToken", pageToken)
22091	return c
22092}
22093
22094// Fields allows partial responses to be retrieved. See
22095// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22096// for more information.
22097func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall {
22098	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22099	return c
22100}
22101
22102// IfNoneMatch sets the optional parameter which makes the operation
22103// fail if the object's ETag matches the given value. This is useful for
22104// getting updates only after the object has changed since the last
22105// request. Use googleapi.IsNotModified to check whether the response
22106// error from Do is the result of In-None-Match.
22107func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall {
22108	c.ifNoneMatch_ = entityTag
22109	return c
22110}
22111
22112// Context sets the context to be used in this call's Do method. Any
22113// pending HTTP request will be aborted if the provided context is
22114// canceled.
22115func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall {
22116	c.ctx_ = ctx
22117	return c
22118}
22119
22120// Header returns an http.Header that can be modified by the caller to
22121// add HTTP headers to the request.
22122func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) Header() http.Header {
22123	if c.header_ == nil {
22124		c.header_ = make(http.Header)
22125	}
22126	return c.header_
22127}
22128
22129func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) doRequest(alt string) (*http.Response, error) {
22130	reqHeaders := make(http.Header)
22131	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
22132	for k, v := range c.header_ {
22133		reqHeaders[k] = v
22134	}
22135	reqHeaders.Set("User-Agent", c.s.userAgent())
22136	if c.ifNoneMatch_ != "" {
22137		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22138	}
22139	var body io.Reader = nil
22140	c.urlParams_.Set("alt", alt)
22141	c.urlParams_.Set("prettyPrint", "false")
22142	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
22143	urls += "?" + c.urlParams_.Encode()
22144	req, err := http.NewRequest("GET", urls, body)
22145	if err != nil {
22146		return nil, err
22147	}
22148	req.Header = reqHeaders
22149	googleapi.Expand(req.URL, map[string]string{
22150		"parent": c.parent,
22151	})
22152	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22153}
22154
22155// Do executes the "dialogflow.projects.agent.environments.users.sessions.entityTypes.list" call.
22156// Exactly one of *GoogleCloudDialogflowV2ListSessionEntityTypesResponse
22157// or error will be non-nil. Any non-2xx status code is an error.
22158// Response headers are in either
22159// *GoogleCloudDialogflowV2ListSessionEntityTypesResponse.ServerResponse.
22160// Header or (if a response was returned at all) in
22161// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
22162// whether the returned error was because http.StatusNotModified was
22163// returned.
22164func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListSessionEntityTypesResponse, error) {
22165	gensupport.SetOptions(c.urlParams_, opts...)
22166	res, err := c.doRequest("json")
22167	if res != nil && res.StatusCode == http.StatusNotModified {
22168		if res.Body != nil {
22169			res.Body.Close()
22170		}
22171		return nil, &googleapi.Error{
22172			Code:   res.StatusCode,
22173			Header: res.Header,
22174		}
22175	}
22176	if err != nil {
22177		return nil, err
22178	}
22179	defer googleapi.CloseBody(res)
22180	if err := googleapi.CheckResponse(res); err != nil {
22181		return nil, err
22182	}
22183	ret := &GoogleCloudDialogflowV2ListSessionEntityTypesResponse{
22184		ServerResponse: googleapi.ServerResponse{
22185			Header:         res.Header,
22186			HTTPStatusCode: res.StatusCode,
22187		},
22188	}
22189	target := &ret
22190	if err := gensupport.DecodeResponse(target, res); err != nil {
22191		return nil, err
22192	}
22193	return ret, nil
22194	// {
22195	//   "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.",
22196	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes",
22197	//   "httpMethod": "GET",
22198	//   "id": "dialogflow.projects.agent.environments.users.sessions.entityTypes.list",
22199	//   "parameterOrder": [
22200	//     "parent"
22201	//   ],
22202	//   "parameters": {
22203	//     "pageSize": {
22204	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
22205	//       "format": "int32",
22206	//       "location": "query",
22207	//       "type": "integer"
22208	//     },
22209	//     "pageToken": {
22210	//       "description": "Optional. The next_page_token value returned from a previous list request.",
22211	//       "location": "query",
22212	//       "type": "string"
22213	//     },
22214	//     "parent": {
22215	//       "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.",
22216	//       "location": "path",
22217	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
22218	//       "required": true,
22219	//       "type": "string"
22220	//     }
22221	//   },
22222	//   "path": "v2/{+parent}/entityTypes",
22223	//   "response": {
22224	//     "$ref": "GoogleCloudDialogflowV2ListSessionEntityTypesResponse"
22225	//   },
22226	//   "scopes": [
22227	//     "https://www.googleapis.com/auth/cloud-platform",
22228	//     "https://www.googleapis.com/auth/dialogflow"
22229	//   ]
22230	// }
22231
22232}
22233
22234// Pages invokes f for each page of results.
22235// A non-nil error returned from f will halt the iteration.
22236// The provided context supersedes any context provided to the Context method.
22237func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListSessionEntityTypesResponse) error) error {
22238	c.ctx_ = ctx
22239	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
22240	for {
22241		x, err := c.Do()
22242		if err != nil {
22243			return err
22244		}
22245		if err := f(x); err != nil {
22246			return err
22247		}
22248		if x.NextPageToken == "" {
22249			return nil
22250		}
22251		c.PageToken(x.NextPageToken)
22252	}
22253}
22254
22255// method id "dialogflow.projects.agent.environments.users.sessions.entityTypes.patch":
22256
22257type ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall struct {
22258	s                                        *Service
22259	nameid                                   string
22260	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
22261	urlParams_                               gensupport.URLParams
22262	ctx_                                     context.Context
22263	header_                                  http.Header
22264}
22265
22266// Patch: Updates the specified session entity type. This method doesn't
22267// work with Google Assistant integration. Contact Dialogflow support if
22268// you need to use session entities with Google Assistant integration.
22269//
22270// - name: The unique identifier of this session entity type. Format:
22271//   `projects//agent/sessions//entityTypes/`, or
22272//   `projects//agent/environments//users//sessions//entityTypes/`. If
22273//   `Environment ID` is not specified, we assume default 'draft'
22274//   environment. If `User ID` is not specified, we assume default '-'
22275//   user. `` must be the display name of an existing entity type in the
22276//   same agent that will be overridden or supplemented.
22277func (r *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService) Patch(nameid string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
22278	c := &ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22279	c.nameid = nameid
22280	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
22281	return c
22282}
22283
22284// UpdateMask sets the optional parameter "updateMask": The mask to
22285// control which fields get updated.
22286func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) UpdateMask(updateMask string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
22287	c.urlParams_.Set("updateMask", updateMask)
22288	return c
22289}
22290
22291// Fields allows partial responses to be retrieved. See
22292// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22293// for more information.
22294func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
22295	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22296	return c
22297}
22298
22299// Context sets the context to be used in this call's Do method. Any
22300// pending HTTP request will be aborted if the provided context is
22301// canceled.
22302func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
22303	c.ctx_ = ctx
22304	return c
22305}
22306
22307// Header returns an http.Header that can be modified by the caller to
22308// add HTTP headers to the request.
22309func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Header() http.Header {
22310	if c.header_ == nil {
22311		c.header_ = make(http.Header)
22312	}
22313	return c.header_
22314}
22315
22316func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) doRequest(alt string) (*http.Response, error) {
22317	reqHeaders := make(http.Header)
22318	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
22319	for k, v := range c.header_ {
22320		reqHeaders[k] = v
22321	}
22322	reqHeaders.Set("User-Agent", c.s.userAgent())
22323	var body io.Reader = nil
22324	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
22325	if err != nil {
22326		return nil, err
22327	}
22328	reqHeaders.Set("Content-Type", "application/json")
22329	c.urlParams_.Set("alt", alt)
22330	c.urlParams_.Set("prettyPrint", "false")
22331	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
22332	urls += "?" + c.urlParams_.Encode()
22333	req, err := http.NewRequest("PATCH", urls, body)
22334	if err != nil {
22335		return nil, err
22336	}
22337	req.Header = reqHeaders
22338	googleapi.Expand(req.URL, map[string]string{
22339		"name": c.nameid,
22340	})
22341	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22342}
22343
22344// Do executes the "dialogflow.projects.agent.environments.users.sessions.entityTypes.patch" call.
22345// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
22346// will be non-nil. Any non-2xx status code is an error. Response
22347// headers are in either
22348// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
22349// (if a response was returned at all) in
22350// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
22351// whether the returned error was because http.StatusNotModified was
22352// returned.
22353func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
22354	gensupport.SetOptions(c.urlParams_, opts...)
22355	res, err := c.doRequest("json")
22356	if res != nil && res.StatusCode == http.StatusNotModified {
22357		if res.Body != nil {
22358			res.Body.Close()
22359		}
22360		return nil, &googleapi.Error{
22361			Code:   res.StatusCode,
22362			Header: res.Header,
22363		}
22364	}
22365	if err != nil {
22366		return nil, err
22367	}
22368	defer googleapi.CloseBody(res)
22369	if err := googleapi.CheckResponse(res); err != nil {
22370		return nil, err
22371	}
22372	ret := &GoogleCloudDialogflowV2SessionEntityType{
22373		ServerResponse: googleapi.ServerResponse{
22374			Header:         res.Header,
22375			HTTPStatusCode: res.StatusCode,
22376		},
22377	}
22378	target := &ret
22379	if err := gensupport.DecodeResponse(target, res); err != nil {
22380		return nil, err
22381	}
22382	return ret, nil
22383	// {
22384	//   "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.",
22385	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes/{entityTypesId}",
22386	//   "httpMethod": "PATCH",
22387	//   "id": "dialogflow.projects.agent.environments.users.sessions.entityTypes.patch",
22388	//   "parameterOrder": [
22389	//     "name"
22390	//   ],
22391	//   "parameters": {
22392	//     "name": {
22393	//       "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.",
22394	//       "location": "path",
22395	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/entityTypes/[^/]+$",
22396	//       "required": true,
22397	//       "type": "string"
22398	//     },
22399	//     "updateMask": {
22400	//       "description": "Optional. The mask to control which fields get updated.",
22401	//       "format": "google-fieldmask",
22402	//       "location": "query",
22403	//       "type": "string"
22404	//     }
22405	//   },
22406	//   "path": "v2/{+name}",
22407	//   "request": {
22408	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
22409	//   },
22410	//   "response": {
22411	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
22412	//   },
22413	//   "scopes": [
22414	//     "https://www.googleapis.com/auth/cloud-platform",
22415	//     "https://www.googleapis.com/auth/dialogflow"
22416	//   ]
22417	// }
22418
22419}
22420
22421// method id "dialogflow.projects.agent.intents.batchDelete":
22422
22423type ProjectsAgentIntentsBatchDeleteCall struct {
22424	s                                                *Service
22425	parent                                           string
22426	googleclouddialogflowv2batchdeleteintentsrequest *GoogleCloudDialogflowV2BatchDeleteIntentsRequest
22427	urlParams_                                       gensupport.URLParams
22428	ctx_                                             context.Context
22429	header_                                          http.Header
22430}
22431
22432// BatchDelete: Deletes intents in the specified agent. Operation
22433//
22434// - parent: The name of the agent to delete all entities types for.
22435//   Format: `projects//agent`.
22436func (r *ProjectsAgentIntentsService) BatchDelete(parent string, googleclouddialogflowv2batchdeleteintentsrequest *GoogleCloudDialogflowV2BatchDeleteIntentsRequest) *ProjectsAgentIntentsBatchDeleteCall {
22437	c := &ProjectsAgentIntentsBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22438	c.parent = parent
22439	c.googleclouddialogflowv2batchdeleteintentsrequest = googleclouddialogflowv2batchdeleteintentsrequest
22440	return c
22441}
22442
22443// Fields allows partial responses to be retrieved. See
22444// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22445// for more information.
22446func (c *ProjectsAgentIntentsBatchDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsBatchDeleteCall {
22447	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22448	return c
22449}
22450
22451// Context sets the context to be used in this call's Do method. Any
22452// pending HTTP request will be aborted if the provided context is
22453// canceled.
22454func (c *ProjectsAgentIntentsBatchDeleteCall) Context(ctx context.Context) *ProjectsAgentIntentsBatchDeleteCall {
22455	c.ctx_ = ctx
22456	return c
22457}
22458
22459// Header returns an http.Header that can be modified by the caller to
22460// add HTTP headers to the request.
22461func (c *ProjectsAgentIntentsBatchDeleteCall) Header() http.Header {
22462	if c.header_ == nil {
22463		c.header_ = make(http.Header)
22464	}
22465	return c.header_
22466}
22467
22468func (c *ProjectsAgentIntentsBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
22469	reqHeaders := make(http.Header)
22470	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
22471	for k, v := range c.header_ {
22472		reqHeaders[k] = v
22473	}
22474	reqHeaders.Set("User-Agent", c.s.userAgent())
22475	var body io.Reader = nil
22476	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchdeleteintentsrequest)
22477	if err != nil {
22478		return nil, err
22479	}
22480	reqHeaders.Set("Content-Type", "application/json")
22481	c.urlParams_.Set("alt", alt)
22482	c.urlParams_.Set("prettyPrint", "false")
22483	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents:batchDelete")
22484	urls += "?" + c.urlParams_.Encode()
22485	req, err := http.NewRequest("POST", urls, body)
22486	if err != nil {
22487		return nil, err
22488	}
22489	req.Header = reqHeaders
22490	googleapi.Expand(req.URL, map[string]string{
22491		"parent": c.parent,
22492	})
22493	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22494}
22495
22496// Do executes the "dialogflow.projects.agent.intents.batchDelete" call.
22497// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
22498// Any non-2xx status code is an error. Response headers are in either
22499// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
22500// was returned at all) in error.(*googleapi.Error).Header. Use
22501// googleapi.IsNotModified to check whether the returned error was
22502// because http.StatusNotModified was returned.
22503func (c *ProjectsAgentIntentsBatchDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
22504	gensupport.SetOptions(c.urlParams_, opts...)
22505	res, err := c.doRequest("json")
22506	if res != nil && res.StatusCode == http.StatusNotModified {
22507		if res.Body != nil {
22508			res.Body.Close()
22509		}
22510		return nil, &googleapi.Error{
22511			Code:   res.StatusCode,
22512			Header: res.Header,
22513		}
22514	}
22515	if err != nil {
22516		return nil, err
22517	}
22518	defer googleapi.CloseBody(res)
22519	if err := googleapi.CheckResponse(res); err != nil {
22520		return nil, err
22521	}
22522	ret := &GoogleLongrunningOperation{
22523		ServerResponse: googleapi.ServerResponse{
22524			Header:         res.Header,
22525			HTTPStatusCode: res.StatusCode,
22526		},
22527	}
22528	target := &ret
22529	if err := gensupport.DecodeResponse(target, res); err != nil {
22530		return nil, err
22531	}
22532	return ret, nil
22533	// {
22534	//   "description": "Deletes intents in the specified agent. Operation ",
22535	//   "flatPath": "v2/projects/{projectsId}/agent/intents:batchDelete",
22536	//   "httpMethod": "POST",
22537	//   "id": "dialogflow.projects.agent.intents.batchDelete",
22538	//   "parameterOrder": [
22539	//     "parent"
22540	//   ],
22541	//   "parameters": {
22542	//     "parent": {
22543	//       "description": "Required. The name of the agent to delete all entities types for. Format: `projects//agent`.",
22544	//       "location": "path",
22545	//       "pattern": "^projects/[^/]+/agent$",
22546	//       "required": true,
22547	//       "type": "string"
22548	//     }
22549	//   },
22550	//   "path": "v2/{+parent}/intents:batchDelete",
22551	//   "request": {
22552	//     "$ref": "GoogleCloudDialogflowV2BatchDeleteIntentsRequest"
22553	//   },
22554	//   "response": {
22555	//     "$ref": "GoogleLongrunningOperation"
22556	//   },
22557	//   "scopes": [
22558	//     "https://www.googleapis.com/auth/cloud-platform",
22559	//     "https://www.googleapis.com/auth/dialogflow"
22560	//   ]
22561	// }
22562
22563}
22564
22565// method id "dialogflow.projects.agent.intents.batchUpdate":
22566
22567type ProjectsAgentIntentsBatchUpdateCall struct {
22568	s                                                *Service
22569	parent                                           string
22570	googleclouddialogflowv2batchupdateintentsrequest *GoogleCloudDialogflowV2BatchUpdateIntentsRequest
22571	urlParams_                                       gensupport.URLParams
22572	ctx_                                             context.Context
22573	header_                                          http.Header
22574}
22575
22576// BatchUpdate: Updates/Creates multiple intents in the specified agent.
22577// Operation
22578//
22579// - parent: The name of the agent to update or create intents in.
22580//   Format: `projects//agent`.
22581func (r *ProjectsAgentIntentsService) BatchUpdate(parent string, googleclouddialogflowv2batchupdateintentsrequest *GoogleCloudDialogflowV2BatchUpdateIntentsRequest) *ProjectsAgentIntentsBatchUpdateCall {
22582	c := &ProjectsAgentIntentsBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22583	c.parent = parent
22584	c.googleclouddialogflowv2batchupdateintentsrequest = googleclouddialogflowv2batchupdateintentsrequest
22585	return c
22586}
22587
22588// Fields allows partial responses to be retrieved. See
22589// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22590// for more information.
22591func (c *ProjectsAgentIntentsBatchUpdateCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsBatchUpdateCall {
22592	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22593	return c
22594}
22595
22596// Context sets the context to be used in this call's Do method. Any
22597// pending HTTP request will be aborted if the provided context is
22598// canceled.
22599func (c *ProjectsAgentIntentsBatchUpdateCall) Context(ctx context.Context) *ProjectsAgentIntentsBatchUpdateCall {
22600	c.ctx_ = ctx
22601	return c
22602}
22603
22604// Header returns an http.Header that can be modified by the caller to
22605// add HTTP headers to the request.
22606func (c *ProjectsAgentIntentsBatchUpdateCall) Header() http.Header {
22607	if c.header_ == nil {
22608		c.header_ = make(http.Header)
22609	}
22610	return c.header_
22611}
22612
22613func (c *ProjectsAgentIntentsBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
22614	reqHeaders := make(http.Header)
22615	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
22616	for k, v := range c.header_ {
22617		reqHeaders[k] = v
22618	}
22619	reqHeaders.Set("User-Agent", c.s.userAgent())
22620	var body io.Reader = nil
22621	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchupdateintentsrequest)
22622	if err != nil {
22623		return nil, err
22624	}
22625	reqHeaders.Set("Content-Type", "application/json")
22626	c.urlParams_.Set("alt", alt)
22627	c.urlParams_.Set("prettyPrint", "false")
22628	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents:batchUpdate")
22629	urls += "?" + c.urlParams_.Encode()
22630	req, err := http.NewRequest("POST", urls, body)
22631	if err != nil {
22632		return nil, err
22633	}
22634	req.Header = reqHeaders
22635	googleapi.Expand(req.URL, map[string]string{
22636		"parent": c.parent,
22637	})
22638	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22639}
22640
22641// Do executes the "dialogflow.projects.agent.intents.batchUpdate" call.
22642// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
22643// Any non-2xx status code is an error. Response headers are in either
22644// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
22645// was returned at all) in error.(*googleapi.Error).Header. Use
22646// googleapi.IsNotModified to check whether the returned error was
22647// because http.StatusNotModified was returned.
22648func (c *ProjectsAgentIntentsBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
22649	gensupport.SetOptions(c.urlParams_, opts...)
22650	res, err := c.doRequest("json")
22651	if res != nil && res.StatusCode == http.StatusNotModified {
22652		if res.Body != nil {
22653			res.Body.Close()
22654		}
22655		return nil, &googleapi.Error{
22656			Code:   res.StatusCode,
22657			Header: res.Header,
22658		}
22659	}
22660	if err != nil {
22661		return nil, err
22662	}
22663	defer googleapi.CloseBody(res)
22664	if err := googleapi.CheckResponse(res); err != nil {
22665		return nil, err
22666	}
22667	ret := &GoogleLongrunningOperation{
22668		ServerResponse: googleapi.ServerResponse{
22669			Header:         res.Header,
22670			HTTPStatusCode: res.StatusCode,
22671		},
22672	}
22673	target := &ret
22674	if err := gensupport.DecodeResponse(target, res); err != nil {
22675		return nil, err
22676	}
22677	return ret, nil
22678	// {
22679	//   "description": "Updates/Creates multiple intents in the specified agent. Operation ",
22680	//   "flatPath": "v2/projects/{projectsId}/agent/intents:batchUpdate",
22681	//   "httpMethod": "POST",
22682	//   "id": "dialogflow.projects.agent.intents.batchUpdate",
22683	//   "parameterOrder": [
22684	//     "parent"
22685	//   ],
22686	//   "parameters": {
22687	//     "parent": {
22688	//       "description": "Required. The name of the agent to update or create intents in. Format: `projects//agent`.",
22689	//       "location": "path",
22690	//       "pattern": "^projects/[^/]+/agent$",
22691	//       "required": true,
22692	//       "type": "string"
22693	//     }
22694	//   },
22695	//   "path": "v2/{+parent}/intents:batchUpdate",
22696	//   "request": {
22697	//     "$ref": "GoogleCloudDialogflowV2BatchUpdateIntentsRequest"
22698	//   },
22699	//   "response": {
22700	//     "$ref": "GoogleLongrunningOperation"
22701	//   },
22702	//   "scopes": [
22703	//     "https://www.googleapis.com/auth/cloud-platform",
22704	//     "https://www.googleapis.com/auth/dialogflow"
22705	//   ]
22706	// }
22707
22708}
22709
22710// method id "dialogflow.projects.agent.intents.create":
22711
22712type ProjectsAgentIntentsCreateCall struct {
22713	s                             *Service
22714	parent                        string
22715	googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent
22716	urlParams_                    gensupport.URLParams
22717	ctx_                          context.Context
22718	header_                       http.Header
22719}
22720
22721// Create: Creates an intent in the specified agent.
22722//
22723// - parent: The agent to create a intent for. Format:
22724//   `projects//agent`.
22725func (r *ProjectsAgentIntentsService) Create(parent string, googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent) *ProjectsAgentIntentsCreateCall {
22726	c := &ProjectsAgentIntentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22727	c.parent = parent
22728	c.googleclouddialogflowv2intent = googleclouddialogflowv2intent
22729	return c
22730}
22731
22732// IntentView sets the optional parameter "intentView": The resource
22733// view to apply to the returned intent.
22734//
22735// Possible values:
22736//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
22737// in the response.
22738//   "INTENT_VIEW_FULL" - All fields are populated.
22739func (c *ProjectsAgentIntentsCreateCall) IntentView(intentView string) *ProjectsAgentIntentsCreateCall {
22740	c.urlParams_.Set("intentView", intentView)
22741	return c
22742}
22743
22744// LanguageCode sets the optional parameter "languageCode": The language
22745// used to access language-specific data. If not specified, the agent's
22746// default language is used. For more information, see Multilingual
22747// intent and entity data
22748// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
22749func (c *ProjectsAgentIntentsCreateCall) LanguageCode(languageCode string) *ProjectsAgentIntentsCreateCall {
22750	c.urlParams_.Set("languageCode", languageCode)
22751	return c
22752}
22753
22754// Fields allows partial responses to be retrieved. See
22755// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22756// for more information.
22757func (c *ProjectsAgentIntentsCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsCreateCall {
22758	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22759	return c
22760}
22761
22762// Context sets the context to be used in this call's Do method. Any
22763// pending HTTP request will be aborted if the provided context is
22764// canceled.
22765func (c *ProjectsAgentIntentsCreateCall) Context(ctx context.Context) *ProjectsAgentIntentsCreateCall {
22766	c.ctx_ = ctx
22767	return c
22768}
22769
22770// Header returns an http.Header that can be modified by the caller to
22771// add HTTP headers to the request.
22772func (c *ProjectsAgentIntentsCreateCall) Header() http.Header {
22773	if c.header_ == nil {
22774		c.header_ = make(http.Header)
22775	}
22776	return c.header_
22777}
22778
22779func (c *ProjectsAgentIntentsCreateCall) doRequest(alt string) (*http.Response, error) {
22780	reqHeaders := make(http.Header)
22781	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
22782	for k, v := range c.header_ {
22783		reqHeaders[k] = v
22784	}
22785	reqHeaders.Set("User-Agent", c.s.userAgent())
22786	var body io.Reader = nil
22787	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2intent)
22788	if err != nil {
22789		return nil, err
22790	}
22791	reqHeaders.Set("Content-Type", "application/json")
22792	c.urlParams_.Set("alt", alt)
22793	c.urlParams_.Set("prettyPrint", "false")
22794	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents")
22795	urls += "?" + c.urlParams_.Encode()
22796	req, err := http.NewRequest("POST", urls, body)
22797	if err != nil {
22798		return nil, err
22799	}
22800	req.Header = reqHeaders
22801	googleapi.Expand(req.URL, map[string]string{
22802		"parent": c.parent,
22803	})
22804	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22805}
22806
22807// Do executes the "dialogflow.projects.agent.intents.create" call.
22808// Exactly one of *GoogleCloudDialogflowV2Intent or error will be
22809// non-nil. Any non-2xx status code is an error. Response headers are in
22810// either *GoogleCloudDialogflowV2Intent.ServerResponse.Header or (if a
22811// response was returned at all) in error.(*googleapi.Error).Header. Use
22812// googleapi.IsNotModified to check whether the returned error was
22813// because http.StatusNotModified was returned.
22814func (c *ProjectsAgentIntentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Intent, error) {
22815	gensupport.SetOptions(c.urlParams_, opts...)
22816	res, err := c.doRequest("json")
22817	if res != nil && res.StatusCode == http.StatusNotModified {
22818		if res.Body != nil {
22819			res.Body.Close()
22820		}
22821		return nil, &googleapi.Error{
22822			Code:   res.StatusCode,
22823			Header: res.Header,
22824		}
22825	}
22826	if err != nil {
22827		return nil, err
22828	}
22829	defer googleapi.CloseBody(res)
22830	if err := googleapi.CheckResponse(res); err != nil {
22831		return nil, err
22832	}
22833	ret := &GoogleCloudDialogflowV2Intent{
22834		ServerResponse: googleapi.ServerResponse{
22835			Header:         res.Header,
22836			HTTPStatusCode: res.StatusCode,
22837		},
22838	}
22839	target := &ret
22840	if err := gensupport.DecodeResponse(target, res); err != nil {
22841		return nil, err
22842	}
22843	return ret, nil
22844	// {
22845	//   "description": "Creates an intent in the specified agent.",
22846	//   "flatPath": "v2/projects/{projectsId}/agent/intents",
22847	//   "httpMethod": "POST",
22848	//   "id": "dialogflow.projects.agent.intents.create",
22849	//   "parameterOrder": [
22850	//     "parent"
22851	//   ],
22852	//   "parameters": {
22853	//     "intentView": {
22854	//       "description": "Optional. The resource view to apply to the returned intent.",
22855	//       "enum": [
22856	//         "INTENT_VIEW_UNSPECIFIED",
22857	//         "INTENT_VIEW_FULL"
22858	//       ],
22859	//       "enumDescriptions": [
22860	//         "Training phrases field is not populated in the response.",
22861	//         "All fields are populated."
22862	//       ],
22863	//       "location": "query",
22864	//       "type": "string"
22865	//     },
22866	//     "languageCode": {
22867	//       "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).",
22868	//       "location": "query",
22869	//       "type": "string"
22870	//     },
22871	//     "parent": {
22872	//       "description": "Required. The agent to create a intent for. Format: `projects//agent`.",
22873	//       "location": "path",
22874	//       "pattern": "^projects/[^/]+/agent$",
22875	//       "required": true,
22876	//       "type": "string"
22877	//     }
22878	//   },
22879	//   "path": "v2/{+parent}/intents",
22880	//   "request": {
22881	//     "$ref": "GoogleCloudDialogflowV2Intent"
22882	//   },
22883	//   "response": {
22884	//     "$ref": "GoogleCloudDialogflowV2Intent"
22885	//   },
22886	//   "scopes": [
22887	//     "https://www.googleapis.com/auth/cloud-platform",
22888	//     "https://www.googleapis.com/auth/dialogflow"
22889	//   ]
22890	// }
22891
22892}
22893
22894// method id "dialogflow.projects.agent.intents.delete":
22895
22896type ProjectsAgentIntentsDeleteCall struct {
22897	s          *Service
22898	name       string
22899	urlParams_ gensupport.URLParams
22900	ctx_       context.Context
22901	header_    http.Header
22902}
22903
22904// Delete: Deletes the specified intent and its direct or indirect
22905// followup intents.
22906//
22907// - name: The name of the intent to delete. If this intent has direct
22908//   or indirect followup intents, we also delete them. Format:
22909//   `projects//agent/intents/`.
22910func (r *ProjectsAgentIntentsService) Delete(name string) *ProjectsAgentIntentsDeleteCall {
22911	c := &ProjectsAgentIntentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22912	c.name = name
22913	return c
22914}
22915
22916// Fields allows partial responses to be retrieved. See
22917// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22918// for more information.
22919func (c *ProjectsAgentIntentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsDeleteCall {
22920	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22921	return c
22922}
22923
22924// Context sets the context to be used in this call's Do method. Any
22925// pending HTTP request will be aborted if the provided context is
22926// canceled.
22927func (c *ProjectsAgentIntentsDeleteCall) Context(ctx context.Context) *ProjectsAgentIntentsDeleteCall {
22928	c.ctx_ = ctx
22929	return c
22930}
22931
22932// Header returns an http.Header that can be modified by the caller to
22933// add HTTP headers to the request.
22934func (c *ProjectsAgentIntentsDeleteCall) Header() http.Header {
22935	if c.header_ == nil {
22936		c.header_ = make(http.Header)
22937	}
22938	return c.header_
22939}
22940
22941func (c *ProjectsAgentIntentsDeleteCall) doRequest(alt string) (*http.Response, error) {
22942	reqHeaders := make(http.Header)
22943	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
22944	for k, v := range c.header_ {
22945		reqHeaders[k] = v
22946	}
22947	reqHeaders.Set("User-Agent", c.s.userAgent())
22948	var body io.Reader = nil
22949	c.urlParams_.Set("alt", alt)
22950	c.urlParams_.Set("prettyPrint", "false")
22951	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
22952	urls += "?" + c.urlParams_.Encode()
22953	req, err := http.NewRequest("DELETE", urls, body)
22954	if err != nil {
22955		return nil, err
22956	}
22957	req.Header = reqHeaders
22958	googleapi.Expand(req.URL, map[string]string{
22959		"name": c.name,
22960	})
22961	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22962}
22963
22964// Do executes the "dialogflow.projects.agent.intents.delete" call.
22965// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
22966// non-2xx status code is an error. Response headers are in either
22967// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
22968// returned at all) in error.(*googleapi.Error).Header. Use
22969// googleapi.IsNotModified to check whether the returned error was
22970// because http.StatusNotModified was returned.
22971func (c *ProjectsAgentIntentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
22972	gensupport.SetOptions(c.urlParams_, opts...)
22973	res, err := c.doRequest("json")
22974	if res != nil && res.StatusCode == http.StatusNotModified {
22975		if res.Body != nil {
22976			res.Body.Close()
22977		}
22978		return nil, &googleapi.Error{
22979			Code:   res.StatusCode,
22980			Header: res.Header,
22981		}
22982	}
22983	if err != nil {
22984		return nil, err
22985	}
22986	defer googleapi.CloseBody(res)
22987	if err := googleapi.CheckResponse(res); err != nil {
22988		return nil, err
22989	}
22990	ret := &GoogleProtobufEmpty{
22991		ServerResponse: googleapi.ServerResponse{
22992			Header:         res.Header,
22993			HTTPStatusCode: res.StatusCode,
22994		},
22995	}
22996	target := &ret
22997	if err := gensupport.DecodeResponse(target, res); err != nil {
22998		return nil, err
22999	}
23000	return ret, nil
23001	// {
23002	//   "description": "Deletes the specified intent and its direct or indirect followup intents.",
23003	//   "flatPath": "v2/projects/{projectsId}/agent/intents/{intentsId}",
23004	//   "httpMethod": "DELETE",
23005	//   "id": "dialogflow.projects.agent.intents.delete",
23006	//   "parameterOrder": [
23007	//     "name"
23008	//   ],
23009	//   "parameters": {
23010	//     "name": {
23011	//       "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/`.",
23012	//       "location": "path",
23013	//       "pattern": "^projects/[^/]+/agent/intents/[^/]+$",
23014	//       "required": true,
23015	//       "type": "string"
23016	//     }
23017	//   },
23018	//   "path": "v2/{+name}",
23019	//   "response": {
23020	//     "$ref": "GoogleProtobufEmpty"
23021	//   },
23022	//   "scopes": [
23023	//     "https://www.googleapis.com/auth/cloud-platform",
23024	//     "https://www.googleapis.com/auth/dialogflow"
23025	//   ]
23026	// }
23027
23028}
23029
23030// method id "dialogflow.projects.agent.intents.get":
23031
23032type ProjectsAgentIntentsGetCall struct {
23033	s            *Service
23034	name         string
23035	urlParams_   gensupport.URLParams
23036	ifNoneMatch_ string
23037	ctx_         context.Context
23038	header_      http.Header
23039}
23040
23041// Get: Retrieves the specified intent.
23042//
23043// - name: The name of the intent. Format: `projects//agent/intents/`.
23044func (r *ProjectsAgentIntentsService) Get(name string) *ProjectsAgentIntentsGetCall {
23045	c := &ProjectsAgentIntentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23046	c.name = name
23047	return c
23048}
23049
23050// IntentView sets the optional parameter "intentView": The resource
23051// view to apply to the returned intent.
23052//
23053// Possible values:
23054//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
23055// in the response.
23056//   "INTENT_VIEW_FULL" - All fields are populated.
23057func (c *ProjectsAgentIntentsGetCall) IntentView(intentView string) *ProjectsAgentIntentsGetCall {
23058	c.urlParams_.Set("intentView", intentView)
23059	return c
23060}
23061
23062// LanguageCode sets the optional parameter "languageCode": The language
23063// used to access language-specific data. If not specified, the agent's
23064// default language is used. For more information, see Multilingual
23065// intent and entity data
23066// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
23067func (c *ProjectsAgentIntentsGetCall) LanguageCode(languageCode string) *ProjectsAgentIntentsGetCall {
23068	c.urlParams_.Set("languageCode", languageCode)
23069	return c
23070}
23071
23072// Fields allows partial responses to be retrieved. See
23073// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23074// for more information.
23075func (c *ProjectsAgentIntentsGetCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsGetCall {
23076	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23077	return c
23078}
23079
23080// IfNoneMatch sets the optional parameter which makes the operation
23081// fail if the object's ETag matches the given value. This is useful for
23082// getting updates only after the object has changed since the last
23083// request. Use googleapi.IsNotModified to check whether the response
23084// error from Do is the result of In-None-Match.
23085func (c *ProjectsAgentIntentsGetCall) IfNoneMatch(entityTag string) *ProjectsAgentIntentsGetCall {
23086	c.ifNoneMatch_ = entityTag
23087	return c
23088}
23089
23090// Context sets the context to be used in this call's Do method. Any
23091// pending HTTP request will be aborted if the provided context is
23092// canceled.
23093func (c *ProjectsAgentIntentsGetCall) Context(ctx context.Context) *ProjectsAgentIntentsGetCall {
23094	c.ctx_ = ctx
23095	return c
23096}
23097
23098// Header returns an http.Header that can be modified by the caller to
23099// add HTTP headers to the request.
23100func (c *ProjectsAgentIntentsGetCall) Header() http.Header {
23101	if c.header_ == nil {
23102		c.header_ = make(http.Header)
23103	}
23104	return c.header_
23105}
23106
23107func (c *ProjectsAgentIntentsGetCall) doRequest(alt string) (*http.Response, error) {
23108	reqHeaders := make(http.Header)
23109	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
23110	for k, v := range c.header_ {
23111		reqHeaders[k] = v
23112	}
23113	reqHeaders.Set("User-Agent", c.s.userAgent())
23114	if c.ifNoneMatch_ != "" {
23115		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23116	}
23117	var body io.Reader = nil
23118	c.urlParams_.Set("alt", alt)
23119	c.urlParams_.Set("prettyPrint", "false")
23120	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
23121	urls += "?" + c.urlParams_.Encode()
23122	req, err := http.NewRequest("GET", urls, body)
23123	if err != nil {
23124		return nil, err
23125	}
23126	req.Header = reqHeaders
23127	googleapi.Expand(req.URL, map[string]string{
23128		"name": c.name,
23129	})
23130	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23131}
23132
23133// Do executes the "dialogflow.projects.agent.intents.get" call.
23134// Exactly one of *GoogleCloudDialogflowV2Intent or error will be
23135// non-nil. Any non-2xx status code is an error. Response headers are in
23136// either *GoogleCloudDialogflowV2Intent.ServerResponse.Header or (if a
23137// response was returned at all) in error.(*googleapi.Error).Header. Use
23138// googleapi.IsNotModified to check whether the returned error was
23139// because http.StatusNotModified was returned.
23140func (c *ProjectsAgentIntentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Intent, error) {
23141	gensupport.SetOptions(c.urlParams_, opts...)
23142	res, err := c.doRequest("json")
23143	if res != nil && res.StatusCode == http.StatusNotModified {
23144		if res.Body != nil {
23145			res.Body.Close()
23146		}
23147		return nil, &googleapi.Error{
23148			Code:   res.StatusCode,
23149			Header: res.Header,
23150		}
23151	}
23152	if err != nil {
23153		return nil, err
23154	}
23155	defer googleapi.CloseBody(res)
23156	if err := googleapi.CheckResponse(res); err != nil {
23157		return nil, err
23158	}
23159	ret := &GoogleCloudDialogflowV2Intent{
23160		ServerResponse: googleapi.ServerResponse{
23161			Header:         res.Header,
23162			HTTPStatusCode: res.StatusCode,
23163		},
23164	}
23165	target := &ret
23166	if err := gensupport.DecodeResponse(target, res); err != nil {
23167		return nil, err
23168	}
23169	return ret, nil
23170	// {
23171	//   "description": "Retrieves the specified intent.",
23172	//   "flatPath": "v2/projects/{projectsId}/agent/intents/{intentsId}",
23173	//   "httpMethod": "GET",
23174	//   "id": "dialogflow.projects.agent.intents.get",
23175	//   "parameterOrder": [
23176	//     "name"
23177	//   ],
23178	//   "parameters": {
23179	//     "intentView": {
23180	//       "description": "Optional. The resource view to apply to the returned intent.",
23181	//       "enum": [
23182	//         "INTENT_VIEW_UNSPECIFIED",
23183	//         "INTENT_VIEW_FULL"
23184	//       ],
23185	//       "enumDescriptions": [
23186	//         "Training phrases field is not populated in the response.",
23187	//         "All fields are populated."
23188	//       ],
23189	//       "location": "query",
23190	//       "type": "string"
23191	//     },
23192	//     "languageCode": {
23193	//       "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).",
23194	//       "location": "query",
23195	//       "type": "string"
23196	//     },
23197	//     "name": {
23198	//       "description": "Required. The name of the intent. Format: `projects//agent/intents/`.",
23199	//       "location": "path",
23200	//       "pattern": "^projects/[^/]+/agent/intents/[^/]+$",
23201	//       "required": true,
23202	//       "type": "string"
23203	//     }
23204	//   },
23205	//   "path": "v2/{+name}",
23206	//   "response": {
23207	//     "$ref": "GoogleCloudDialogflowV2Intent"
23208	//   },
23209	//   "scopes": [
23210	//     "https://www.googleapis.com/auth/cloud-platform",
23211	//     "https://www.googleapis.com/auth/dialogflow"
23212	//   ]
23213	// }
23214
23215}
23216
23217// method id "dialogflow.projects.agent.intents.list":
23218
23219type ProjectsAgentIntentsListCall struct {
23220	s            *Service
23221	parent       string
23222	urlParams_   gensupport.URLParams
23223	ifNoneMatch_ string
23224	ctx_         context.Context
23225	header_      http.Header
23226}
23227
23228// List: Returns the list of all intents in the specified agent.
23229//
23230// - parent: The agent to list all intents from. Format:
23231//   `projects//agent`.
23232func (r *ProjectsAgentIntentsService) List(parent string) *ProjectsAgentIntentsListCall {
23233	c := &ProjectsAgentIntentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23234	c.parent = parent
23235	return c
23236}
23237
23238// IntentView sets the optional parameter "intentView": The resource
23239// view to apply to the returned intent.
23240//
23241// Possible values:
23242//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
23243// in the response.
23244//   "INTENT_VIEW_FULL" - All fields are populated.
23245func (c *ProjectsAgentIntentsListCall) IntentView(intentView string) *ProjectsAgentIntentsListCall {
23246	c.urlParams_.Set("intentView", intentView)
23247	return c
23248}
23249
23250// LanguageCode sets the optional parameter "languageCode": The language
23251// used to access language-specific data. If not specified, the agent's
23252// default language is used. For more information, see Multilingual
23253// intent and entity data
23254// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
23255func (c *ProjectsAgentIntentsListCall) LanguageCode(languageCode string) *ProjectsAgentIntentsListCall {
23256	c.urlParams_.Set("languageCode", languageCode)
23257	return c
23258}
23259
23260// PageSize sets the optional parameter "pageSize": The maximum number
23261// of items to return in a single page. By default 100 and at most 1000.
23262func (c *ProjectsAgentIntentsListCall) PageSize(pageSize int64) *ProjectsAgentIntentsListCall {
23263	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
23264	return c
23265}
23266
23267// PageToken sets the optional parameter "pageToken": The
23268// next_page_token value returned from a previous list request.
23269func (c *ProjectsAgentIntentsListCall) PageToken(pageToken string) *ProjectsAgentIntentsListCall {
23270	c.urlParams_.Set("pageToken", pageToken)
23271	return c
23272}
23273
23274// Fields allows partial responses to be retrieved. See
23275// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23276// for more information.
23277func (c *ProjectsAgentIntentsListCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsListCall {
23278	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23279	return c
23280}
23281
23282// IfNoneMatch sets the optional parameter which makes the operation
23283// fail if the object's ETag matches the given value. This is useful for
23284// getting updates only after the object has changed since the last
23285// request. Use googleapi.IsNotModified to check whether the response
23286// error from Do is the result of In-None-Match.
23287func (c *ProjectsAgentIntentsListCall) IfNoneMatch(entityTag string) *ProjectsAgentIntentsListCall {
23288	c.ifNoneMatch_ = entityTag
23289	return c
23290}
23291
23292// Context sets the context to be used in this call's Do method. Any
23293// pending HTTP request will be aborted if the provided context is
23294// canceled.
23295func (c *ProjectsAgentIntentsListCall) Context(ctx context.Context) *ProjectsAgentIntentsListCall {
23296	c.ctx_ = ctx
23297	return c
23298}
23299
23300// Header returns an http.Header that can be modified by the caller to
23301// add HTTP headers to the request.
23302func (c *ProjectsAgentIntentsListCall) Header() http.Header {
23303	if c.header_ == nil {
23304		c.header_ = make(http.Header)
23305	}
23306	return c.header_
23307}
23308
23309func (c *ProjectsAgentIntentsListCall) doRequest(alt string) (*http.Response, error) {
23310	reqHeaders := make(http.Header)
23311	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
23312	for k, v := range c.header_ {
23313		reqHeaders[k] = v
23314	}
23315	reqHeaders.Set("User-Agent", c.s.userAgent())
23316	if c.ifNoneMatch_ != "" {
23317		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23318	}
23319	var body io.Reader = nil
23320	c.urlParams_.Set("alt", alt)
23321	c.urlParams_.Set("prettyPrint", "false")
23322	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents")
23323	urls += "?" + c.urlParams_.Encode()
23324	req, err := http.NewRequest("GET", urls, body)
23325	if err != nil {
23326		return nil, err
23327	}
23328	req.Header = reqHeaders
23329	googleapi.Expand(req.URL, map[string]string{
23330		"parent": c.parent,
23331	})
23332	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23333}
23334
23335// Do executes the "dialogflow.projects.agent.intents.list" call.
23336// Exactly one of *GoogleCloudDialogflowV2ListIntentsResponse or error
23337// will be non-nil. Any non-2xx status code is an error. Response
23338// headers are in either
23339// *GoogleCloudDialogflowV2ListIntentsResponse.ServerResponse.Header or
23340// (if a response was returned at all) in
23341// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
23342// whether the returned error was because http.StatusNotModified was
23343// returned.
23344func (c *ProjectsAgentIntentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListIntentsResponse, error) {
23345	gensupport.SetOptions(c.urlParams_, opts...)
23346	res, err := c.doRequest("json")
23347	if res != nil && res.StatusCode == http.StatusNotModified {
23348		if res.Body != nil {
23349			res.Body.Close()
23350		}
23351		return nil, &googleapi.Error{
23352			Code:   res.StatusCode,
23353			Header: res.Header,
23354		}
23355	}
23356	if err != nil {
23357		return nil, err
23358	}
23359	defer googleapi.CloseBody(res)
23360	if err := googleapi.CheckResponse(res); err != nil {
23361		return nil, err
23362	}
23363	ret := &GoogleCloudDialogflowV2ListIntentsResponse{
23364		ServerResponse: googleapi.ServerResponse{
23365			Header:         res.Header,
23366			HTTPStatusCode: res.StatusCode,
23367		},
23368	}
23369	target := &ret
23370	if err := gensupport.DecodeResponse(target, res); err != nil {
23371		return nil, err
23372	}
23373	return ret, nil
23374	// {
23375	//   "description": "Returns the list of all intents in the specified agent.",
23376	//   "flatPath": "v2/projects/{projectsId}/agent/intents",
23377	//   "httpMethod": "GET",
23378	//   "id": "dialogflow.projects.agent.intents.list",
23379	//   "parameterOrder": [
23380	//     "parent"
23381	//   ],
23382	//   "parameters": {
23383	//     "intentView": {
23384	//       "description": "Optional. The resource view to apply to the returned intent.",
23385	//       "enum": [
23386	//         "INTENT_VIEW_UNSPECIFIED",
23387	//         "INTENT_VIEW_FULL"
23388	//       ],
23389	//       "enumDescriptions": [
23390	//         "Training phrases field is not populated in the response.",
23391	//         "All fields are populated."
23392	//       ],
23393	//       "location": "query",
23394	//       "type": "string"
23395	//     },
23396	//     "languageCode": {
23397	//       "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).",
23398	//       "location": "query",
23399	//       "type": "string"
23400	//     },
23401	//     "pageSize": {
23402	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
23403	//       "format": "int32",
23404	//       "location": "query",
23405	//       "type": "integer"
23406	//     },
23407	//     "pageToken": {
23408	//       "description": "Optional. The next_page_token value returned from a previous list request.",
23409	//       "location": "query",
23410	//       "type": "string"
23411	//     },
23412	//     "parent": {
23413	//       "description": "Required. The agent to list all intents from. Format: `projects//agent`.",
23414	//       "location": "path",
23415	//       "pattern": "^projects/[^/]+/agent$",
23416	//       "required": true,
23417	//       "type": "string"
23418	//     }
23419	//   },
23420	//   "path": "v2/{+parent}/intents",
23421	//   "response": {
23422	//     "$ref": "GoogleCloudDialogflowV2ListIntentsResponse"
23423	//   },
23424	//   "scopes": [
23425	//     "https://www.googleapis.com/auth/cloud-platform",
23426	//     "https://www.googleapis.com/auth/dialogflow"
23427	//   ]
23428	// }
23429
23430}
23431
23432// Pages invokes f for each page of results.
23433// A non-nil error returned from f will halt the iteration.
23434// The provided context supersedes any context provided to the Context method.
23435func (c *ProjectsAgentIntentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListIntentsResponse) error) error {
23436	c.ctx_ = ctx
23437	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
23438	for {
23439		x, err := c.Do()
23440		if err != nil {
23441			return err
23442		}
23443		if err := f(x); err != nil {
23444			return err
23445		}
23446		if x.NextPageToken == "" {
23447			return nil
23448		}
23449		c.PageToken(x.NextPageToken)
23450	}
23451}
23452
23453// method id "dialogflow.projects.agent.intents.patch":
23454
23455type ProjectsAgentIntentsPatchCall struct {
23456	s                             *Service
23457	nameid                        string
23458	googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent
23459	urlParams_                    gensupport.URLParams
23460	ctx_                          context.Context
23461	header_                       http.Header
23462}
23463
23464// Patch: Updates the specified intent.
23465//
23466// - name: Optional. The unique identifier of this intent. Required for
23467//   Intents.UpdateIntent and Intents.BatchUpdateIntents methods.
23468//   Format: `projects//agent/intents/`.
23469func (r *ProjectsAgentIntentsService) Patch(nameid string, googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent) *ProjectsAgentIntentsPatchCall {
23470	c := &ProjectsAgentIntentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23471	c.nameid = nameid
23472	c.googleclouddialogflowv2intent = googleclouddialogflowv2intent
23473	return c
23474}
23475
23476// IntentView sets the optional parameter "intentView": The resource
23477// view to apply to the returned intent.
23478//
23479// Possible values:
23480//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
23481// in the response.
23482//   "INTENT_VIEW_FULL" - All fields are populated.
23483func (c *ProjectsAgentIntentsPatchCall) IntentView(intentView string) *ProjectsAgentIntentsPatchCall {
23484	c.urlParams_.Set("intentView", intentView)
23485	return c
23486}
23487
23488// LanguageCode sets the optional parameter "languageCode": The language
23489// used to access language-specific data. If not specified, the agent's
23490// default language is used. For more information, see Multilingual
23491// intent and entity data
23492// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
23493func (c *ProjectsAgentIntentsPatchCall) LanguageCode(languageCode string) *ProjectsAgentIntentsPatchCall {
23494	c.urlParams_.Set("languageCode", languageCode)
23495	return c
23496}
23497
23498// UpdateMask sets the optional parameter "updateMask": The mask to
23499// control which fields get updated.
23500func (c *ProjectsAgentIntentsPatchCall) UpdateMask(updateMask string) *ProjectsAgentIntentsPatchCall {
23501	c.urlParams_.Set("updateMask", updateMask)
23502	return c
23503}
23504
23505// Fields allows partial responses to be retrieved. See
23506// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23507// for more information.
23508func (c *ProjectsAgentIntentsPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsPatchCall {
23509	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23510	return c
23511}
23512
23513// Context sets the context to be used in this call's Do method. Any
23514// pending HTTP request will be aborted if the provided context is
23515// canceled.
23516func (c *ProjectsAgentIntentsPatchCall) Context(ctx context.Context) *ProjectsAgentIntentsPatchCall {
23517	c.ctx_ = ctx
23518	return c
23519}
23520
23521// Header returns an http.Header that can be modified by the caller to
23522// add HTTP headers to the request.
23523func (c *ProjectsAgentIntentsPatchCall) Header() http.Header {
23524	if c.header_ == nil {
23525		c.header_ = make(http.Header)
23526	}
23527	return c.header_
23528}
23529
23530func (c *ProjectsAgentIntentsPatchCall) doRequest(alt string) (*http.Response, error) {
23531	reqHeaders := make(http.Header)
23532	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
23533	for k, v := range c.header_ {
23534		reqHeaders[k] = v
23535	}
23536	reqHeaders.Set("User-Agent", c.s.userAgent())
23537	var body io.Reader = nil
23538	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2intent)
23539	if err != nil {
23540		return nil, err
23541	}
23542	reqHeaders.Set("Content-Type", "application/json")
23543	c.urlParams_.Set("alt", alt)
23544	c.urlParams_.Set("prettyPrint", "false")
23545	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
23546	urls += "?" + c.urlParams_.Encode()
23547	req, err := http.NewRequest("PATCH", urls, body)
23548	if err != nil {
23549		return nil, err
23550	}
23551	req.Header = reqHeaders
23552	googleapi.Expand(req.URL, map[string]string{
23553		"name": c.nameid,
23554	})
23555	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23556}
23557
23558// Do executes the "dialogflow.projects.agent.intents.patch" call.
23559// Exactly one of *GoogleCloudDialogflowV2Intent or error will be
23560// non-nil. Any non-2xx status code is an error. Response headers are in
23561// either *GoogleCloudDialogflowV2Intent.ServerResponse.Header or (if a
23562// response was returned at all) in error.(*googleapi.Error).Header. Use
23563// googleapi.IsNotModified to check whether the returned error was
23564// because http.StatusNotModified was returned.
23565func (c *ProjectsAgentIntentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Intent, error) {
23566	gensupport.SetOptions(c.urlParams_, opts...)
23567	res, err := c.doRequest("json")
23568	if res != nil && res.StatusCode == http.StatusNotModified {
23569		if res.Body != nil {
23570			res.Body.Close()
23571		}
23572		return nil, &googleapi.Error{
23573			Code:   res.StatusCode,
23574			Header: res.Header,
23575		}
23576	}
23577	if err != nil {
23578		return nil, err
23579	}
23580	defer googleapi.CloseBody(res)
23581	if err := googleapi.CheckResponse(res); err != nil {
23582		return nil, err
23583	}
23584	ret := &GoogleCloudDialogflowV2Intent{
23585		ServerResponse: googleapi.ServerResponse{
23586			Header:         res.Header,
23587			HTTPStatusCode: res.StatusCode,
23588		},
23589	}
23590	target := &ret
23591	if err := gensupport.DecodeResponse(target, res); err != nil {
23592		return nil, err
23593	}
23594	return ret, nil
23595	// {
23596	//   "description": "Updates the specified intent.",
23597	//   "flatPath": "v2/projects/{projectsId}/agent/intents/{intentsId}",
23598	//   "httpMethod": "PATCH",
23599	//   "id": "dialogflow.projects.agent.intents.patch",
23600	//   "parameterOrder": [
23601	//     "name"
23602	//   ],
23603	//   "parameters": {
23604	//     "intentView": {
23605	//       "description": "Optional. The resource view to apply to the returned intent.",
23606	//       "enum": [
23607	//         "INTENT_VIEW_UNSPECIFIED",
23608	//         "INTENT_VIEW_FULL"
23609	//       ],
23610	//       "enumDescriptions": [
23611	//         "Training phrases field is not populated in the response.",
23612	//         "All fields are populated."
23613	//       ],
23614	//       "location": "query",
23615	//       "type": "string"
23616	//     },
23617	//     "languageCode": {
23618	//       "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).",
23619	//       "location": "query",
23620	//       "type": "string"
23621	//     },
23622	//     "name": {
23623	//       "description": "Optional. The unique identifier of this intent. Required for Intents.UpdateIntent and Intents.BatchUpdateIntents methods. Format: `projects//agent/intents/`.",
23624	//       "location": "path",
23625	//       "pattern": "^projects/[^/]+/agent/intents/[^/]+$",
23626	//       "required": true,
23627	//       "type": "string"
23628	//     },
23629	//     "updateMask": {
23630	//       "description": "Optional. The mask to control which fields get updated.",
23631	//       "format": "google-fieldmask",
23632	//       "location": "query",
23633	//       "type": "string"
23634	//     }
23635	//   },
23636	//   "path": "v2/{+name}",
23637	//   "request": {
23638	//     "$ref": "GoogleCloudDialogflowV2Intent"
23639	//   },
23640	//   "response": {
23641	//     "$ref": "GoogleCloudDialogflowV2Intent"
23642	//   },
23643	//   "scopes": [
23644	//     "https://www.googleapis.com/auth/cloud-platform",
23645	//     "https://www.googleapis.com/auth/dialogflow"
23646	//   ]
23647	// }
23648
23649}
23650
23651// method id "dialogflow.projects.agent.knowledgeBases.create":
23652
23653type ProjectsAgentKnowledgeBasesCreateCall struct {
23654	s                                    *Service
23655	parent                               string
23656	googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase
23657	urlParams_                           gensupport.URLParams
23658	ctx_                                 context.Context
23659	header_                              http.Header
23660}
23661
23662// Create: Creates a knowledge base.
23663//
23664// - parent: The project to create a knowledge base for. Format:
23665//   `projects//locations/`.
23666func (r *ProjectsAgentKnowledgeBasesService) Create(parent string, googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase) *ProjectsAgentKnowledgeBasesCreateCall {
23667	c := &ProjectsAgentKnowledgeBasesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23668	c.parent = parent
23669	c.googleclouddialogflowv2knowledgebase = googleclouddialogflowv2knowledgebase
23670	return c
23671}
23672
23673// Fields allows partial responses to be retrieved. See
23674// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23675// for more information.
23676func (c *ProjectsAgentKnowledgeBasesCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesCreateCall {
23677	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23678	return c
23679}
23680
23681// Context sets the context to be used in this call's Do method. Any
23682// pending HTTP request will be aborted if the provided context is
23683// canceled.
23684func (c *ProjectsAgentKnowledgeBasesCreateCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesCreateCall {
23685	c.ctx_ = ctx
23686	return c
23687}
23688
23689// Header returns an http.Header that can be modified by the caller to
23690// add HTTP headers to the request.
23691func (c *ProjectsAgentKnowledgeBasesCreateCall) Header() http.Header {
23692	if c.header_ == nil {
23693		c.header_ = make(http.Header)
23694	}
23695	return c.header_
23696}
23697
23698func (c *ProjectsAgentKnowledgeBasesCreateCall) doRequest(alt string) (*http.Response, error) {
23699	reqHeaders := make(http.Header)
23700	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
23701	for k, v := range c.header_ {
23702		reqHeaders[k] = v
23703	}
23704	reqHeaders.Set("User-Agent", c.s.userAgent())
23705	var body io.Reader = nil
23706	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2knowledgebase)
23707	if err != nil {
23708		return nil, err
23709	}
23710	reqHeaders.Set("Content-Type", "application/json")
23711	c.urlParams_.Set("alt", alt)
23712	c.urlParams_.Set("prettyPrint", "false")
23713	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/knowledgeBases")
23714	urls += "?" + c.urlParams_.Encode()
23715	req, err := http.NewRequest("POST", urls, body)
23716	if err != nil {
23717		return nil, err
23718	}
23719	req.Header = reqHeaders
23720	googleapi.Expand(req.URL, map[string]string{
23721		"parent": c.parent,
23722	})
23723	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23724}
23725
23726// Do executes the "dialogflow.projects.agent.knowledgeBases.create" call.
23727// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
23728// non-nil. Any non-2xx status code is an error. Response headers are in
23729// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
23730// (if a response was returned at all) in
23731// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
23732// whether the returned error was because http.StatusNotModified was
23733// returned.
23734func (c *ProjectsAgentKnowledgeBasesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
23735	gensupport.SetOptions(c.urlParams_, opts...)
23736	res, err := c.doRequest("json")
23737	if res != nil && res.StatusCode == http.StatusNotModified {
23738		if res.Body != nil {
23739			res.Body.Close()
23740		}
23741		return nil, &googleapi.Error{
23742			Code:   res.StatusCode,
23743			Header: res.Header,
23744		}
23745	}
23746	if err != nil {
23747		return nil, err
23748	}
23749	defer googleapi.CloseBody(res)
23750	if err := googleapi.CheckResponse(res); err != nil {
23751		return nil, err
23752	}
23753	ret := &GoogleCloudDialogflowV2KnowledgeBase{
23754		ServerResponse: googleapi.ServerResponse{
23755			Header:         res.Header,
23756			HTTPStatusCode: res.StatusCode,
23757		},
23758	}
23759	target := &ret
23760	if err := gensupport.DecodeResponse(target, res); err != nil {
23761		return nil, err
23762	}
23763	return ret, nil
23764	// {
23765	//   "description": "Creates a knowledge base.",
23766	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases",
23767	//   "httpMethod": "POST",
23768	//   "id": "dialogflow.projects.agent.knowledgeBases.create",
23769	//   "parameterOrder": [
23770	//     "parent"
23771	//   ],
23772	//   "parameters": {
23773	//     "parent": {
23774	//       "description": "Required. The project to create a knowledge base for. Format: `projects//locations/`.",
23775	//       "location": "path",
23776	//       "pattern": "^projects/[^/]+/agent$",
23777	//       "required": true,
23778	//       "type": "string"
23779	//     }
23780	//   },
23781	//   "path": "v2/{+parent}/knowledgeBases",
23782	//   "request": {
23783	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
23784	//   },
23785	//   "response": {
23786	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
23787	//   },
23788	//   "scopes": [
23789	//     "https://www.googleapis.com/auth/cloud-platform",
23790	//     "https://www.googleapis.com/auth/dialogflow"
23791	//   ]
23792	// }
23793
23794}
23795
23796// method id "dialogflow.projects.agent.knowledgeBases.delete":
23797
23798type ProjectsAgentKnowledgeBasesDeleteCall struct {
23799	s          *Service
23800	name       string
23801	urlParams_ gensupport.URLParams
23802	ctx_       context.Context
23803	header_    http.Header
23804}
23805
23806// Delete: Deletes the specified knowledge base.
23807//
23808// - name: The name of the knowledge base to delete. Format:
23809//   `projects//locations//knowledgeBases/`.
23810func (r *ProjectsAgentKnowledgeBasesService) Delete(name string) *ProjectsAgentKnowledgeBasesDeleteCall {
23811	c := &ProjectsAgentKnowledgeBasesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23812	c.name = name
23813	return c
23814}
23815
23816// Force sets the optional parameter "force": Force deletes the
23817// knowledge base. When set to true, any documents in the knowledge base
23818// are also deleted.
23819func (c *ProjectsAgentKnowledgeBasesDeleteCall) Force(force bool) *ProjectsAgentKnowledgeBasesDeleteCall {
23820	c.urlParams_.Set("force", fmt.Sprint(force))
23821	return c
23822}
23823
23824// Fields allows partial responses to be retrieved. See
23825// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23826// for more information.
23827func (c *ProjectsAgentKnowledgeBasesDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDeleteCall {
23828	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23829	return c
23830}
23831
23832// Context sets the context to be used in this call's Do method. Any
23833// pending HTTP request will be aborted if the provided context is
23834// canceled.
23835func (c *ProjectsAgentKnowledgeBasesDeleteCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDeleteCall {
23836	c.ctx_ = ctx
23837	return c
23838}
23839
23840// Header returns an http.Header that can be modified by the caller to
23841// add HTTP headers to the request.
23842func (c *ProjectsAgentKnowledgeBasesDeleteCall) Header() http.Header {
23843	if c.header_ == nil {
23844		c.header_ = make(http.Header)
23845	}
23846	return c.header_
23847}
23848
23849func (c *ProjectsAgentKnowledgeBasesDeleteCall) doRequest(alt string) (*http.Response, error) {
23850	reqHeaders := make(http.Header)
23851	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
23852	for k, v := range c.header_ {
23853		reqHeaders[k] = v
23854	}
23855	reqHeaders.Set("User-Agent", c.s.userAgent())
23856	var body io.Reader = nil
23857	c.urlParams_.Set("alt", alt)
23858	c.urlParams_.Set("prettyPrint", "false")
23859	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
23860	urls += "?" + c.urlParams_.Encode()
23861	req, err := http.NewRequest("DELETE", urls, body)
23862	if err != nil {
23863		return nil, err
23864	}
23865	req.Header = reqHeaders
23866	googleapi.Expand(req.URL, map[string]string{
23867		"name": c.name,
23868	})
23869	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23870}
23871
23872// Do executes the "dialogflow.projects.agent.knowledgeBases.delete" call.
23873// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
23874// non-2xx status code is an error. Response headers are in either
23875// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
23876// returned at all) in error.(*googleapi.Error).Header. Use
23877// googleapi.IsNotModified to check whether the returned error was
23878// because http.StatusNotModified was returned.
23879func (c *ProjectsAgentKnowledgeBasesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
23880	gensupport.SetOptions(c.urlParams_, opts...)
23881	res, err := c.doRequest("json")
23882	if res != nil && res.StatusCode == http.StatusNotModified {
23883		if res.Body != nil {
23884			res.Body.Close()
23885		}
23886		return nil, &googleapi.Error{
23887			Code:   res.StatusCode,
23888			Header: res.Header,
23889		}
23890	}
23891	if err != nil {
23892		return nil, err
23893	}
23894	defer googleapi.CloseBody(res)
23895	if err := googleapi.CheckResponse(res); err != nil {
23896		return nil, err
23897	}
23898	ret := &GoogleProtobufEmpty{
23899		ServerResponse: googleapi.ServerResponse{
23900			Header:         res.Header,
23901			HTTPStatusCode: res.StatusCode,
23902		},
23903	}
23904	target := &ret
23905	if err := gensupport.DecodeResponse(target, res); err != nil {
23906		return nil, err
23907	}
23908	return ret, nil
23909	// {
23910	//   "description": "Deletes the specified knowledge base.",
23911	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}",
23912	//   "httpMethod": "DELETE",
23913	//   "id": "dialogflow.projects.agent.knowledgeBases.delete",
23914	//   "parameterOrder": [
23915	//     "name"
23916	//   ],
23917	//   "parameters": {
23918	//     "force": {
23919	//       "description": "Optional. Force deletes the knowledge base. When set to true, any documents in the knowledge base are also deleted.",
23920	//       "location": "query",
23921	//       "type": "boolean"
23922	//     },
23923	//     "name": {
23924	//       "description": "Required. The name of the knowledge base to delete. Format: `projects//locations//knowledgeBases/`.",
23925	//       "location": "path",
23926	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+$",
23927	//       "required": true,
23928	//       "type": "string"
23929	//     }
23930	//   },
23931	//   "path": "v2/{+name}",
23932	//   "response": {
23933	//     "$ref": "GoogleProtobufEmpty"
23934	//   },
23935	//   "scopes": [
23936	//     "https://www.googleapis.com/auth/cloud-platform",
23937	//     "https://www.googleapis.com/auth/dialogflow"
23938	//   ]
23939	// }
23940
23941}
23942
23943// method id "dialogflow.projects.agent.knowledgeBases.get":
23944
23945type ProjectsAgentKnowledgeBasesGetCall struct {
23946	s            *Service
23947	name         string
23948	urlParams_   gensupport.URLParams
23949	ifNoneMatch_ string
23950	ctx_         context.Context
23951	header_      http.Header
23952}
23953
23954// Get: Retrieves the specified knowledge base.
23955//
23956// - name: The name of the knowledge base to retrieve. Format
23957//   `projects//locations//knowledgeBases/`.
23958func (r *ProjectsAgentKnowledgeBasesService) Get(name string) *ProjectsAgentKnowledgeBasesGetCall {
23959	c := &ProjectsAgentKnowledgeBasesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23960	c.name = name
23961	return c
23962}
23963
23964// Fields allows partial responses to be retrieved. See
23965// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23966// for more information.
23967func (c *ProjectsAgentKnowledgeBasesGetCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesGetCall {
23968	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23969	return c
23970}
23971
23972// IfNoneMatch sets the optional parameter which makes the operation
23973// fail if the object's ETag matches the given value. This is useful for
23974// getting updates only after the object has changed since the last
23975// request. Use googleapi.IsNotModified to check whether the response
23976// error from Do is the result of In-None-Match.
23977func (c *ProjectsAgentKnowledgeBasesGetCall) IfNoneMatch(entityTag string) *ProjectsAgentKnowledgeBasesGetCall {
23978	c.ifNoneMatch_ = entityTag
23979	return c
23980}
23981
23982// Context sets the context to be used in this call's Do method. Any
23983// pending HTTP request will be aborted if the provided context is
23984// canceled.
23985func (c *ProjectsAgentKnowledgeBasesGetCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesGetCall {
23986	c.ctx_ = ctx
23987	return c
23988}
23989
23990// Header returns an http.Header that can be modified by the caller to
23991// add HTTP headers to the request.
23992func (c *ProjectsAgentKnowledgeBasesGetCall) Header() http.Header {
23993	if c.header_ == nil {
23994		c.header_ = make(http.Header)
23995	}
23996	return c.header_
23997}
23998
23999func (c *ProjectsAgentKnowledgeBasesGetCall) doRequest(alt string) (*http.Response, error) {
24000	reqHeaders := make(http.Header)
24001	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
24002	for k, v := range c.header_ {
24003		reqHeaders[k] = v
24004	}
24005	reqHeaders.Set("User-Agent", c.s.userAgent())
24006	if c.ifNoneMatch_ != "" {
24007		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24008	}
24009	var body io.Reader = nil
24010	c.urlParams_.Set("alt", alt)
24011	c.urlParams_.Set("prettyPrint", "false")
24012	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
24013	urls += "?" + c.urlParams_.Encode()
24014	req, err := http.NewRequest("GET", urls, body)
24015	if err != nil {
24016		return nil, err
24017	}
24018	req.Header = reqHeaders
24019	googleapi.Expand(req.URL, map[string]string{
24020		"name": c.name,
24021	})
24022	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24023}
24024
24025// Do executes the "dialogflow.projects.agent.knowledgeBases.get" call.
24026// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
24027// non-nil. Any non-2xx status code is an error. Response headers are in
24028// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
24029// (if a response was returned at all) in
24030// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
24031// whether the returned error was because http.StatusNotModified was
24032// returned.
24033func (c *ProjectsAgentKnowledgeBasesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
24034	gensupport.SetOptions(c.urlParams_, opts...)
24035	res, err := c.doRequest("json")
24036	if res != nil && res.StatusCode == http.StatusNotModified {
24037		if res.Body != nil {
24038			res.Body.Close()
24039		}
24040		return nil, &googleapi.Error{
24041			Code:   res.StatusCode,
24042			Header: res.Header,
24043		}
24044	}
24045	if err != nil {
24046		return nil, err
24047	}
24048	defer googleapi.CloseBody(res)
24049	if err := googleapi.CheckResponse(res); err != nil {
24050		return nil, err
24051	}
24052	ret := &GoogleCloudDialogflowV2KnowledgeBase{
24053		ServerResponse: googleapi.ServerResponse{
24054			Header:         res.Header,
24055			HTTPStatusCode: res.StatusCode,
24056		},
24057	}
24058	target := &ret
24059	if err := gensupport.DecodeResponse(target, res); err != nil {
24060		return nil, err
24061	}
24062	return ret, nil
24063	// {
24064	//   "description": "Retrieves the specified knowledge base.",
24065	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}",
24066	//   "httpMethod": "GET",
24067	//   "id": "dialogflow.projects.agent.knowledgeBases.get",
24068	//   "parameterOrder": [
24069	//     "name"
24070	//   ],
24071	//   "parameters": {
24072	//     "name": {
24073	//       "description": "Required. The name of the knowledge base to retrieve. Format `projects//locations//knowledgeBases/`.",
24074	//       "location": "path",
24075	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+$",
24076	//       "required": true,
24077	//       "type": "string"
24078	//     }
24079	//   },
24080	//   "path": "v2/{+name}",
24081	//   "response": {
24082	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
24083	//   },
24084	//   "scopes": [
24085	//     "https://www.googleapis.com/auth/cloud-platform",
24086	//     "https://www.googleapis.com/auth/dialogflow"
24087	//   ]
24088	// }
24089
24090}
24091
24092// method id "dialogflow.projects.agent.knowledgeBases.list":
24093
24094type ProjectsAgentKnowledgeBasesListCall struct {
24095	s            *Service
24096	parent       string
24097	urlParams_   gensupport.URLParams
24098	ifNoneMatch_ string
24099	ctx_         context.Context
24100	header_      http.Header
24101}
24102
24103// List: Returns the list of all knowledge bases of the specified agent.
24104//
24105// - parent: The project to list of knowledge bases for. Format:
24106//   `projects//locations/`.
24107func (r *ProjectsAgentKnowledgeBasesService) List(parent string) *ProjectsAgentKnowledgeBasesListCall {
24108	c := &ProjectsAgentKnowledgeBasesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24109	c.parent = parent
24110	return c
24111}
24112
24113// PageSize sets the optional parameter "pageSize": The maximum number
24114// of items to return in a single page. By default 10 and at most 100.
24115func (c *ProjectsAgentKnowledgeBasesListCall) PageSize(pageSize int64) *ProjectsAgentKnowledgeBasesListCall {
24116	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
24117	return c
24118}
24119
24120// PageToken sets the optional parameter "pageToken": The
24121// next_page_token value returned from a previous list request.
24122func (c *ProjectsAgentKnowledgeBasesListCall) PageToken(pageToken string) *ProjectsAgentKnowledgeBasesListCall {
24123	c.urlParams_.Set("pageToken", pageToken)
24124	return c
24125}
24126
24127// Fields allows partial responses to be retrieved. See
24128// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24129// for more information.
24130func (c *ProjectsAgentKnowledgeBasesListCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesListCall {
24131	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24132	return c
24133}
24134
24135// IfNoneMatch sets the optional parameter which makes the operation
24136// fail if the object's ETag matches the given value. This is useful for
24137// getting updates only after the object has changed since the last
24138// request. Use googleapi.IsNotModified to check whether the response
24139// error from Do is the result of In-None-Match.
24140func (c *ProjectsAgentKnowledgeBasesListCall) IfNoneMatch(entityTag string) *ProjectsAgentKnowledgeBasesListCall {
24141	c.ifNoneMatch_ = entityTag
24142	return c
24143}
24144
24145// Context sets the context to be used in this call's Do method. Any
24146// pending HTTP request will be aborted if the provided context is
24147// canceled.
24148func (c *ProjectsAgentKnowledgeBasesListCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesListCall {
24149	c.ctx_ = ctx
24150	return c
24151}
24152
24153// Header returns an http.Header that can be modified by the caller to
24154// add HTTP headers to the request.
24155func (c *ProjectsAgentKnowledgeBasesListCall) Header() http.Header {
24156	if c.header_ == nil {
24157		c.header_ = make(http.Header)
24158	}
24159	return c.header_
24160}
24161
24162func (c *ProjectsAgentKnowledgeBasesListCall) doRequest(alt string) (*http.Response, error) {
24163	reqHeaders := make(http.Header)
24164	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
24165	for k, v := range c.header_ {
24166		reqHeaders[k] = v
24167	}
24168	reqHeaders.Set("User-Agent", c.s.userAgent())
24169	if c.ifNoneMatch_ != "" {
24170		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24171	}
24172	var body io.Reader = nil
24173	c.urlParams_.Set("alt", alt)
24174	c.urlParams_.Set("prettyPrint", "false")
24175	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/knowledgeBases")
24176	urls += "?" + c.urlParams_.Encode()
24177	req, err := http.NewRequest("GET", urls, body)
24178	if err != nil {
24179		return nil, err
24180	}
24181	req.Header = reqHeaders
24182	googleapi.Expand(req.URL, map[string]string{
24183		"parent": c.parent,
24184	})
24185	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24186}
24187
24188// Do executes the "dialogflow.projects.agent.knowledgeBases.list" call.
24189// Exactly one of *GoogleCloudDialogflowV2ListKnowledgeBasesResponse or
24190// error will be non-nil. Any non-2xx status code is an error. Response
24191// headers are in either
24192// *GoogleCloudDialogflowV2ListKnowledgeBasesResponse.ServerResponse.Head
24193// er or (if a response was returned at all) in
24194// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
24195// whether the returned error was because http.StatusNotModified was
24196// returned.
24197func (c *ProjectsAgentKnowledgeBasesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListKnowledgeBasesResponse, error) {
24198	gensupport.SetOptions(c.urlParams_, opts...)
24199	res, err := c.doRequest("json")
24200	if res != nil && res.StatusCode == http.StatusNotModified {
24201		if res.Body != nil {
24202			res.Body.Close()
24203		}
24204		return nil, &googleapi.Error{
24205			Code:   res.StatusCode,
24206			Header: res.Header,
24207		}
24208	}
24209	if err != nil {
24210		return nil, err
24211	}
24212	defer googleapi.CloseBody(res)
24213	if err := googleapi.CheckResponse(res); err != nil {
24214		return nil, err
24215	}
24216	ret := &GoogleCloudDialogflowV2ListKnowledgeBasesResponse{
24217		ServerResponse: googleapi.ServerResponse{
24218			Header:         res.Header,
24219			HTTPStatusCode: res.StatusCode,
24220		},
24221	}
24222	target := &ret
24223	if err := gensupport.DecodeResponse(target, res); err != nil {
24224		return nil, err
24225	}
24226	return ret, nil
24227	// {
24228	//   "description": "Returns the list of all knowledge bases of the specified agent.",
24229	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases",
24230	//   "httpMethod": "GET",
24231	//   "id": "dialogflow.projects.agent.knowledgeBases.list",
24232	//   "parameterOrder": [
24233	//     "parent"
24234	//   ],
24235	//   "parameters": {
24236	//     "pageSize": {
24237	//       "description": "The maximum number of items to return in a single page. By default 10 and at most 100.",
24238	//       "format": "int32",
24239	//       "location": "query",
24240	//       "type": "integer"
24241	//     },
24242	//     "pageToken": {
24243	//       "description": "The next_page_token value returned from a previous list request.",
24244	//       "location": "query",
24245	//       "type": "string"
24246	//     },
24247	//     "parent": {
24248	//       "description": "Required. The project to list of knowledge bases for. Format: `projects//locations/`.",
24249	//       "location": "path",
24250	//       "pattern": "^projects/[^/]+/agent$",
24251	//       "required": true,
24252	//       "type": "string"
24253	//     }
24254	//   },
24255	//   "path": "v2/{+parent}/knowledgeBases",
24256	//   "response": {
24257	//     "$ref": "GoogleCloudDialogflowV2ListKnowledgeBasesResponse"
24258	//   },
24259	//   "scopes": [
24260	//     "https://www.googleapis.com/auth/cloud-platform",
24261	//     "https://www.googleapis.com/auth/dialogflow"
24262	//   ]
24263	// }
24264
24265}
24266
24267// Pages invokes f for each page of results.
24268// A non-nil error returned from f will halt the iteration.
24269// The provided context supersedes any context provided to the Context method.
24270func (c *ProjectsAgentKnowledgeBasesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListKnowledgeBasesResponse) error) error {
24271	c.ctx_ = ctx
24272	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
24273	for {
24274		x, err := c.Do()
24275		if err != nil {
24276			return err
24277		}
24278		if err := f(x); err != nil {
24279			return err
24280		}
24281		if x.NextPageToken == "" {
24282			return nil
24283		}
24284		c.PageToken(x.NextPageToken)
24285	}
24286}
24287
24288// method id "dialogflow.projects.agent.knowledgeBases.patch":
24289
24290type ProjectsAgentKnowledgeBasesPatchCall struct {
24291	s                                    *Service
24292	name                                 string
24293	googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase
24294	urlParams_                           gensupport.URLParams
24295	ctx_                                 context.Context
24296	header_                              http.Header
24297}
24298
24299// Patch: Updates the specified knowledge base.
24300//
24301// - name: The knowledge base resource name. The name must be empty when
24302//   creating a knowledge base. Format:
24303//   `projects//locations//knowledgeBases/`.
24304func (r *ProjectsAgentKnowledgeBasesService) Patch(name string, googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase) *ProjectsAgentKnowledgeBasesPatchCall {
24305	c := &ProjectsAgentKnowledgeBasesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24306	c.name = name
24307	c.googleclouddialogflowv2knowledgebase = googleclouddialogflowv2knowledgebase
24308	return c
24309}
24310
24311// UpdateMask sets the optional parameter "updateMask": Not specified
24312// means `update all`. Currently, only `display_name` can be updated, an
24313// InvalidArgument will be returned for attempting to update other
24314// fields.
24315func (c *ProjectsAgentKnowledgeBasesPatchCall) UpdateMask(updateMask string) *ProjectsAgentKnowledgeBasesPatchCall {
24316	c.urlParams_.Set("updateMask", updateMask)
24317	return c
24318}
24319
24320// Fields allows partial responses to be retrieved. See
24321// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24322// for more information.
24323func (c *ProjectsAgentKnowledgeBasesPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesPatchCall {
24324	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24325	return c
24326}
24327
24328// Context sets the context to be used in this call's Do method. Any
24329// pending HTTP request will be aborted if the provided context is
24330// canceled.
24331func (c *ProjectsAgentKnowledgeBasesPatchCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesPatchCall {
24332	c.ctx_ = ctx
24333	return c
24334}
24335
24336// Header returns an http.Header that can be modified by the caller to
24337// add HTTP headers to the request.
24338func (c *ProjectsAgentKnowledgeBasesPatchCall) Header() http.Header {
24339	if c.header_ == nil {
24340		c.header_ = make(http.Header)
24341	}
24342	return c.header_
24343}
24344
24345func (c *ProjectsAgentKnowledgeBasesPatchCall) doRequest(alt string) (*http.Response, error) {
24346	reqHeaders := make(http.Header)
24347	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
24348	for k, v := range c.header_ {
24349		reqHeaders[k] = v
24350	}
24351	reqHeaders.Set("User-Agent", c.s.userAgent())
24352	var body io.Reader = nil
24353	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2knowledgebase)
24354	if err != nil {
24355		return nil, err
24356	}
24357	reqHeaders.Set("Content-Type", "application/json")
24358	c.urlParams_.Set("alt", alt)
24359	c.urlParams_.Set("prettyPrint", "false")
24360	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
24361	urls += "?" + c.urlParams_.Encode()
24362	req, err := http.NewRequest("PATCH", urls, body)
24363	if err != nil {
24364		return nil, err
24365	}
24366	req.Header = reqHeaders
24367	googleapi.Expand(req.URL, map[string]string{
24368		"name": c.name,
24369	})
24370	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24371}
24372
24373// Do executes the "dialogflow.projects.agent.knowledgeBases.patch" call.
24374// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
24375// non-nil. Any non-2xx status code is an error. Response headers are in
24376// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
24377// (if a response was returned at all) in
24378// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
24379// whether the returned error was because http.StatusNotModified was
24380// returned.
24381func (c *ProjectsAgentKnowledgeBasesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
24382	gensupport.SetOptions(c.urlParams_, opts...)
24383	res, err := c.doRequest("json")
24384	if res != nil && res.StatusCode == http.StatusNotModified {
24385		if res.Body != nil {
24386			res.Body.Close()
24387		}
24388		return nil, &googleapi.Error{
24389			Code:   res.StatusCode,
24390			Header: res.Header,
24391		}
24392	}
24393	if err != nil {
24394		return nil, err
24395	}
24396	defer googleapi.CloseBody(res)
24397	if err := googleapi.CheckResponse(res); err != nil {
24398		return nil, err
24399	}
24400	ret := &GoogleCloudDialogflowV2KnowledgeBase{
24401		ServerResponse: googleapi.ServerResponse{
24402			Header:         res.Header,
24403			HTTPStatusCode: res.StatusCode,
24404		},
24405	}
24406	target := &ret
24407	if err := gensupport.DecodeResponse(target, res); err != nil {
24408		return nil, err
24409	}
24410	return ret, nil
24411	// {
24412	//   "description": "Updates the specified knowledge base.",
24413	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}",
24414	//   "httpMethod": "PATCH",
24415	//   "id": "dialogflow.projects.agent.knowledgeBases.patch",
24416	//   "parameterOrder": [
24417	//     "name"
24418	//   ],
24419	//   "parameters": {
24420	//     "name": {
24421	//       "description": "The knowledge base resource name. The name must be empty when creating a knowledge base. Format: `projects//locations//knowledgeBases/`.",
24422	//       "location": "path",
24423	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+$",
24424	//       "required": true,
24425	//       "type": "string"
24426	//     },
24427	//     "updateMask": {
24428	//       "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.",
24429	//       "format": "google-fieldmask",
24430	//       "location": "query",
24431	//       "type": "string"
24432	//     }
24433	//   },
24434	//   "path": "v2/{+name}",
24435	//   "request": {
24436	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
24437	//   },
24438	//   "response": {
24439	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
24440	//   },
24441	//   "scopes": [
24442	//     "https://www.googleapis.com/auth/cloud-platform",
24443	//     "https://www.googleapis.com/auth/dialogflow"
24444	//   ]
24445	// }
24446
24447}
24448
24449// method id "dialogflow.projects.agent.knowledgeBases.documents.create":
24450
24451type ProjectsAgentKnowledgeBasesDocumentsCreateCall struct {
24452	s                               *Service
24453	parent                          string
24454	googleclouddialogflowv2document *GoogleCloudDialogflowV2Document
24455	urlParams_                      gensupport.URLParams
24456	ctx_                            context.Context
24457	header_                         http.Header
24458}
24459
24460// Create: Creates a new document. Operation
24461//
24462// - parent: The knowledge base to create a document for. Format:
24463//   `projects//locations//knowledgeBases/`.
24464func (r *ProjectsAgentKnowledgeBasesDocumentsService) Create(parent string, googleclouddialogflowv2document *GoogleCloudDialogflowV2Document) *ProjectsAgentKnowledgeBasesDocumentsCreateCall {
24465	c := &ProjectsAgentKnowledgeBasesDocumentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24466	c.parent = parent
24467	c.googleclouddialogflowv2document = googleclouddialogflowv2document
24468	return c
24469}
24470
24471// Fields allows partial responses to be retrieved. See
24472// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24473// for more information.
24474func (c *ProjectsAgentKnowledgeBasesDocumentsCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDocumentsCreateCall {
24475	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24476	return c
24477}
24478
24479// Context sets the context to be used in this call's Do method. Any
24480// pending HTTP request will be aborted if the provided context is
24481// canceled.
24482func (c *ProjectsAgentKnowledgeBasesDocumentsCreateCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDocumentsCreateCall {
24483	c.ctx_ = ctx
24484	return c
24485}
24486
24487// Header returns an http.Header that can be modified by the caller to
24488// add HTTP headers to the request.
24489func (c *ProjectsAgentKnowledgeBasesDocumentsCreateCall) Header() http.Header {
24490	if c.header_ == nil {
24491		c.header_ = make(http.Header)
24492	}
24493	return c.header_
24494}
24495
24496func (c *ProjectsAgentKnowledgeBasesDocumentsCreateCall) doRequest(alt string) (*http.Response, error) {
24497	reqHeaders := make(http.Header)
24498	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
24499	for k, v := range c.header_ {
24500		reqHeaders[k] = v
24501	}
24502	reqHeaders.Set("User-Agent", c.s.userAgent())
24503	var body io.Reader = nil
24504	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2document)
24505	if err != nil {
24506		return nil, err
24507	}
24508	reqHeaders.Set("Content-Type", "application/json")
24509	c.urlParams_.Set("alt", alt)
24510	c.urlParams_.Set("prettyPrint", "false")
24511	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/documents")
24512	urls += "?" + c.urlParams_.Encode()
24513	req, err := http.NewRequest("POST", urls, body)
24514	if err != nil {
24515		return nil, err
24516	}
24517	req.Header = reqHeaders
24518	googleapi.Expand(req.URL, map[string]string{
24519		"parent": c.parent,
24520	})
24521	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24522}
24523
24524// Do executes the "dialogflow.projects.agent.knowledgeBases.documents.create" call.
24525// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
24526// Any non-2xx status code is an error. Response headers are in either
24527// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
24528// was returned at all) in error.(*googleapi.Error).Header. Use
24529// googleapi.IsNotModified to check whether the returned error was
24530// because http.StatusNotModified was returned.
24531func (c *ProjectsAgentKnowledgeBasesDocumentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
24532	gensupport.SetOptions(c.urlParams_, opts...)
24533	res, err := c.doRequest("json")
24534	if res != nil && res.StatusCode == http.StatusNotModified {
24535		if res.Body != nil {
24536			res.Body.Close()
24537		}
24538		return nil, &googleapi.Error{
24539			Code:   res.StatusCode,
24540			Header: res.Header,
24541		}
24542	}
24543	if err != nil {
24544		return nil, err
24545	}
24546	defer googleapi.CloseBody(res)
24547	if err := googleapi.CheckResponse(res); err != nil {
24548		return nil, err
24549	}
24550	ret := &GoogleLongrunningOperation{
24551		ServerResponse: googleapi.ServerResponse{
24552			Header:         res.Header,
24553			HTTPStatusCode: res.StatusCode,
24554		},
24555	}
24556	target := &ret
24557	if err := gensupport.DecodeResponse(target, res); err != nil {
24558		return nil, err
24559	}
24560	return ret, nil
24561	// {
24562	//   "description": "Creates a new document. Operation ",
24563	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}/documents",
24564	//   "httpMethod": "POST",
24565	//   "id": "dialogflow.projects.agent.knowledgeBases.documents.create",
24566	//   "parameterOrder": [
24567	//     "parent"
24568	//   ],
24569	//   "parameters": {
24570	//     "parent": {
24571	//       "description": "Required. The knowledge base to create a document for. Format: `projects//locations//knowledgeBases/`.",
24572	//       "location": "path",
24573	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+$",
24574	//       "required": true,
24575	//       "type": "string"
24576	//     }
24577	//   },
24578	//   "path": "v2/{+parent}/documents",
24579	//   "request": {
24580	//     "$ref": "GoogleCloudDialogflowV2Document"
24581	//   },
24582	//   "response": {
24583	//     "$ref": "GoogleLongrunningOperation"
24584	//   },
24585	//   "scopes": [
24586	//     "https://www.googleapis.com/auth/cloud-platform",
24587	//     "https://www.googleapis.com/auth/dialogflow"
24588	//   ]
24589	// }
24590
24591}
24592
24593// method id "dialogflow.projects.agent.knowledgeBases.documents.delete":
24594
24595type ProjectsAgentKnowledgeBasesDocumentsDeleteCall struct {
24596	s          *Service
24597	name       string
24598	urlParams_ gensupport.URLParams
24599	ctx_       context.Context
24600	header_    http.Header
24601}
24602
24603// Delete: Deletes the specified document. Operation
24604//
24605// - name: The name of the document to delete. Format:
24606//   `projects//locations//knowledgeBases//documents/`.
24607func (r *ProjectsAgentKnowledgeBasesDocumentsService) Delete(name string) *ProjectsAgentKnowledgeBasesDocumentsDeleteCall {
24608	c := &ProjectsAgentKnowledgeBasesDocumentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24609	c.name = name
24610	return c
24611}
24612
24613// Fields allows partial responses to be retrieved. See
24614// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24615// for more information.
24616func (c *ProjectsAgentKnowledgeBasesDocumentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDocumentsDeleteCall {
24617	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24618	return c
24619}
24620
24621// Context sets the context to be used in this call's Do method. Any
24622// pending HTTP request will be aborted if the provided context is
24623// canceled.
24624func (c *ProjectsAgentKnowledgeBasesDocumentsDeleteCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDocumentsDeleteCall {
24625	c.ctx_ = ctx
24626	return c
24627}
24628
24629// Header returns an http.Header that can be modified by the caller to
24630// add HTTP headers to the request.
24631func (c *ProjectsAgentKnowledgeBasesDocumentsDeleteCall) Header() http.Header {
24632	if c.header_ == nil {
24633		c.header_ = make(http.Header)
24634	}
24635	return c.header_
24636}
24637
24638func (c *ProjectsAgentKnowledgeBasesDocumentsDeleteCall) doRequest(alt string) (*http.Response, error) {
24639	reqHeaders := make(http.Header)
24640	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
24641	for k, v := range c.header_ {
24642		reqHeaders[k] = v
24643	}
24644	reqHeaders.Set("User-Agent", c.s.userAgent())
24645	var body io.Reader = nil
24646	c.urlParams_.Set("alt", alt)
24647	c.urlParams_.Set("prettyPrint", "false")
24648	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
24649	urls += "?" + c.urlParams_.Encode()
24650	req, err := http.NewRequest("DELETE", urls, body)
24651	if err != nil {
24652		return nil, err
24653	}
24654	req.Header = reqHeaders
24655	googleapi.Expand(req.URL, map[string]string{
24656		"name": c.name,
24657	})
24658	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24659}
24660
24661// Do executes the "dialogflow.projects.agent.knowledgeBases.documents.delete" call.
24662// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
24663// Any non-2xx status code is an error. Response headers are in either
24664// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
24665// was returned at all) in error.(*googleapi.Error).Header. Use
24666// googleapi.IsNotModified to check whether the returned error was
24667// because http.StatusNotModified was returned.
24668func (c *ProjectsAgentKnowledgeBasesDocumentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
24669	gensupport.SetOptions(c.urlParams_, opts...)
24670	res, err := c.doRequest("json")
24671	if res != nil && res.StatusCode == http.StatusNotModified {
24672		if res.Body != nil {
24673			res.Body.Close()
24674		}
24675		return nil, &googleapi.Error{
24676			Code:   res.StatusCode,
24677			Header: res.Header,
24678		}
24679	}
24680	if err != nil {
24681		return nil, err
24682	}
24683	defer googleapi.CloseBody(res)
24684	if err := googleapi.CheckResponse(res); err != nil {
24685		return nil, err
24686	}
24687	ret := &GoogleLongrunningOperation{
24688		ServerResponse: googleapi.ServerResponse{
24689			Header:         res.Header,
24690			HTTPStatusCode: res.StatusCode,
24691		},
24692	}
24693	target := &ret
24694	if err := gensupport.DecodeResponse(target, res); err != nil {
24695		return nil, err
24696	}
24697	return ret, nil
24698	// {
24699	//   "description": "Deletes the specified document. Operation ",
24700	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
24701	//   "httpMethod": "DELETE",
24702	//   "id": "dialogflow.projects.agent.knowledgeBases.documents.delete",
24703	//   "parameterOrder": [
24704	//     "name"
24705	//   ],
24706	//   "parameters": {
24707	//     "name": {
24708	//       "description": "Required. The name of the document to delete. Format: `projects//locations//knowledgeBases//documents/`.",
24709	//       "location": "path",
24710	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+/documents/[^/]+$",
24711	//       "required": true,
24712	//       "type": "string"
24713	//     }
24714	//   },
24715	//   "path": "v2/{+name}",
24716	//   "response": {
24717	//     "$ref": "GoogleLongrunningOperation"
24718	//   },
24719	//   "scopes": [
24720	//     "https://www.googleapis.com/auth/cloud-platform",
24721	//     "https://www.googleapis.com/auth/dialogflow"
24722	//   ]
24723	// }
24724
24725}
24726
24727// method id "dialogflow.projects.agent.knowledgeBases.documents.get":
24728
24729type ProjectsAgentKnowledgeBasesDocumentsGetCall struct {
24730	s            *Service
24731	name         string
24732	urlParams_   gensupport.URLParams
24733	ifNoneMatch_ string
24734	ctx_         context.Context
24735	header_      http.Header
24736}
24737
24738// Get: Retrieves the specified document.
24739//
24740// - name: The name of the document to retrieve. Format
24741//   `projects//locations//knowledgeBases//documents/`.
24742func (r *ProjectsAgentKnowledgeBasesDocumentsService) Get(name string) *ProjectsAgentKnowledgeBasesDocumentsGetCall {
24743	c := &ProjectsAgentKnowledgeBasesDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24744	c.name = name
24745	return c
24746}
24747
24748// Fields allows partial responses to be retrieved. See
24749// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24750// for more information.
24751func (c *ProjectsAgentKnowledgeBasesDocumentsGetCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDocumentsGetCall {
24752	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24753	return c
24754}
24755
24756// IfNoneMatch sets the optional parameter which makes the operation
24757// fail if the object's ETag matches the given value. This is useful for
24758// getting updates only after the object has changed since the last
24759// request. Use googleapi.IsNotModified to check whether the response
24760// error from Do is the result of In-None-Match.
24761func (c *ProjectsAgentKnowledgeBasesDocumentsGetCall) IfNoneMatch(entityTag string) *ProjectsAgentKnowledgeBasesDocumentsGetCall {
24762	c.ifNoneMatch_ = entityTag
24763	return c
24764}
24765
24766// Context sets the context to be used in this call's Do method. Any
24767// pending HTTP request will be aborted if the provided context is
24768// canceled.
24769func (c *ProjectsAgentKnowledgeBasesDocumentsGetCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDocumentsGetCall {
24770	c.ctx_ = ctx
24771	return c
24772}
24773
24774// Header returns an http.Header that can be modified by the caller to
24775// add HTTP headers to the request.
24776func (c *ProjectsAgentKnowledgeBasesDocumentsGetCall) Header() http.Header {
24777	if c.header_ == nil {
24778		c.header_ = make(http.Header)
24779	}
24780	return c.header_
24781}
24782
24783func (c *ProjectsAgentKnowledgeBasesDocumentsGetCall) doRequest(alt string) (*http.Response, error) {
24784	reqHeaders := make(http.Header)
24785	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
24786	for k, v := range c.header_ {
24787		reqHeaders[k] = v
24788	}
24789	reqHeaders.Set("User-Agent", c.s.userAgent())
24790	if c.ifNoneMatch_ != "" {
24791		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24792	}
24793	var body io.Reader = nil
24794	c.urlParams_.Set("alt", alt)
24795	c.urlParams_.Set("prettyPrint", "false")
24796	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
24797	urls += "?" + c.urlParams_.Encode()
24798	req, err := http.NewRequest("GET", urls, body)
24799	if err != nil {
24800		return nil, err
24801	}
24802	req.Header = reqHeaders
24803	googleapi.Expand(req.URL, map[string]string{
24804		"name": c.name,
24805	})
24806	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24807}
24808
24809// Do executes the "dialogflow.projects.agent.knowledgeBases.documents.get" call.
24810// Exactly one of *GoogleCloudDialogflowV2Document or error will be
24811// non-nil. Any non-2xx status code is an error. Response headers are in
24812// either *GoogleCloudDialogflowV2Document.ServerResponse.Header or (if
24813// a response was returned at all) in error.(*googleapi.Error).Header.
24814// Use googleapi.IsNotModified to check whether the returned error was
24815// because http.StatusNotModified was returned.
24816func (c *ProjectsAgentKnowledgeBasesDocumentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Document, error) {
24817	gensupport.SetOptions(c.urlParams_, opts...)
24818	res, err := c.doRequest("json")
24819	if res != nil && res.StatusCode == http.StatusNotModified {
24820		if res.Body != nil {
24821			res.Body.Close()
24822		}
24823		return nil, &googleapi.Error{
24824			Code:   res.StatusCode,
24825			Header: res.Header,
24826		}
24827	}
24828	if err != nil {
24829		return nil, err
24830	}
24831	defer googleapi.CloseBody(res)
24832	if err := googleapi.CheckResponse(res); err != nil {
24833		return nil, err
24834	}
24835	ret := &GoogleCloudDialogflowV2Document{
24836		ServerResponse: googleapi.ServerResponse{
24837			Header:         res.Header,
24838			HTTPStatusCode: res.StatusCode,
24839		},
24840	}
24841	target := &ret
24842	if err := gensupport.DecodeResponse(target, res); err != nil {
24843		return nil, err
24844	}
24845	return ret, nil
24846	// {
24847	//   "description": "Retrieves the specified document.",
24848	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
24849	//   "httpMethod": "GET",
24850	//   "id": "dialogflow.projects.agent.knowledgeBases.documents.get",
24851	//   "parameterOrder": [
24852	//     "name"
24853	//   ],
24854	//   "parameters": {
24855	//     "name": {
24856	//       "description": "Required. The name of the document to retrieve. Format `projects//locations//knowledgeBases//documents/`.",
24857	//       "location": "path",
24858	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+/documents/[^/]+$",
24859	//       "required": true,
24860	//       "type": "string"
24861	//     }
24862	//   },
24863	//   "path": "v2/{+name}",
24864	//   "response": {
24865	//     "$ref": "GoogleCloudDialogflowV2Document"
24866	//   },
24867	//   "scopes": [
24868	//     "https://www.googleapis.com/auth/cloud-platform",
24869	//     "https://www.googleapis.com/auth/dialogflow"
24870	//   ]
24871	// }
24872
24873}
24874
24875// method id "dialogflow.projects.agent.knowledgeBases.documents.list":
24876
24877type ProjectsAgentKnowledgeBasesDocumentsListCall struct {
24878	s            *Service
24879	parent       string
24880	urlParams_   gensupport.URLParams
24881	ifNoneMatch_ string
24882	ctx_         context.Context
24883	header_      http.Header
24884}
24885
24886// List: Returns the list of all documents of the knowledge base.
24887//
24888// - parent: The knowledge base to list all documents for. Format:
24889//   `projects//locations//knowledgeBases/`.
24890func (r *ProjectsAgentKnowledgeBasesDocumentsService) List(parent string) *ProjectsAgentKnowledgeBasesDocumentsListCall {
24891	c := &ProjectsAgentKnowledgeBasesDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24892	c.parent = parent
24893	return c
24894}
24895
24896// PageSize sets the optional parameter "pageSize": The maximum number
24897// of items to return in a single page. By default 10 and at most 100.
24898func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) PageSize(pageSize int64) *ProjectsAgentKnowledgeBasesDocumentsListCall {
24899	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
24900	return c
24901}
24902
24903// PageToken sets the optional parameter "pageToken": The
24904// next_page_token value returned from a previous list request.
24905func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) PageToken(pageToken string) *ProjectsAgentKnowledgeBasesDocumentsListCall {
24906	c.urlParams_.Set("pageToken", pageToken)
24907	return c
24908}
24909
24910// Fields allows partial responses to be retrieved. See
24911// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24912// for more information.
24913func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDocumentsListCall {
24914	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24915	return c
24916}
24917
24918// IfNoneMatch sets the optional parameter which makes the operation
24919// fail if the object's ETag matches the given value. This is useful for
24920// getting updates only after the object has changed since the last
24921// request. Use googleapi.IsNotModified to check whether the response
24922// error from Do is the result of In-None-Match.
24923func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) IfNoneMatch(entityTag string) *ProjectsAgentKnowledgeBasesDocumentsListCall {
24924	c.ifNoneMatch_ = entityTag
24925	return c
24926}
24927
24928// Context sets the context to be used in this call's Do method. Any
24929// pending HTTP request will be aborted if the provided context is
24930// canceled.
24931func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDocumentsListCall {
24932	c.ctx_ = ctx
24933	return c
24934}
24935
24936// Header returns an http.Header that can be modified by the caller to
24937// add HTTP headers to the request.
24938func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) Header() http.Header {
24939	if c.header_ == nil {
24940		c.header_ = make(http.Header)
24941	}
24942	return c.header_
24943}
24944
24945func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) doRequest(alt string) (*http.Response, error) {
24946	reqHeaders := make(http.Header)
24947	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
24948	for k, v := range c.header_ {
24949		reqHeaders[k] = v
24950	}
24951	reqHeaders.Set("User-Agent", c.s.userAgent())
24952	if c.ifNoneMatch_ != "" {
24953		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24954	}
24955	var body io.Reader = nil
24956	c.urlParams_.Set("alt", alt)
24957	c.urlParams_.Set("prettyPrint", "false")
24958	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/documents")
24959	urls += "?" + c.urlParams_.Encode()
24960	req, err := http.NewRequest("GET", urls, body)
24961	if err != nil {
24962		return nil, err
24963	}
24964	req.Header = reqHeaders
24965	googleapi.Expand(req.URL, map[string]string{
24966		"parent": c.parent,
24967	})
24968	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24969}
24970
24971// Do executes the "dialogflow.projects.agent.knowledgeBases.documents.list" call.
24972// Exactly one of *GoogleCloudDialogflowV2ListDocumentsResponse or error
24973// will be non-nil. Any non-2xx status code is an error. Response
24974// headers are in either
24975// *GoogleCloudDialogflowV2ListDocumentsResponse.ServerResponse.Header
24976// or (if a response was returned at all) in
24977// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
24978// whether the returned error was because http.StatusNotModified was
24979// returned.
24980func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListDocumentsResponse, error) {
24981	gensupport.SetOptions(c.urlParams_, opts...)
24982	res, err := c.doRequest("json")
24983	if res != nil && res.StatusCode == http.StatusNotModified {
24984		if res.Body != nil {
24985			res.Body.Close()
24986		}
24987		return nil, &googleapi.Error{
24988			Code:   res.StatusCode,
24989			Header: res.Header,
24990		}
24991	}
24992	if err != nil {
24993		return nil, err
24994	}
24995	defer googleapi.CloseBody(res)
24996	if err := googleapi.CheckResponse(res); err != nil {
24997		return nil, err
24998	}
24999	ret := &GoogleCloudDialogflowV2ListDocumentsResponse{
25000		ServerResponse: googleapi.ServerResponse{
25001			Header:         res.Header,
25002			HTTPStatusCode: res.StatusCode,
25003		},
25004	}
25005	target := &ret
25006	if err := gensupport.DecodeResponse(target, res); err != nil {
25007		return nil, err
25008	}
25009	return ret, nil
25010	// {
25011	//   "description": "Returns the list of all documents of the knowledge base.",
25012	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}/documents",
25013	//   "httpMethod": "GET",
25014	//   "id": "dialogflow.projects.agent.knowledgeBases.documents.list",
25015	//   "parameterOrder": [
25016	//     "parent"
25017	//   ],
25018	//   "parameters": {
25019	//     "pageSize": {
25020	//       "description": "The maximum number of items to return in a single page. By default 10 and at most 100.",
25021	//       "format": "int32",
25022	//       "location": "query",
25023	//       "type": "integer"
25024	//     },
25025	//     "pageToken": {
25026	//       "description": "The next_page_token value returned from a previous list request.",
25027	//       "location": "query",
25028	//       "type": "string"
25029	//     },
25030	//     "parent": {
25031	//       "description": "Required. The knowledge base to list all documents for. Format: `projects//locations//knowledgeBases/`.",
25032	//       "location": "path",
25033	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+$",
25034	//       "required": true,
25035	//       "type": "string"
25036	//     }
25037	//   },
25038	//   "path": "v2/{+parent}/documents",
25039	//   "response": {
25040	//     "$ref": "GoogleCloudDialogflowV2ListDocumentsResponse"
25041	//   },
25042	//   "scopes": [
25043	//     "https://www.googleapis.com/auth/cloud-platform",
25044	//     "https://www.googleapis.com/auth/dialogflow"
25045	//   ]
25046	// }
25047
25048}
25049
25050// Pages invokes f for each page of results.
25051// A non-nil error returned from f will halt the iteration.
25052// The provided context supersedes any context provided to the Context method.
25053func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListDocumentsResponse) error) error {
25054	c.ctx_ = ctx
25055	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
25056	for {
25057		x, err := c.Do()
25058		if err != nil {
25059			return err
25060		}
25061		if err := f(x); err != nil {
25062			return err
25063		}
25064		if x.NextPageToken == "" {
25065			return nil
25066		}
25067		c.PageToken(x.NextPageToken)
25068	}
25069}
25070
25071// method id "dialogflow.projects.agent.knowledgeBases.documents.patch":
25072
25073type ProjectsAgentKnowledgeBasesDocumentsPatchCall struct {
25074	s                               *Service
25075	name                            string
25076	googleclouddialogflowv2document *GoogleCloudDialogflowV2Document
25077	urlParams_                      gensupport.URLParams
25078	ctx_                            context.Context
25079	header_                         http.Header
25080}
25081
25082// Patch: Updates the specified document. Operation
25083//
25084// - name: Optional. The document resource name. The name must be empty
25085//   when creating a document. Format:
25086//   `projects//locations//knowledgeBases//documents/`.
25087func (r *ProjectsAgentKnowledgeBasesDocumentsService) Patch(name string, googleclouddialogflowv2document *GoogleCloudDialogflowV2Document) *ProjectsAgentKnowledgeBasesDocumentsPatchCall {
25088	c := &ProjectsAgentKnowledgeBasesDocumentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25089	c.name = name
25090	c.googleclouddialogflowv2document = googleclouddialogflowv2document
25091	return c
25092}
25093
25094// UpdateMask sets the optional parameter "updateMask": Not specified
25095// means `update all`. Currently, only `display_name` can be updated, an
25096// InvalidArgument will be returned for attempting to update other
25097// fields.
25098func (c *ProjectsAgentKnowledgeBasesDocumentsPatchCall) UpdateMask(updateMask string) *ProjectsAgentKnowledgeBasesDocumentsPatchCall {
25099	c.urlParams_.Set("updateMask", updateMask)
25100	return c
25101}
25102
25103// Fields allows partial responses to be retrieved. See
25104// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25105// for more information.
25106func (c *ProjectsAgentKnowledgeBasesDocumentsPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDocumentsPatchCall {
25107	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25108	return c
25109}
25110
25111// Context sets the context to be used in this call's Do method. Any
25112// pending HTTP request will be aborted if the provided context is
25113// canceled.
25114func (c *ProjectsAgentKnowledgeBasesDocumentsPatchCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDocumentsPatchCall {
25115	c.ctx_ = ctx
25116	return c
25117}
25118
25119// Header returns an http.Header that can be modified by the caller to
25120// add HTTP headers to the request.
25121func (c *ProjectsAgentKnowledgeBasesDocumentsPatchCall) Header() http.Header {
25122	if c.header_ == nil {
25123		c.header_ = make(http.Header)
25124	}
25125	return c.header_
25126}
25127
25128func (c *ProjectsAgentKnowledgeBasesDocumentsPatchCall) doRequest(alt string) (*http.Response, error) {
25129	reqHeaders := make(http.Header)
25130	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
25131	for k, v := range c.header_ {
25132		reqHeaders[k] = v
25133	}
25134	reqHeaders.Set("User-Agent", c.s.userAgent())
25135	var body io.Reader = nil
25136	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2document)
25137	if err != nil {
25138		return nil, err
25139	}
25140	reqHeaders.Set("Content-Type", "application/json")
25141	c.urlParams_.Set("alt", alt)
25142	c.urlParams_.Set("prettyPrint", "false")
25143	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
25144	urls += "?" + c.urlParams_.Encode()
25145	req, err := http.NewRequest("PATCH", urls, body)
25146	if err != nil {
25147		return nil, err
25148	}
25149	req.Header = reqHeaders
25150	googleapi.Expand(req.URL, map[string]string{
25151		"name": c.name,
25152	})
25153	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25154}
25155
25156// Do executes the "dialogflow.projects.agent.knowledgeBases.documents.patch" call.
25157// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
25158// Any non-2xx status code is an error. Response headers are in either
25159// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
25160// was returned at all) in error.(*googleapi.Error).Header. Use
25161// googleapi.IsNotModified to check whether the returned error was
25162// because http.StatusNotModified was returned.
25163func (c *ProjectsAgentKnowledgeBasesDocumentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
25164	gensupport.SetOptions(c.urlParams_, opts...)
25165	res, err := c.doRequest("json")
25166	if res != nil && res.StatusCode == http.StatusNotModified {
25167		if res.Body != nil {
25168			res.Body.Close()
25169		}
25170		return nil, &googleapi.Error{
25171			Code:   res.StatusCode,
25172			Header: res.Header,
25173		}
25174	}
25175	if err != nil {
25176		return nil, err
25177	}
25178	defer googleapi.CloseBody(res)
25179	if err := googleapi.CheckResponse(res); err != nil {
25180		return nil, err
25181	}
25182	ret := &GoogleLongrunningOperation{
25183		ServerResponse: googleapi.ServerResponse{
25184			Header:         res.Header,
25185			HTTPStatusCode: res.StatusCode,
25186		},
25187	}
25188	target := &ret
25189	if err := gensupport.DecodeResponse(target, res); err != nil {
25190		return nil, err
25191	}
25192	return ret, nil
25193	// {
25194	//   "description": "Updates the specified document. Operation ",
25195	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
25196	//   "httpMethod": "PATCH",
25197	//   "id": "dialogflow.projects.agent.knowledgeBases.documents.patch",
25198	//   "parameterOrder": [
25199	//     "name"
25200	//   ],
25201	//   "parameters": {
25202	//     "name": {
25203	//       "description": "Optional. The document resource name. The name must be empty when creating a document. Format: `projects//locations//knowledgeBases//documents/`.",
25204	//       "location": "path",
25205	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+/documents/[^/]+$",
25206	//       "required": true,
25207	//       "type": "string"
25208	//     },
25209	//     "updateMask": {
25210	//       "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.",
25211	//       "format": "google-fieldmask",
25212	//       "location": "query",
25213	//       "type": "string"
25214	//     }
25215	//   },
25216	//   "path": "v2/{+name}",
25217	//   "request": {
25218	//     "$ref": "GoogleCloudDialogflowV2Document"
25219	//   },
25220	//   "response": {
25221	//     "$ref": "GoogleLongrunningOperation"
25222	//   },
25223	//   "scopes": [
25224	//     "https://www.googleapis.com/auth/cloud-platform",
25225	//     "https://www.googleapis.com/auth/dialogflow"
25226	//   ]
25227	// }
25228
25229}
25230
25231// method id "dialogflow.projects.agent.knowledgeBases.documents.reload":
25232
25233type ProjectsAgentKnowledgeBasesDocumentsReloadCall struct {
25234	s                                            *Service
25235	name                                         string
25236	googleclouddialogflowv2reloaddocumentrequest *GoogleCloudDialogflowV2ReloadDocumentRequest
25237	urlParams_                                   gensupport.URLParams
25238	ctx_                                         context.Context
25239	header_                                      http.Header
25240}
25241
25242// Reload: Reloads the specified document from its specified source,
25243// content_uri or content. The previously loaded content of the document
25244// will be deleted. Note: Even when the content of the document has not
25245// changed, there still may be side effects because of internal
25246// implementation changes. Note: The
25247// `projects.agent.knowledgeBases.documents` resource is deprecated;
25248// only use `projects.knowledgeBases.documents`. Operation
25249//
25250// - name: The name of the document to reload. Format:
25251//   `projects//locations//knowledgeBases//documents/`.
25252func (r *ProjectsAgentKnowledgeBasesDocumentsService) Reload(name string, googleclouddialogflowv2reloaddocumentrequest *GoogleCloudDialogflowV2ReloadDocumentRequest) *ProjectsAgentKnowledgeBasesDocumentsReloadCall {
25253	c := &ProjectsAgentKnowledgeBasesDocumentsReloadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25254	c.name = name
25255	c.googleclouddialogflowv2reloaddocumentrequest = googleclouddialogflowv2reloaddocumentrequest
25256	return c
25257}
25258
25259// Fields allows partial responses to be retrieved. See
25260// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25261// for more information.
25262func (c *ProjectsAgentKnowledgeBasesDocumentsReloadCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDocumentsReloadCall {
25263	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25264	return c
25265}
25266
25267// Context sets the context to be used in this call's Do method. Any
25268// pending HTTP request will be aborted if the provided context is
25269// canceled.
25270func (c *ProjectsAgentKnowledgeBasesDocumentsReloadCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDocumentsReloadCall {
25271	c.ctx_ = ctx
25272	return c
25273}
25274
25275// Header returns an http.Header that can be modified by the caller to
25276// add HTTP headers to the request.
25277func (c *ProjectsAgentKnowledgeBasesDocumentsReloadCall) Header() http.Header {
25278	if c.header_ == nil {
25279		c.header_ = make(http.Header)
25280	}
25281	return c.header_
25282}
25283
25284func (c *ProjectsAgentKnowledgeBasesDocumentsReloadCall) doRequest(alt string) (*http.Response, error) {
25285	reqHeaders := make(http.Header)
25286	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
25287	for k, v := range c.header_ {
25288		reqHeaders[k] = v
25289	}
25290	reqHeaders.Set("User-Agent", c.s.userAgent())
25291	var body io.Reader = nil
25292	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2reloaddocumentrequest)
25293	if err != nil {
25294		return nil, err
25295	}
25296	reqHeaders.Set("Content-Type", "application/json")
25297	c.urlParams_.Set("alt", alt)
25298	c.urlParams_.Set("prettyPrint", "false")
25299	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:reload")
25300	urls += "?" + c.urlParams_.Encode()
25301	req, err := http.NewRequest("POST", urls, body)
25302	if err != nil {
25303		return nil, err
25304	}
25305	req.Header = reqHeaders
25306	googleapi.Expand(req.URL, map[string]string{
25307		"name": c.name,
25308	})
25309	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25310}
25311
25312// Do executes the "dialogflow.projects.agent.knowledgeBases.documents.reload" call.
25313// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
25314// Any non-2xx status code is an error. Response headers are in either
25315// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
25316// was returned at all) in error.(*googleapi.Error).Header. Use
25317// googleapi.IsNotModified to check whether the returned error was
25318// because http.StatusNotModified was returned.
25319func (c *ProjectsAgentKnowledgeBasesDocumentsReloadCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
25320	gensupport.SetOptions(c.urlParams_, opts...)
25321	res, err := c.doRequest("json")
25322	if res != nil && res.StatusCode == http.StatusNotModified {
25323		if res.Body != nil {
25324			res.Body.Close()
25325		}
25326		return nil, &googleapi.Error{
25327			Code:   res.StatusCode,
25328			Header: res.Header,
25329		}
25330	}
25331	if err != nil {
25332		return nil, err
25333	}
25334	defer googleapi.CloseBody(res)
25335	if err := googleapi.CheckResponse(res); err != nil {
25336		return nil, err
25337	}
25338	ret := &GoogleLongrunningOperation{
25339		ServerResponse: googleapi.ServerResponse{
25340			Header:         res.Header,
25341			HTTPStatusCode: res.StatusCode,
25342		},
25343	}
25344	target := &ret
25345	if err := gensupport.DecodeResponse(target, res); err != nil {
25346		return nil, err
25347	}
25348	return ret, nil
25349	// {
25350	//   "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. Note: The `projects.agent.knowledgeBases.documents` resource is deprecated; only use `projects.knowledgeBases.documents`. Operation ",
25351	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}:reload",
25352	//   "httpMethod": "POST",
25353	//   "id": "dialogflow.projects.agent.knowledgeBases.documents.reload",
25354	//   "parameterOrder": [
25355	//     "name"
25356	//   ],
25357	//   "parameters": {
25358	//     "name": {
25359	//       "description": "Required. The name of the document to reload. Format: `projects//locations//knowledgeBases//documents/`",
25360	//       "location": "path",
25361	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+/documents/[^/]+$",
25362	//       "required": true,
25363	//       "type": "string"
25364	//     }
25365	//   },
25366	//   "path": "v2/{+name}:reload",
25367	//   "request": {
25368	//     "$ref": "GoogleCloudDialogflowV2ReloadDocumentRequest"
25369	//   },
25370	//   "response": {
25371	//     "$ref": "GoogleLongrunningOperation"
25372	//   },
25373	//   "scopes": [
25374	//     "https://www.googleapis.com/auth/cloud-platform",
25375	//     "https://www.googleapis.com/auth/dialogflow"
25376	//   ]
25377	// }
25378
25379}
25380
25381// method id "dialogflow.projects.agent.sessions.deleteContexts":
25382
25383type ProjectsAgentSessionsDeleteContextsCall struct {
25384	s          *Service
25385	parent     string
25386	urlParams_ gensupport.URLParams
25387	ctx_       context.Context
25388	header_    http.Header
25389}
25390
25391// DeleteContexts: Deletes all active contexts in the specified session.
25392//
25393// - parent: The name of the session to delete all contexts from.
25394//   Format: `projects//agent/sessions/` or
25395//   `projects//agent/environments//users//sessions/`. If `Environment
25396//   ID` is not specified we assume default 'draft' environment. If
25397//   `User ID` is not specified, we assume default '-' user.
25398func (r *ProjectsAgentSessionsService) DeleteContexts(parent string) *ProjectsAgentSessionsDeleteContextsCall {
25399	c := &ProjectsAgentSessionsDeleteContextsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25400	c.parent = parent
25401	return c
25402}
25403
25404// Fields allows partial responses to be retrieved. See
25405// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25406// for more information.
25407func (c *ProjectsAgentSessionsDeleteContextsCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsDeleteContextsCall {
25408	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25409	return c
25410}
25411
25412// Context sets the context to be used in this call's Do method. Any
25413// pending HTTP request will be aborted if the provided context is
25414// canceled.
25415func (c *ProjectsAgentSessionsDeleteContextsCall) Context(ctx context.Context) *ProjectsAgentSessionsDeleteContextsCall {
25416	c.ctx_ = ctx
25417	return c
25418}
25419
25420// Header returns an http.Header that can be modified by the caller to
25421// add HTTP headers to the request.
25422func (c *ProjectsAgentSessionsDeleteContextsCall) Header() http.Header {
25423	if c.header_ == nil {
25424		c.header_ = make(http.Header)
25425	}
25426	return c.header_
25427}
25428
25429func (c *ProjectsAgentSessionsDeleteContextsCall) doRequest(alt string) (*http.Response, error) {
25430	reqHeaders := make(http.Header)
25431	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
25432	for k, v := range c.header_ {
25433		reqHeaders[k] = v
25434	}
25435	reqHeaders.Set("User-Agent", c.s.userAgent())
25436	var body io.Reader = nil
25437	c.urlParams_.Set("alt", alt)
25438	c.urlParams_.Set("prettyPrint", "false")
25439	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
25440	urls += "?" + c.urlParams_.Encode()
25441	req, err := http.NewRequest("DELETE", urls, body)
25442	if err != nil {
25443		return nil, err
25444	}
25445	req.Header = reqHeaders
25446	googleapi.Expand(req.URL, map[string]string{
25447		"parent": c.parent,
25448	})
25449	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25450}
25451
25452// Do executes the "dialogflow.projects.agent.sessions.deleteContexts" call.
25453// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
25454// non-2xx status code is an error. Response headers are in either
25455// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
25456// returned at all) in error.(*googleapi.Error).Header. Use
25457// googleapi.IsNotModified to check whether the returned error was
25458// because http.StatusNotModified was returned.
25459func (c *ProjectsAgentSessionsDeleteContextsCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
25460	gensupport.SetOptions(c.urlParams_, opts...)
25461	res, err := c.doRequest("json")
25462	if res != nil && res.StatusCode == http.StatusNotModified {
25463		if res.Body != nil {
25464			res.Body.Close()
25465		}
25466		return nil, &googleapi.Error{
25467			Code:   res.StatusCode,
25468			Header: res.Header,
25469		}
25470	}
25471	if err != nil {
25472		return nil, err
25473	}
25474	defer googleapi.CloseBody(res)
25475	if err := googleapi.CheckResponse(res); err != nil {
25476		return nil, err
25477	}
25478	ret := &GoogleProtobufEmpty{
25479		ServerResponse: googleapi.ServerResponse{
25480			Header:         res.Header,
25481			HTTPStatusCode: res.StatusCode,
25482		},
25483	}
25484	target := &ret
25485	if err := gensupport.DecodeResponse(target, res); err != nil {
25486		return nil, err
25487	}
25488	return ret, nil
25489	// {
25490	//   "description": "Deletes all active contexts in the specified session.",
25491	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/contexts",
25492	//   "httpMethod": "DELETE",
25493	//   "id": "dialogflow.projects.agent.sessions.deleteContexts",
25494	//   "parameterOrder": [
25495	//     "parent"
25496	//   ],
25497	//   "parameters": {
25498	//     "parent": {
25499	//       "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.",
25500	//       "location": "path",
25501	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+$",
25502	//       "required": true,
25503	//       "type": "string"
25504	//     }
25505	//   },
25506	//   "path": "v2/{+parent}/contexts",
25507	//   "response": {
25508	//     "$ref": "GoogleProtobufEmpty"
25509	//   },
25510	//   "scopes": [
25511	//     "https://www.googleapis.com/auth/cloud-platform",
25512	//     "https://www.googleapis.com/auth/dialogflow"
25513	//   ]
25514	// }
25515
25516}
25517
25518// method id "dialogflow.projects.agent.sessions.detectIntent":
25519
25520type ProjectsAgentSessionsDetectIntentCall struct {
25521	s                                          *Service
25522	sessionid                                  string
25523	googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest
25524	urlParams_                                 gensupport.URLParams
25525	ctx_                                       context.Context
25526	header_                                    http.Header
25527}
25528
25529// DetectIntent: Processes a natural language query and returns
25530// structured, actionable data as a result. This method is not
25531// idempotent, because it may cause contexts and session entity types to
25532// be updated, which in turn might affect results of future queries.
25533// Note: Always use agent versions for production traffic. See Versions
25534// and environments
25535// (https://cloud.google.com/dialogflow/es/docs/agents-versions).
25536//
25537// - session: The name of the session this query is sent to. Format:
25538//   `projects//agent/sessions/`, or
25539//   `projects//agent/environments//users//sessions/`. If `Environment
25540//   ID` is not specified, we assume default 'draft' environment
25541//   (`Environment ID` might be referred to as environment name at some
25542//   places). If `User ID` is not specified, we are using "-". It's up
25543//   to the API caller to choose an appropriate `Session ID` and `User
25544//   Id`. They can be a random number or some type of user and session
25545//   identifiers (preferably hashed). The length of the `Session ID` and
25546//   `User ID` must not exceed 36 characters. For more information, see
25547//   the API interactions guide
25548//   (https://cloud.google.com/dialogflow/docs/api-overview). Note:
25549//   Always use agent versions for production traffic. See Versions and
25550//   environments
25551//   (https://cloud.google.com/dialogflow/es/docs/agents-versions).
25552func (r *ProjectsAgentSessionsService) DetectIntent(sessionid string, googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest) *ProjectsAgentSessionsDetectIntentCall {
25553	c := &ProjectsAgentSessionsDetectIntentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25554	c.sessionid = sessionid
25555	c.googleclouddialogflowv2detectintentrequest = googleclouddialogflowv2detectintentrequest
25556	return c
25557}
25558
25559// Fields allows partial responses to be retrieved. See
25560// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25561// for more information.
25562func (c *ProjectsAgentSessionsDetectIntentCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsDetectIntentCall {
25563	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25564	return c
25565}
25566
25567// Context sets the context to be used in this call's Do method. Any
25568// pending HTTP request will be aborted if the provided context is
25569// canceled.
25570func (c *ProjectsAgentSessionsDetectIntentCall) Context(ctx context.Context) *ProjectsAgentSessionsDetectIntentCall {
25571	c.ctx_ = ctx
25572	return c
25573}
25574
25575// Header returns an http.Header that can be modified by the caller to
25576// add HTTP headers to the request.
25577func (c *ProjectsAgentSessionsDetectIntentCall) Header() http.Header {
25578	if c.header_ == nil {
25579		c.header_ = make(http.Header)
25580	}
25581	return c.header_
25582}
25583
25584func (c *ProjectsAgentSessionsDetectIntentCall) doRequest(alt string) (*http.Response, error) {
25585	reqHeaders := make(http.Header)
25586	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
25587	for k, v := range c.header_ {
25588		reqHeaders[k] = v
25589	}
25590	reqHeaders.Set("User-Agent", c.s.userAgent())
25591	var body io.Reader = nil
25592	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2detectintentrequest)
25593	if err != nil {
25594		return nil, err
25595	}
25596	reqHeaders.Set("Content-Type", "application/json")
25597	c.urlParams_.Set("alt", alt)
25598	c.urlParams_.Set("prettyPrint", "false")
25599	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+session}:detectIntent")
25600	urls += "?" + c.urlParams_.Encode()
25601	req, err := http.NewRequest("POST", urls, body)
25602	if err != nil {
25603		return nil, err
25604	}
25605	req.Header = reqHeaders
25606	googleapi.Expand(req.URL, map[string]string{
25607		"session": c.sessionid,
25608	})
25609	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25610}
25611
25612// Do executes the "dialogflow.projects.agent.sessions.detectIntent" call.
25613// Exactly one of *GoogleCloudDialogflowV2DetectIntentResponse or error
25614// will be non-nil. Any non-2xx status code is an error. Response
25615// headers are in either
25616// *GoogleCloudDialogflowV2DetectIntentResponse.ServerResponse.Header or
25617// (if a response was returned at all) in
25618// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
25619// whether the returned error was because http.StatusNotModified was
25620// returned.
25621func (c *ProjectsAgentSessionsDetectIntentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2DetectIntentResponse, error) {
25622	gensupport.SetOptions(c.urlParams_, opts...)
25623	res, err := c.doRequest("json")
25624	if res != nil && res.StatusCode == http.StatusNotModified {
25625		if res.Body != nil {
25626			res.Body.Close()
25627		}
25628		return nil, &googleapi.Error{
25629			Code:   res.StatusCode,
25630			Header: res.Header,
25631		}
25632	}
25633	if err != nil {
25634		return nil, err
25635	}
25636	defer googleapi.CloseBody(res)
25637	if err := googleapi.CheckResponse(res); err != nil {
25638		return nil, err
25639	}
25640	ret := &GoogleCloudDialogflowV2DetectIntentResponse{
25641		ServerResponse: googleapi.ServerResponse{
25642			Header:         res.Header,
25643			HTTPStatusCode: res.StatusCode,
25644		},
25645	}
25646	target := &ret
25647	if err := gensupport.DecodeResponse(target, res); err != nil {
25648		return nil, err
25649	}
25650	return ret, nil
25651	// {
25652	//   "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. Note: Always use agent versions for production traffic. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
25653	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}:detectIntent",
25654	//   "httpMethod": "POST",
25655	//   "id": "dialogflow.projects.agent.sessions.detectIntent",
25656	//   "parameterOrder": [
25657	//     "session"
25658	//   ],
25659	//   "parameters": {
25660	//     "session": {
25661	//       "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).",
25662	//       "location": "path",
25663	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+$",
25664	//       "required": true,
25665	//       "type": "string"
25666	//     }
25667	//   },
25668	//   "path": "v2/{+session}:detectIntent",
25669	//   "request": {
25670	//     "$ref": "GoogleCloudDialogflowV2DetectIntentRequest"
25671	//   },
25672	//   "response": {
25673	//     "$ref": "GoogleCloudDialogflowV2DetectIntentResponse"
25674	//   },
25675	//   "scopes": [
25676	//     "https://www.googleapis.com/auth/cloud-platform",
25677	//     "https://www.googleapis.com/auth/dialogflow"
25678	//   ]
25679	// }
25680
25681}
25682
25683// method id "dialogflow.projects.agent.sessions.contexts.create":
25684
25685type ProjectsAgentSessionsContextsCreateCall struct {
25686	s                              *Service
25687	parent                         string
25688	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
25689	urlParams_                     gensupport.URLParams
25690	ctx_                           context.Context
25691	header_                        http.Header
25692}
25693
25694// Create: Creates a context. If the specified context already exists,
25695// overrides the context.
25696//
25697// - parent: The session to create a context for. Format:
25698//   `projects//agent/sessions/` or
25699//   `projects//agent/environments//users//sessions/`. If `Environment
25700//   ID` is not specified, we assume default 'draft' environment. If
25701//   `User ID` is not specified, we assume default '-' user.
25702func (r *ProjectsAgentSessionsContextsService) Create(parent string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsAgentSessionsContextsCreateCall {
25703	c := &ProjectsAgentSessionsContextsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25704	c.parent = parent
25705	c.googleclouddialogflowv2context = googleclouddialogflowv2context
25706	return c
25707}
25708
25709// Fields allows partial responses to be retrieved. See
25710// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25711// for more information.
25712func (c *ProjectsAgentSessionsContextsCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsContextsCreateCall {
25713	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25714	return c
25715}
25716
25717// Context sets the context to be used in this call's Do method. Any
25718// pending HTTP request will be aborted if the provided context is
25719// canceled.
25720func (c *ProjectsAgentSessionsContextsCreateCall) Context(ctx context.Context) *ProjectsAgentSessionsContextsCreateCall {
25721	c.ctx_ = ctx
25722	return c
25723}
25724
25725// Header returns an http.Header that can be modified by the caller to
25726// add HTTP headers to the request.
25727func (c *ProjectsAgentSessionsContextsCreateCall) Header() http.Header {
25728	if c.header_ == nil {
25729		c.header_ = make(http.Header)
25730	}
25731	return c.header_
25732}
25733
25734func (c *ProjectsAgentSessionsContextsCreateCall) doRequest(alt string) (*http.Response, error) {
25735	reqHeaders := make(http.Header)
25736	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
25737	for k, v := range c.header_ {
25738		reqHeaders[k] = v
25739	}
25740	reqHeaders.Set("User-Agent", c.s.userAgent())
25741	var body io.Reader = nil
25742	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
25743	if err != nil {
25744		return nil, err
25745	}
25746	reqHeaders.Set("Content-Type", "application/json")
25747	c.urlParams_.Set("alt", alt)
25748	c.urlParams_.Set("prettyPrint", "false")
25749	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
25750	urls += "?" + c.urlParams_.Encode()
25751	req, err := http.NewRequest("POST", urls, body)
25752	if err != nil {
25753		return nil, err
25754	}
25755	req.Header = reqHeaders
25756	googleapi.Expand(req.URL, map[string]string{
25757		"parent": c.parent,
25758	})
25759	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25760}
25761
25762// Do executes the "dialogflow.projects.agent.sessions.contexts.create" call.
25763// Exactly one of *GoogleCloudDialogflowV2Context or error will be
25764// non-nil. Any non-2xx status code is an error. Response headers are in
25765// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
25766// response was returned at all) in error.(*googleapi.Error).Header. Use
25767// googleapi.IsNotModified to check whether the returned error was
25768// because http.StatusNotModified was returned.
25769func (c *ProjectsAgentSessionsContextsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
25770	gensupport.SetOptions(c.urlParams_, opts...)
25771	res, err := c.doRequest("json")
25772	if res != nil && res.StatusCode == http.StatusNotModified {
25773		if res.Body != nil {
25774			res.Body.Close()
25775		}
25776		return nil, &googleapi.Error{
25777			Code:   res.StatusCode,
25778			Header: res.Header,
25779		}
25780	}
25781	if err != nil {
25782		return nil, err
25783	}
25784	defer googleapi.CloseBody(res)
25785	if err := googleapi.CheckResponse(res); err != nil {
25786		return nil, err
25787	}
25788	ret := &GoogleCloudDialogflowV2Context{
25789		ServerResponse: googleapi.ServerResponse{
25790			Header:         res.Header,
25791			HTTPStatusCode: res.StatusCode,
25792		},
25793	}
25794	target := &ret
25795	if err := gensupport.DecodeResponse(target, res); err != nil {
25796		return nil, err
25797	}
25798	return ret, nil
25799	// {
25800	//   "description": "Creates a context. If the specified context already exists, overrides the context.",
25801	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/contexts",
25802	//   "httpMethod": "POST",
25803	//   "id": "dialogflow.projects.agent.sessions.contexts.create",
25804	//   "parameterOrder": [
25805	//     "parent"
25806	//   ],
25807	//   "parameters": {
25808	//     "parent": {
25809	//       "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.",
25810	//       "location": "path",
25811	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+$",
25812	//       "required": true,
25813	//       "type": "string"
25814	//     }
25815	//   },
25816	//   "path": "v2/{+parent}/contexts",
25817	//   "request": {
25818	//     "$ref": "GoogleCloudDialogflowV2Context"
25819	//   },
25820	//   "response": {
25821	//     "$ref": "GoogleCloudDialogflowV2Context"
25822	//   },
25823	//   "scopes": [
25824	//     "https://www.googleapis.com/auth/cloud-platform",
25825	//     "https://www.googleapis.com/auth/dialogflow"
25826	//   ]
25827	// }
25828
25829}
25830
25831// method id "dialogflow.projects.agent.sessions.contexts.delete":
25832
25833type ProjectsAgentSessionsContextsDeleteCall struct {
25834	s          *Service
25835	name       string
25836	urlParams_ gensupport.URLParams
25837	ctx_       context.Context
25838	header_    http.Header
25839}
25840
25841// Delete: Deletes the specified context.
25842//
25843// - name: The name of the context to delete. Format:
25844//   `projects//agent/sessions//contexts/` or
25845//   `projects//agent/environments//users//sessions//contexts/`. If
25846//   `Environment ID` is not specified, we assume default 'draft'
25847//   environment. If `User ID` is not specified, we assume default '-'
25848//   user.
25849func (r *ProjectsAgentSessionsContextsService) Delete(name string) *ProjectsAgentSessionsContextsDeleteCall {
25850	c := &ProjectsAgentSessionsContextsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25851	c.name = name
25852	return c
25853}
25854
25855// Fields allows partial responses to be retrieved. See
25856// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25857// for more information.
25858func (c *ProjectsAgentSessionsContextsDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsContextsDeleteCall {
25859	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25860	return c
25861}
25862
25863// Context sets the context to be used in this call's Do method. Any
25864// pending HTTP request will be aborted if the provided context is
25865// canceled.
25866func (c *ProjectsAgentSessionsContextsDeleteCall) Context(ctx context.Context) *ProjectsAgentSessionsContextsDeleteCall {
25867	c.ctx_ = ctx
25868	return c
25869}
25870
25871// Header returns an http.Header that can be modified by the caller to
25872// add HTTP headers to the request.
25873func (c *ProjectsAgentSessionsContextsDeleteCall) Header() http.Header {
25874	if c.header_ == nil {
25875		c.header_ = make(http.Header)
25876	}
25877	return c.header_
25878}
25879
25880func (c *ProjectsAgentSessionsContextsDeleteCall) doRequest(alt string) (*http.Response, error) {
25881	reqHeaders := make(http.Header)
25882	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
25883	for k, v := range c.header_ {
25884		reqHeaders[k] = v
25885	}
25886	reqHeaders.Set("User-Agent", c.s.userAgent())
25887	var body io.Reader = nil
25888	c.urlParams_.Set("alt", alt)
25889	c.urlParams_.Set("prettyPrint", "false")
25890	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
25891	urls += "?" + c.urlParams_.Encode()
25892	req, err := http.NewRequest("DELETE", urls, body)
25893	if err != nil {
25894		return nil, err
25895	}
25896	req.Header = reqHeaders
25897	googleapi.Expand(req.URL, map[string]string{
25898		"name": c.name,
25899	})
25900	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25901}
25902
25903// Do executes the "dialogflow.projects.agent.sessions.contexts.delete" call.
25904// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
25905// non-2xx status code is an error. Response headers are in either
25906// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
25907// returned at all) in error.(*googleapi.Error).Header. Use
25908// googleapi.IsNotModified to check whether the returned error was
25909// because http.StatusNotModified was returned.
25910func (c *ProjectsAgentSessionsContextsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
25911	gensupport.SetOptions(c.urlParams_, opts...)
25912	res, err := c.doRequest("json")
25913	if res != nil && res.StatusCode == http.StatusNotModified {
25914		if res.Body != nil {
25915			res.Body.Close()
25916		}
25917		return nil, &googleapi.Error{
25918			Code:   res.StatusCode,
25919			Header: res.Header,
25920		}
25921	}
25922	if err != nil {
25923		return nil, err
25924	}
25925	defer googleapi.CloseBody(res)
25926	if err := googleapi.CheckResponse(res); err != nil {
25927		return nil, err
25928	}
25929	ret := &GoogleProtobufEmpty{
25930		ServerResponse: googleapi.ServerResponse{
25931			Header:         res.Header,
25932			HTTPStatusCode: res.StatusCode,
25933		},
25934	}
25935	target := &ret
25936	if err := gensupport.DecodeResponse(target, res); err != nil {
25937		return nil, err
25938	}
25939	return ret, nil
25940	// {
25941	//   "description": "Deletes the specified context.",
25942	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/contexts/{contextsId}",
25943	//   "httpMethod": "DELETE",
25944	//   "id": "dialogflow.projects.agent.sessions.contexts.delete",
25945	//   "parameterOrder": [
25946	//     "name"
25947	//   ],
25948	//   "parameters": {
25949	//     "name": {
25950	//       "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.",
25951	//       "location": "path",
25952	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+/contexts/[^/]+$",
25953	//       "required": true,
25954	//       "type": "string"
25955	//     }
25956	//   },
25957	//   "path": "v2/{+name}",
25958	//   "response": {
25959	//     "$ref": "GoogleProtobufEmpty"
25960	//   },
25961	//   "scopes": [
25962	//     "https://www.googleapis.com/auth/cloud-platform",
25963	//     "https://www.googleapis.com/auth/dialogflow"
25964	//   ]
25965	// }
25966
25967}
25968
25969// method id "dialogflow.projects.agent.sessions.contexts.get":
25970
25971type ProjectsAgentSessionsContextsGetCall struct {
25972	s            *Service
25973	name         string
25974	urlParams_   gensupport.URLParams
25975	ifNoneMatch_ string
25976	ctx_         context.Context
25977	header_      http.Header
25978}
25979
25980// Get: Retrieves the specified context.
25981//
25982// - name: The name of the context. Format:
25983//   `projects//agent/sessions//contexts/` or
25984//   `projects//agent/environments//users//sessions//contexts/`. If
25985//   `Environment ID` is not specified, we assume default 'draft'
25986//   environment. If `User ID` is not specified, we assume default '-'
25987//   user.
25988func (r *ProjectsAgentSessionsContextsService) Get(name string) *ProjectsAgentSessionsContextsGetCall {
25989	c := &ProjectsAgentSessionsContextsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25990	c.name = name
25991	return c
25992}
25993
25994// Fields allows partial responses to be retrieved. See
25995// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25996// for more information.
25997func (c *ProjectsAgentSessionsContextsGetCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsContextsGetCall {
25998	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25999	return c
26000}
26001
26002// IfNoneMatch sets the optional parameter which makes the operation
26003// fail if the object's ETag matches the given value. This is useful for
26004// getting updates only after the object has changed since the last
26005// request. Use googleapi.IsNotModified to check whether the response
26006// error from Do is the result of In-None-Match.
26007func (c *ProjectsAgentSessionsContextsGetCall) IfNoneMatch(entityTag string) *ProjectsAgentSessionsContextsGetCall {
26008	c.ifNoneMatch_ = entityTag
26009	return c
26010}
26011
26012// Context sets the context to be used in this call's Do method. Any
26013// pending HTTP request will be aborted if the provided context is
26014// canceled.
26015func (c *ProjectsAgentSessionsContextsGetCall) Context(ctx context.Context) *ProjectsAgentSessionsContextsGetCall {
26016	c.ctx_ = ctx
26017	return c
26018}
26019
26020// Header returns an http.Header that can be modified by the caller to
26021// add HTTP headers to the request.
26022func (c *ProjectsAgentSessionsContextsGetCall) Header() http.Header {
26023	if c.header_ == nil {
26024		c.header_ = make(http.Header)
26025	}
26026	return c.header_
26027}
26028
26029func (c *ProjectsAgentSessionsContextsGetCall) doRequest(alt string) (*http.Response, error) {
26030	reqHeaders := make(http.Header)
26031	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
26032	for k, v := range c.header_ {
26033		reqHeaders[k] = v
26034	}
26035	reqHeaders.Set("User-Agent", c.s.userAgent())
26036	if c.ifNoneMatch_ != "" {
26037		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26038	}
26039	var body io.Reader = nil
26040	c.urlParams_.Set("alt", alt)
26041	c.urlParams_.Set("prettyPrint", "false")
26042	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
26043	urls += "?" + c.urlParams_.Encode()
26044	req, err := http.NewRequest("GET", urls, body)
26045	if err != nil {
26046		return nil, err
26047	}
26048	req.Header = reqHeaders
26049	googleapi.Expand(req.URL, map[string]string{
26050		"name": c.name,
26051	})
26052	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26053}
26054
26055// Do executes the "dialogflow.projects.agent.sessions.contexts.get" call.
26056// Exactly one of *GoogleCloudDialogflowV2Context or error will be
26057// non-nil. Any non-2xx status code is an error. Response headers are in
26058// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
26059// response was returned at all) in error.(*googleapi.Error).Header. Use
26060// googleapi.IsNotModified to check whether the returned error was
26061// because http.StatusNotModified was returned.
26062func (c *ProjectsAgentSessionsContextsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
26063	gensupport.SetOptions(c.urlParams_, opts...)
26064	res, err := c.doRequest("json")
26065	if res != nil && res.StatusCode == http.StatusNotModified {
26066		if res.Body != nil {
26067			res.Body.Close()
26068		}
26069		return nil, &googleapi.Error{
26070			Code:   res.StatusCode,
26071			Header: res.Header,
26072		}
26073	}
26074	if err != nil {
26075		return nil, err
26076	}
26077	defer googleapi.CloseBody(res)
26078	if err := googleapi.CheckResponse(res); err != nil {
26079		return nil, err
26080	}
26081	ret := &GoogleCloudDialogflowV2Context{
26082		ServerResponse: googleapi.ServerResponse{
26083			Header:         res.Header,
26084			HTTPStatusCode: res.StatusCode,
26085		},
26086	}
26087	target := &ret
26088	if err := gensupport.DecodeResponse(target, res); err != nil {
26089		return nil, err
26090	}
26091	return ret, nil
26092	// {
26093	//   "description": "Retrieves the specified context.",
26094	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/contexts/{contextsId}",
26095	//   "httpMethod": "GET",
26096	//   "id": "dialogflow.projects.agent.sessions.contexts.get",
26097	//   "parameterOrder": [
26098	//     "name"
26099	//   ],
26100	//   "parameters": {
26101	//     "name": {
26102	//       "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.",
26103	//       "location": "path",
26104	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+/contexts/[^/]+$",
26105	//       "required": true,
26106	//       "type": "string"
26107	//     }
26108	//   },
26109	//   "path": "v2/{+name}",
26110	//   "response": {
26111	//     "$ref": "GoogleCloudDialogflowV2Context"
26112	//   },
26113	//   "scopes": [
26114	//     "https://www.googleapis.com/auth/cloud-platform",
26115	//     "https://www.googleapis.com/auth/dialogflow"
26116	//   ]
26117	// }
26118
26119}
26120
26121// method id "dialogflow.projects.agent.sessions.contexts.list":
26122
26123type ProjectsAgentSessionsContextsListCall struct {
26124	s            *Service
26125	parent       string
26126	urlParams_   gensupport.URLParams
26127	ifNoneMatch_ string
26128	ctx_         context.Context
26129	header_      http.Header
26130}
26131
26132// List: Returns the list of all contexts in the specified session.
26133//
26134// - parent: The session to list all contexts from. Format:
26135//   `projects//agent/sessions/` or
26136//   `projects//agent/environments//users//sessions/`. If `Environment
26137//   ID` is not specified, we assume default 'draft' environment. If
26138//   `User ID` is not specified, we assume default '-' user.
26139func (r *ProjectsAgentSessionsContextsService) List(parent string) *ProjectsAgentSessionsContextsListCall {
26140	c := &ProjectsAgentSessionsContextsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26141	c.parent = parent
26142	return c
26143}
26144
26145// PageSize sets the optional parameter "pageSize": The maximum number
26146// of items to return in a single page. By default 100 and at most 1000.
26147func (c *ProjectsAgentSessionsContextsListCall) PageSize(pageSize int64) *ProjectsAgentSessionsContextsListCall {
26148	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
26149	return c
26150}
26151
26152// PageToken sets the optional parameter "pageToken": The
26153// next_page_token value returned from a previous list request.
26154func (c *ProjectsAgentSessionsContextsListCall) PageToken(pageToken string) *ProjectsAgentSessionsContextsListCall {
26155	c.urlParams_.Set("pageToken", pageToken)
26156	return c
26157}
26158
26159// Fields allows partial responses to be retrieved. See
26160// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26161// for more information.
26162func (c *ProjectsAgentSessionsContextsListCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsContextsListCall {
26163	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26164	return c
26165}
26166
26167// IfNoneMatch sets the optional parameter which makes the operation
26168// fail if the object's ETag matches the given value. This is useful for
26169// getting updates only after the object has changed since the last
26170// request. Use googleapi.IsNotModified to check whether the response
26171// error from Do is the result of In-None-Match.
26172func (c *ProjectsAgentSessionsContextsListCall) IfNoneMatch(entityTag string) *ProjectsAgentSessionsContextsListCall {
26173	c.ifNoneMatch_ = entityTag
26174	return c
26175}
26176
26177// Context sets the context to be used in this call's Do method. Any
26178// pending HTTP request will be aborted if the provided context is
26179// canceled.
26180func (c *ProjectsAgentSessionsContextsListCall) Context(ctx context.Context) *ProjectsAgentSessionsContextsListCall {
26181	c.ctx_ = ctx
26182	return c
26183}
26184
26185// Header returns an http.Header that can be modified by the caller to
26186// add HTTP headers to the request.
26187func (c *ProjectsAgentSessionsContextsListCall) Header() http.Header {
26188	if c.header_ == nil {
26189		c.header_ = make(http.Header)
26190	}
26191	return c.header_
26192}
26193
26194func (c *ProjectsAgentSessionsContextsListCall) doRequest(alt string) (*http.Response, error) {
26195	reqHeaders := make(http.Header)
26196	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
26197	for k, v := range c.header_ {
26198		reqHeaders[k] = v
26199	}
26200	reqHeaders.Set("User-Agent", c.s.userAgent())
26201	if c.ifNoneMatch_ != "" {
26202		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26203	}
26204	var body io.Reader = nil
26205	c.urlParams_.Set("alt", alt)
26206	c.urlParams_.Set("prettyPrint", "false")
26207	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
26208	urls += "?" + c.urlParams_.Encode()
26209	req, err := http.NewRequest("GET", urls, body)
26210	if err != nil {
26211		return nil, err
26212	}
26213	req.Header = reqHeaders
26214	googleapi.Expand(req.URL, map[string]string{
26215		"parent": c.parent,
26216	})
26217	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26218}
26219
26220// Do executes the "dialogflow.projects.agent.sessions.contexts.list" call.
26221// Exactly one of *GoogleCloudDialogflowV2ListContextsResponse or error
26222// will be non-nil. Any non-2xx status code is an error. Response
26223// headers are in either
26224// *GoogleCloudDialogflowV2ListContextsResponse.ServerResponse.Header or
26225// (if a response was returned at all) in
26226// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
26227// whether the returned error was because http.StatusNotModified was
26228// returned.
26229func (c *ProjectsAgentSessionsContextsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListContextsResponse, error) {
26230	gensupport.SetOptions(c.urlParams_, opts...)
26231	res, err := c.doRequest("json")
26232	if res != nil && res.StatusCode == http.StatusNotModified {
26233		if res.Body != nil {
26234			res.Body.Close()
26235		}
26236		return nil, &googleapi.Error{
26237			Code:   res.StatusCode,
26238			Header: res.Header,
26239		}
26240	}
26241	if err != nil {
26242		return nil, err
26243	}
26244	defer googleapi.CloseBody(res)
26245	if err := googleapi.CheckResponse(res); err != nil {
26246		return nil, err
26247	}
26248	ret := &GoogleCloudDialogflowV2ListContextsResponse{
26249		ServerResponse: googleapi.ServerResponse{
26250			Header:         res.Header,
26251			HTTPStatusCode: res.StatusCode,
26252		},
26253	}
26254	target := &ret
26255	if err := gensupport.DecodeResponse(target, res); err != nil {
26256		return nil, err
26257	}
26258	return ret, nil
26259	// {
26260	//   "description": "Returns the list of all contexts in the specified session.",
26261	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/contexts",
26262	//   "httpMethod": "GET",
26263	//   "id": "dialogflow.projects.agent.sessions.contexts.list",
26264	//   "parameterOrder": [
26265	//     "parent"
26266	//   ],
26267	//   "parameters": {
26268	//     "pageSize": {
26269	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
26270	//       "format": "int32",
26271	//       "location": "query",
26272	//       "type": "integer"
26273	//     },
26274	//     "pageToken": {
26275	//       "description": "Optional. The next_page_token value returned from a previous list request.",
26276	//       "location": "query",
26277	//       "type": "string"
26278	//     },
26279	//     "parent": {
26280	//       "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.",
26281	//       "location": "path",
26282	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+$",
26283	//       "required": true,
26284	//       "type": "string"
26285	//     }
26286	//   },
26287	//   "path": "v2/{+parent}/contexts",
26288	//   "response": {
26289	//     "$ref": "GoogleCloudDialogflowV2ListContextsResponse"
26290	//   },
26291	//   "scopes": [
26292	//     "https://www.googleapis.com/auth/cloud-platform",
26293	//     "https://www.googleapis.com/auth/dialogflow"
26294	//   ]
26295	// }
26296
26297}
26298
26299// Pages invokes f for each page of results.
26300// A non-nil error returned from f will halt the iteration.
26301// The provided context supersedes any context provided to the Context method.
26302func (c *ProjectsAgentSessionsContextsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListContextsResponse) error) error {
26303	c.ctx_ = ctx
26304	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
26305	for {
26306		x, err := c.Do()
26307		if err != nil {
26308			return err
26309		}
26310		if err := f(x); err != nil {
26311			return err
26312		}
26313		if x.NextPageToken == "" {
26314			return nil
26315		}
26316		c.PageToken(x.NextPageToken)
26317	}
26318}
26319
26320// method id "dialogflow.projects.agent.sessions.contexts.patch":
26321
26322type ProjectsAgentSessionsContextsPatchCall struct {
26323	s                              *Service
26324	nameid                         string
26325	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
26326	urlParams_                     gensupport.URLParams
26327	ctx_                           context.Context
26328	header_                        http.Header
26329}
26330
26331// Patch: Updates the specified context.
26332//
26333// - name: The unique identifier of the context. Format:
26334//   `projects//agent/sessions//contexts/`, or
26335//   `projects//agent/environments//users//sessions//contexts/`. The
26336//   `Context ID` is always converted to lowercase, may only contain
26337//   characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If
26338//   `Environment ID` is not specified, we assume default 'draft'
26339//   environment. If `User ID` is not specified, we assume default '-'
26340//   user. The following context names are reserved for internal use by
26341//   Dialogflow. You should not use these contexts or create contexts
26342//   with these names: * `__system_counters__` * `*_id_dialog_context` *
26343//   `*_dialog_params_size`.
26344func (r *ProjectsAgentSessionsContextsService) Patch(nameid string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsAgentSessionsContextsPatchCall {
26345	c := &ProjectsAgentSessionsContextsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26346	c.nameid = nameid
26347	c.googleclouddialogflowv2context = googleclouddialogflowv2context
26348	return c
26349}
26350
26351// UpdateMask sets the optional parameter "updateMask": The mask to
26352// control which fields get updated.
26353func (c *ProjectsAgentSessionsContextsPatchCall) UpdateMask(updateMask string) *ProjectsAgentSessionsContextsPatchCall {
26354	c.urlParams_.Set("updateMask", updateMask)
26355	return c
26356}
26357
26358// Fields allows partial responses to be retrieved. See
26359// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26360// for more information.
26361func (c *ProjectsAgentSessionsContextsPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsContextsPatchCall {
26362	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26363	return c
26364}
26365
26366// Context sets the context to be used in this call's Do method. Any
26367// pending HTTP request will be aborted if the provided context is
26368// canceled.
26369func (c *ProjectsAgentSessionsContextsPatchCall) Context(ctx context.Context) *ProjectsAgentSessionsContextsPatchCall {
26370	c.ctx_ = ctx
26371	return c
26372}
26373
26374// Header returns an http.Header that can be modified by the caller to
26375// add HTTP headers to the request.
26376func (c *ProjectsAgentSessionsContextsPatchCall) Header() http.Header {
26377	if c.header_ == nil {
26378		c.header_ = make(http.Header)
26379	}
26380	return c.header_
26381}
26382
26383func (c *ProjectsAgentSessionsContextsPatchCall) doRequest(alt string) (*http.Response, error) {
26384	reqHeaders := make(http.Header)
26385	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
26386	for k, v := range c.header_ {
26387		reqHeaders[k] = v
26388	}
26389	reqHeaders.Set("User-Agent", c.s.userAgent())
26390	var body io.Reader = nil
26391	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
26392	if err != nil {
26393		return nil, err
26394	}
26395	reqHeaders.Set("Content-Type", "application/json")
26396	c.urlParams_.Set("alt", alt)
26397	c.urlParams_.Set("prettyPrint", "false")
26398	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
26399	urls += "?" + c.urlParams_.Encode()
26400	req, err := http.NewRequest("PATCH", urls, body)
26401	if err != nil {
26402		return nil, err
26403	}
26404	req.Header = reqHeaders
26405	googleapi.Expand(req.URL, map[string]string{
26406		"name": c.nameid,
26407	})
26408	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26409}
26410
26411// Do executes the "dialogflow.projects.agent.sessions.contexts.patch" call.
26412// Exactly one of *GoogleCloudDialogflowV2Context or error will be
26413// non-nil. Any non-2xx status code is an error. Response headers are in
26414// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
26415// response was returned at all) in error.(*googleapi.Error).Header. Use
26416// googleapi.IsNotModified to check whether the returned error was
26417// because http.StatusNotModified was returned.
26418func (c *ProjectsAgentSessionsContextsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
26419	gensupport.SetOptions(c.urlParams_, opts...)
26420	res, err := c.doRequest("json")
26421	if res != nil && res.StatusCode == http.StatusNotModified {
26422		if res.Body != nil {
26423			res.Body.Close()
26424		}
26425		return nil, &googleapi.Error{
26426			Code:   res.StatusCode,
26427			Header: res.Header,
26428		}
26429	}
26430	if err != nil {
26431		return nil, err
26432	}
26433	defer googleapi.CloseBody(res)
26434	if err := googleapi.CheckResponse(res); err != nil {
26435		return nil, err
26436	}
26437	ret := &GoogleCloudDialogflowV2Context{
26438		ServerResponse: googleapi.ServerResponse{
26439			Header:         res.Header,
26440			HTTPStatusCode: res.StatusCode,
26441		},
26442	}
26443	target := &ret
26444	if err := gensupport.DecodeResponse(target, res); err != nil {
26445		return nil, err
26446	}
26447	return ret, nil
26448	// {
26449	//   "description": "Updates the specified context.",
26450	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/contexts/{contextsId}",
26451	//   "httpMethod": "PATCH",
26452	//   "id": "dialogflow.projects.agent.sessions.contexts.patch",
26453	//   "parameterOrder": [
26454	//     "name"
26455	//   ],
26456	//   "parameters": {
26457	//     "name": {
26458	//       "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`",
26459	//       "location": "path",
26460	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+/contexts/[^/]+$",
26461	//       "required": true,
26462	//       "type": "string"
26463	//     },
26464	//     "updateMask": {
26465	//       "description": "Optional. The mask to control which fields get updated.",
26466	//       "format": "google-fieldmask",
26467	//       "location": "query",
26468	//       "type": "string"
26469	//     }
26470	//   },
26471	//   "path": "v2/{+name}",
26472	//   "request": {
26473	//     "$ref": "GoogleCloudDialogflowV2Context"
26474	//   },
26475	//   "response": {
26476	//     "$ref": "GoogleCloudDialogflowV2Context"
26477	//   },
26478	//   "scopes": [
26479	//     "https://www.googleapis.com/auth/cloud-platform",
26480	//     "https://www.googleapis.com/auth/dialogflow"
26481	//   ]
26482	// }
26483
26484}
26485
26486// method id "dialogflow.projects.agent.sessions.entityTypes.create":
26487
26488type ProjectsAgentSessionsEntityTypesCreateCall struct {
26489	s                                        *Service
26490	parent                                   string
26491	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
26492	urlParams_                               gensupport.URLParams
26493	ctx_                                     context.Context
26494	header_                                  http.Header
26495}
26496
26497// Create: Creates a session entity type. If the specified session
26498// entity type already exists, overrides the session entity type. This
26499// method doesn't work with Google Assistant integration. Contact
26500// Dialogflow support if you need to use session entities with Google
26501// Assistant integration.
26502//
26503// - parent: The session to create a session entity type for. Format:
26504//   `projects//agent/sessions/` or
26505//   `projects//agent/environments//users// sessions/`. If `Environment
26506//   ID` is not specified, we assume default 'draft' environment. If
26507//   `User ID` is not specified, we assume default '-' user.
26508func (r *ProjectsAgentSessionsEntityTypesService) Create(parent string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsAgentSessionsEntityTypesCreateCall {
26509	c := &ProjectsAgentSessionsEntityTypesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26510	c.parent = parent
26511	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
26512	return c
26513}
26514
26515// Fields allows partial responses to be retrieved. See
26516// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26517// for more information.
26518func (c *ProjectsAgentSessionsEntityTypesCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsEntityTypesCreateCall {
26519	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26520	return c
26521}
26522
26523// Context sets the context to be used in this call's Do method. Any
26524// pending HTTP request will be aborted if the provided context is
26525// canceled.
26526func (c *ProjectsAgentSessionsEntityTypesCreateCall) Context(ctx context.Context) *ProjectsAgentSessionsEntityTypesCreateCall {
26527	c.ctx_ = ctx
26528	return c
26529}
26530
26531// Header returns an http.Header that can be modified by the caller to
26532// add HTTP headers to the request.
26533func (c *ProjectsAgentSessionsEntityTypesCreateCall) Header() http.Header {
26534	if c.header_ == nil {
26535		c.header_ = make(http.Header)
26536	}
26537	return c.header_
26538}
26539
26540func (c *ProjectsAgentSessionsEntityTypesCreateCall) doRequest(alt string) (*http.Response, error) {
26541	reqHeaders := make(http.Header)
26542	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
26543	for k, v := range c.header_ {
26544		reqHeaders[k] = v
26545	}
26546	reqHeaders.Set("User-Agent", c.s.userAgent())
26547	var body io.Reader = nil
26548	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
26549	if err != nil {
26550		return nil, err
26551	}
26552	reqHeaders.Set("Content-Type", "application/json")
26553	c.urlParams_.Set("alt", alt)
26554	c.urlParams_.Set("prettyPrint", "false")
26555	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
26556	urls += "?" + c.urlParams_.Encode()
26557	req, err := http.NewRequest("POST", urls, body)
26558	if err != nil {
26559		return nil, err
26560	}
26561	req.Header = reqHeaders
26562	googleapi.Expand(req.URL, map[string]string{
26563		"parent": c.parent,
26564	})
26565	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26566}
26567
26568// Do executes the "dialogflow.projects.agent.sessions.entityTypes.create" call.
26569// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
26570// will be non-nil. Any non-2xx status code is an error. Response
26571// headers are in either
26572// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
26573// (if a response was returned at all) in
26574// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
26575// whether the returned error was because http.StatusNotModified was
26576// returned.
26577func (c *ProjectsAgentSessionsEntityTypesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
26578	gensupport.SetOptions(c.urlParams_, opts...)
26579	res, err := c.doRequest("json")
26580	if res != nil && res.StatusCode == http.StatusNotModified {
26581		if res.Body != nil {
26582			res.Body.Close()
26583		}
26584		return nil, &googleapi.Error{
26585			Code:   res.StatusCode,
26586			Header: res.Header,
26587		}
26588	}
26589	if err != nil {
26590		return nil, err
26591	}
26592	defer googleapi.CloseBody(res)
26593	if err := googleapi.CheckResponse(res); err != nil {
26594		return nil, err
26595	}
26596	ret := &GoogleCloudDialogflowV2SessionEntityType{
26597		ServerResponse: googleapi.ServerResponse{
26598			Header:         res.Header,
26599			HTTPStatusCode: res.StatusCode,
26600		},
26601	}
26602	target := &ret
26603	if err := gensupport.DecodeResponse(target, res); err != nil {
26604		return nil, err
26605	}
26606	return ret, nil
26607	// {
26608	//   "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.",
26609	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/entityTypes",
26610	//   "httpMethod": "POST",
26611	//   "id": "dialogflow.projects.agent.sessions.entityTypes.create",
26612	//   "parameterOrder": [
26613	//     "parent"
26614	//   ],
26615	//   "parameters": {
26616	//     "parent": {
26617	//       "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.",
26618	//       "location": "path",
26619	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+$",
26620	//       "required": true,
26621	//       "type": "string"
26622	//     }
26623	//   },
26624	//   "path": "v2/{+parent}/entityTypes",
26625	//   "request": {
26626	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
26627	//   },
26628	//   "response": {
26629	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
26630	//   },
26631	//   "scopes": [
26632	//     "https://www.googleapis.com/auth/cloud-platform",
26633	//     "https://www.googleapis.com/auth/dialogflow"
26634	//   ]
26635	// }
26636
26637}
26638
26639// method id "dialogflow.projects.agent.sessions.entityTypes.delete":
26640
26641type ProjectsAgentSessionsEntityTypesDeleteCall struct {
26642	s          *Service
26643	name       string
26644	urlParams_ gensupport.URLParams
26645	ctx_       context.Context
26646	header_    http.Header
26647}
26648
26649// Delete: Deletes the specified session entity type. This method
26650// doesn't work with Google Assistant integration. Contact Dialogflow
26651// support if you need to use session entities with Google Assistant
26652// integration.
26653//
26654// - name: The name of the entity type to delete. Format:
26655//   `projects//agent/sessions//entityTypes/` or
26656//   `projects//agent/environments//users//sessions//entityTypes/`. If
26657//   `Environment ID` is not specified, we assume default 'draft'
26658//   environment. If `User ID` is not specified, we assume default '-'
26659//   user.
26660func (r *ProjectsAgentSessionsEntityTypesService) Delete(name string) *ProjectsAgentSessionsEntityTypesDeleteCall {
26661	c := &ProjectsAgentSessionsEntityTypesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26662	c.name = name
26663	return c
26664}
26665
26666// Fields allows partial responses to be retrieved. See
26667// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26668// for more information.
26669func (c *ProjectsAgentSessionsEntityTypesDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsEntityTypesDeleteCall {
26670	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26671	return c
26672}
26673
26674// Context sets the context to be used in this call's Do method. Any
26675// pending HTTP request will be aborted if the provided context is
26676// canceled.
26677func (c *ProjectsAgentSessionsEntityTypesDeleteCall) Context(ctx context.Context) *ProjectsAgentSessionsEntityTypesDeleteCall {
26678	c.ctx_ = ctx
26679	return c
26680}
26681
26682// Header returns an http.Header that can be modified by the caller to
26683// add HTTP headers to the request.
26684func (c *ProjectsAgentSessionsEntityTypesDeleteCall) Header() http.Header {
26685	if c.header_ == nil {
26686		c.header_ = make(http.Header)
26687	}
26688	return c.header_
26689}
26690
26691func (c *ProjectsAgentSessionsEntityTypesDeleteCall) doRequest(alt string) (*http.Response, error) {
26692	reqHeaders := make(http.Header)
26693	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
26694	for k, v := range c.header_ {
26695		reqHeaders[k] = v
26696	}
26697	reqHeaders.Set("User-Agent", c.s.userAgent())
26698	var body io.Reader = nil
26699	c.urlParams_.Set("alt", alt)
26700	c.urlParams_.Set("prettyPrint", "false")
26701	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
26702	urls += "?" + c.urlParams_.Encode()
26703	req, err := http.NewRequest("DELETE", urls, body)
26704	if err != nil {
26705		return nil, err
26706	}
26707	req.Header = reqHeaders
26708	googleapi.Expand(req.URL, map[string]string{
26709		"name": c.name,
26710	})
26711	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26712}
26713
26714// Do executes the "dialogflow.projects.agent.sessions.entityTypes.delete" call.
26715// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
26716// non-2xx status code is an error. Response headers are in either
26717// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
26718// returned at all) in error.(*googleapi.Error).Header. Use
26719// googleapi.IsNotModified to check whether the returned error was
26720// because http.StatusNotModified was returned.
26721func (c *ProjectsAgentSessionsEntityTypesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
26722	gensupport.SetOptions(c.urlParams_, opts...)
26723	res, err := c.doRequest("json")
26724	if res != nil && res.StatusCode == http.StatusNotModified {
26725		if res.Body != nil {
26726			res.Body.Close()
26727		}
26728		return nil, &googleapi.Error{
26729			Code:   res.StatusCode,
26730			Header: res.Header,
26731		}
26732	}
26733	if err != nil {
26734		return nil, err
26735	}
26736	defer googleapi.CloseBody(res)
26737	if err := googleapi.CheckResponse(res); err != nil {
26738		return nil, err
26739	}
26740	ret := &GoogleProtobufEmpty{
26741		ServerResponse: googleapi.ServerResponse{
26742			Header:         res.Header,
26743			HTTPStatusCode: res.StatusCode,
26744		},
26745	}
26746	target := &ret
26747	if err := gensupport.DecodeResponse(target, res); err != nil {
26748		return nil, err
26749	}
26750	return ret, nil
26751	// {
26752	//   "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.",
26753	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/entityTypes/{entityTypesId}",
26754	//   "httpMethod": "DELETE",
26755	//   "id": "dialogflow.projects.agent.sessions.entityTypes.delete",
26756	//   "parameterOrder": [
26757	//     "name"
26758	//   ],
26759	//   "parameters": {
26760	//     "name": {
26761	//       "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.",
26762	//       "location": "path",
26763	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+/entityTypes/[^/]+$",
26764	//       "required": true,
26765	//       "type": "string"
26766	//     }
26767	//   },
26768	//   "path": "v2/{+name}",
26769	//   "response": {
26770	//     "$ref": "GoogleProtobufEmpty"
26771	//   },
26772	//   "scopes": [
26773	//     "https://www.googleapis.com/auth/cloud-platform",
26774	//     "https://www.googleapis.com/auth/dialogflow"
26775	//   ]
26776	// }
26777
26778}
26779
26780// method id "dialogflow.projects.agent.sessions.entityTypes.get":
26781
26782type ProjectsAgentSessionsEntityTypesGetCall struct {
26783	s            *Service
26784	name         string
26785	urlParams_   gensupport.URLParams
26786	ifNoneMatch_ string
26787	ctx_         context.Context
26788	header_      http.Header
26789}
26790
26791// Get: Retrieves the specified session entity type. This method doesn't
26792// work with Google Assistant integration. Contact Dialogflow support if
26793// you need to use session entities with Google Assistant integration.
26794//
26795// - name: The name of the session entity type. Format:
26796//   `projects//agent/sessions//entityTypes/` or
26797//   `projects//agent/environments//users//sessions//entityTypes/`. If
26798//   `Environment ID` is not specified, we assume default 'draft'
26799//   environment. If `User ID` is not specified, we assume default '-'
26800//   user.
26801func (r *ProjectsAgentSessionsEntityTypesService) Get(name string) *ProjectsAgentSessionsEntityTypesGetCall {
26802	c := &ProjectsAgentSessionsEntityTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26803	c.name = name
26804	return c
26805}
26806
26807// Fields allows partial responses to be retrieved. See
26808// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26809// for more information.
26810func (c *ProjectsAgentSessionsEntityTypesGetCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsEntityTypesGetCall {
26811	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26812	return c
26813}
26814
26815// IfNoneMatch sets the optional parameter which makes the operation
26816// fail if the object's ETag matches the given value. This is useful for
26817// getting updates only after the object has changed since the last
26818// request. Use googleapi.IsNotModified to check whether the response
26819// error from Do is the result of In-None-Match.
26820func (c *ProjectsAgentSessionsEntityTypesGetCall) IfNoneMatch(entityTag string) *ProjectsAgentSessionsEntityTypesGetCall {
26821	c.ifNoneMatch_ = entityTag
26822	return c
26823}
26824
26825// Context sets the context to be used in this call's Do method. Any
26826// pending HTTP request will be aborted if the provided context is
26827// canceled.
26828func (c *ProjectsAgentSessionsEntityTypesGetCall) Context(ctx context.Context) *ProjectsAgentSessionsEntityTypesGetCall {
26829	c.ctx_ = ctx
26830	return c
26831}
26832
26833// Header returns an http.Header that can be modified by the caller to
26834// add HTTP headers to the request.
26835func (c *ProjectsAgentSessionsEntityTypesGetCall) Header() http.Header {
26836	if c.header_ == nil {
26837		c.header_ = make(http.Header)
26838	}
26839	return c.header_
26840}
26841
26842func (c *ProjectsAgentSessionsEntityTypesGetCall) doRequest(alt string) (*http.Response, error) {
26843	reqHeaders := make(http.Header)
26844	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
26845	for k, v := range c.header_ {
26846		reqHeaders[k] = v
26847	}
26848	reqHeaders.Set("User-Agent", c.s.userAgent())
26849	if c.ifNoneMatch_ != "" {
26850		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26851	}
26852	var body io.Reader = nil
26853	c.urlParams_.Set("alt", alt)
26854	c.urlParams_.Set("prettyPrint", "false")
26855	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
26856	urls += "?" + c.urlParams_.Encode()
26857	req, err := http.NewRequest("GET", urls, body)
26858	if err != nil {
26859		return nil, err
26860	}
26861	req.Header = reqHeaders
26862	googleapi.Expand(req.URL, map[string]string{
26863		"name": c.name,
26864	})
26865	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26866}
26867
26868// Do executes the "dialogflow.projects.agent.sessions.entityTypes.get" call.
26869// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
26870// will be non-nil. Any non-2xx status code is an error. Response
26871// headers are in either
26872// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
26873// (if a response was returned at all) in
26874// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
26875// whether the returned error was because http.StatusNotModified was
26876// returned.
26877func (c *ProjectsAgentSessionsEntityTypesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
26878	gensupport.SetOptions(c.urlParams_, opts...)
26879	res, err := c.doRequest("json")
26880	if res != nil && res.StatusCode == http.StatusNotModified {
26881		if res.Body != nil {
26882			res.Body.Close()
26883		}
26884		return nil, &googleapi.Error{
26885			Code:   res.StatusCode,
26886			Header: res.Header,
26887		}
26888	}
26889	if err != nil {
26890		return nil, err
26891	}
26892	defer googleapi.CloseBody(res)
26893	if err := googleapi.CheckResponse(res); err != nil {
26894		return nil, err
26895	}
26896	ret := &GoogleCloudDialogflowV2SessionEntityType{
26897		ServerResponse: googleapi.ServerResponse{
26898			Header:         res.Header,
26899			HTTPStatusCode: res.StatusCode,
26900		},
26901	}
26902	target := &ret
26903	if err := gensupport.DecodeResponse(target, res); err != nil {
26904		return nil, err
26905	}
26906	return ret, nil
26907	// {
26908	//   "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.",
26909	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/entityTypes/{entityTypesId}",
26910	//   "httpMethod": "GET",
26911	//   "id": "dialogflow.projects.agent.sessions.entityTypes.get",
26912	//   "parameterOrder": [
26913	//     "name"
26914	//   ],
26915	//   "parameters": {
26916	//     "name": {
26917	//       "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.",
26918	//       "location": "path",
26919	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+/entityTypes/[^/]+$",
26920	//       "required": true,
26921	//       "type": "string"
26922	//     }
26923	//   },
26924	//   "path": "v2/{+name}",
26925	//   "response": {
26926	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
26927	//   },
26928	//   "scopes": [
26929	//     "https://www.googleapis.com/auth/cloud-platform",
26930	//     "https://www.googleapis.com/auth/dialogflow"
26931	//   ]
26932	// }
26933
26934}
26935
26936// method id "dialogflow.projects.agent.sessions.entityTypes.list":
26937
26938type ProjectsAgentSessionsEntityTypesListCall struct {
26939	s            *Service
26940	parent       string
26941	urlParams_   gensupport.URLParams
26942	ifNoneMatch_ string
26943	ctx_         context.Context
26944	header_      http.Header
26945}
26946
26947// List: Returns the list of all session entity types in the specified
26948// session. This method doesn't work with Google Assistant integration.
26949// Contact Dialogflow support if you need to use session entities with
26950// Google Assistant integration.
26951//
26952// - parent: The session to list all session entity types from. Format:
26953//   `projects//agent/sessions/` or
26954//   `projects//agent/environments//users// sessions/`. If `Environment
26955//   ID` is not specified, we assume default 'draft' environment. If
26956//   `User ID` is not specified, we assume default '-' user.
26957func (r *ProjectsAgentSessionsEntityTypesService) List(parent string) *ProjectsAgentSessionsEntityTypesListCall {
26958	c := &ProjectsAgentSessionsEntityTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26959	c.parent = parent
26960	return c
26961}
26962
26963// PageSize sets the optional parameter "pageSize": The maximum number
26964// of items to return in a single page. By default 100 and at most 1000.
26965func (c *ProjectsAgentSessionsEntityTypesListCall) PageSize(pageSize int64) *ProjectsAgentSessionsEntityTypesListCall {
26966	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
26967	return c
26968}
26969
26970// PageToken sets the optional parameter "pageToken": The
26971// next_page_token value returned from a previous list request.
26972func (c *ProjectsAgentSessionsEntityTypesListCall) PageToken(pageToken string) *ProjectsAgentSessionsEntityTypesListCall {
26973	c.urlParams_.Set("pageToken", pageToken)
26974	return c
26975}
26976
26977// Fields allows partial responses to be retrieved. See
26978// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26979// for more information.
26980func (c *ProjectsAgentSessionsEntityTypesListCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsEntityTypesListCall {
26981	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26982	return c
26983}
26984
26985// IfNoneMatch sets the optional parameter which makes the operation
26986// fail if the object's ETag matches the given value. This is useful for
26987// getting updates only after the object has changed since the last
26988// request. Use googleapi.IsNotModified to check whether the response
26989// error from Do is the result of In-None-Match.
26990func (c *ProjectsAgentSessionsEntityTypesListCall) IfNoneMatch(entityTag string) *ProjectsAgentSessionsEntityTypesListCall {
26991	c.ifNoneMatch_ = entityTag
26992	return c
26993}
26994
26995// Context sets the context to be used in this call's Do method. Any
26996// pending HTTP request will be aborted if the provided context is
26997// canceled.
26998func (c *ProjectsAgentSessionsEntityTypesListCall) Context(ctx context.Context) *ProjectsAgentSessionsEntityTypesListCall {
26999	c.ctx_ = ctx
27000	return c
27001}
27002
27003// Header returns an http.Header that can be modified by the caller to
27004// add HTTP headers to the request.
27005func (c *ProjectsAgentSessionsEntityTypesListCall) Header() http.Header {
27006	if c.header_ == nil {
27007		c.header_ = make(http.Header)
27008	}
27009	return c.header_
27010}
27011
27012func (c *ProjectsAgentSessionsEntityTypesListCall) doRequest(alt string) (*http.Response, error) {
27013	reqHeaders := make(http.Header)
27014	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
27015	for k, v := range c.header_ {
27016		reqHeaders[k] = v
27017	}
27018	reqHeaders.Set("User-Agent", c.s.userAgent())
27019	if c.ifNoneMatch_ != "" {
27020		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
27021	}
27022	var body io.Reader = nil
27023	c.urlParams_.Set("alt", alt)
27024	c.urlParams_.Set("prettyPrint", "false")
27025	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
27026	urls += "?" + c.urlParams_.Encode()
27027	req, err := http.NewRequest("GET", urls, body)
27028	if err != nil {
27029		return nil, err
27030	}
27031	req.Header = reqHeaders
27032	googleapi.Expand(req.URL, map[string]string{
27033		"parent": c.parent,
27034	})
27035	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27036}
27037
27038// Do executes the "dialogflow.projects.agent.sessions.entityTypes.list" call.
27039// Exactly one of *GoogleCloudDialogflowV2ListSessionEntityTypesResponse
27040// or error will be non-nil. Any non-2xx status code is an error.
27041// Response headers are in either
27042// *GoogleCloudDialogflowV2ListSessionEntityTypesResponse.ServerResponse.
27043// Header or (if a response was returned at all) in
27044// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
27045// whether the returned error was because http.StatusNotModified was
27046// returned.
27047func (c *ProjectsAgentSessionsEntityTypesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListSessionEntityTypesResponse, error) {
27048	gensupport.SetOptions(c.urlParams_, opts...)
27049	res, err := c.doRequest("json")
27050	if res != nil && res.StatusCode == http.StatusNotModified {
27051		if res.Body != nil {
27052			res.Body.Close()
27053		}
27054		return nil, &googleapi.Error{
27055			Code:   res.StatusCode,
27056			Header: res.Header,
27057		}
27058	}
27059	if err != nil {
27060		return nil, err
27061	}
27062	defer googleapi.CloseBody(res)
27063	if err := googleapi.CheckResponse(res); err != nil {
27064		return nil, err
27065	}
27066	ret := &GoogleCloudDialogflowV2ListSessionEntityTypesResponse{
27067		ServerResponse: googleapi.ServerResponse{
27068			Header:         res.Header,
27069			HTTPStatusCode: res.StatusCode,
27070		},
27071	}
27072	target := &ret
27073	if err := gensupport.DecodeResponse(target, res); err != nil {
27074		return nil, err
27075	}
27076	return ret, nil
27077	// {
27078	//   "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.",
27079	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/entityTypes",
27080	//   "httpMethod": "GET",
27081	//   "id": "dialogflow.projects.agent.sessions.entityTypes.list",
27082	//   "parameterOrder": [
27083	//     "parent"
27084	//   ],
27085	//   "parameters": {
27086	//     "pageSize": {
27087	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
27088	//       "format": "int32",
27089	//       "location": "query",
27090	//       "type": "integer"
27091	//     },
27092	//     "pageToken": {
27093	//       "description": "Optional. The next_page_token value returned from a previous list request.",
27094	//       "location": "query",
27095	//       "type": "string"
27096	//     },
27097	//     "parent": {
27098	//       "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.",
27099	//       "location": "path",
27100	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+$",
27101	//       "required": true,
27102	//       "type": "string"
27103	//     }
27104	//   },
27105	//   "path": "v2/{+parent}/entityTypes",
27106	//   "response": {
27107	//     "$ref": "GoogleCloudDialogflowV2ListSessionEntityTypesResponse"
27108	//   },
27109	//   "scopes": [
27110	//     "https://www.googleapis.com/auth/cloud-platform",
27111	//     "https://www.googleapis.com/auth/dialogflow"
27112	//   ]
27113	// }
27114
27115}
27116
27117// Pages invokes f for each page of results.
27118// A non-nil error returned from f will halt the iteration.
27119// The provided context supersedes any context provided to the Context method.
27120func (c *ProjectsAgentSessionsEntityTypesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListSessionEntityTypesResponse) error) error {
27121	c.ctx_ = ctx
27122	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
27123	for {
27124		x, err := c.Do()
27125		if err != nil {
27126			return err
27127		}
27128		if err := f(x); err != nil {
27129			return err
27130		}
27131		if x.NextPageToken == "" {
27132			return nil
27133		}
27134		c.PageToken(x.NextPageToken)
27135	}
27136}
27137
27138// method id "dialogflow.projects.agent.sessions.entityTypes.patch":
27139
27140type ProjectsAgentSessionsEntityTypesPatchCall struct {
27141	s                                        *Service
27142	nameid                                   string
27143	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
27144	urlParams_                               gensupport.URLParams
27145	ctx_                                     context.Context
27146	header_                                  http.Header
27147}
27148
27149// Patch: Updates the specified session entity type. This method doesn't
27150// work with Google Assistant integration. Contact Dialogflow support if
27151// you need to use session entities with Google Assistant integration.
27152//
27153// - name: The unique identifier of this session entity type. Format:
27154//   `projects//agent/sessions//entityTypes/`, or
27155//   `projects//agent/environments//users//sessions//entityTypes/`. If
27156//   `Environment ID` is not specified, we assume default 'draft'
27157//   environment. If `User ID` is not specified, we assume default '-'
27158//   user. `` must be the display name of an existing entity type in the
27159//   same agent that will be overridden or supplemented.
27160func (r *ProjectsAgentSessionsEntityTypesService) Patch(nameid string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsAgentSessionsEntityTypesPatchCall {
27161	c := &ProjectsAgentSessionsEntityTypesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27162	c.nameid = nameid
27163	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
27164	return c
27165}
27166
27167// UpdateMask sets the optional parameter "updateMask": The mask to
27168// control which fields get updated.
27169func (c *ProjectsAgentSessionsEntityTypesPatchCall) UpdateMask(updateMask string) *ProjectsAgentSessionsEntityTypesPatchCall {
27170	c.urlParams_.Set("updateMask", updateMask)
27171	return c
27172}
27173
27174// Fields allows partial responses to be retrieved. See
27175// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27176// for more information.
27177func (c *ProjectsAgentSessionsEntityTypesPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsEntityTypesPatchCall {
27178	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27179	return c
27180}
27181
27182// Context sets the context to be used in this call's Do method. Any
27183// pending HTTP request will be aborted if the provided context is
27184// canceled.
27185func (c *ProjectsAgentSessionsEntityTypesPatchCall) Context(ctx context.Context) *ProjectsAgentSessionsEntityTypesPatchCall {
27186	c.ctx_ = ctx
27187	return c
27188}
27189
27190// Header returns an http.Header that can be modified by the caller to
27191// add HTTP headers to the request.
27192func (c *ProjectsAgentSessionsEntityTypesPatchCall) Header() http.Header {
27193	if c.header_ == nil {
27194		c.header_ = make(http.Header)
27195	}
27196	return c.header_
27197}
27198
27199func (c *ProjectsAgentSessionsEntityTypesPatchCall) doRequest(alt string) (*http.Response, error) {
27200	reqHeaders := make(http.Header)
27201	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
27202	for k, v := range c.header_ {
27203		reqHeaders[k] = v
27204	}
27205	reqHeaders.Set("User-Agent", c.s.userAgent())
27206	var body io.Reader = nil
27207	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
27208	if err != nil {
27209		return nil, err
27210	}
27211	reqHeaders.Set("Content-Type", "application/json")
27212	c.urlParams_.Set("alt", alt)
27213	c.urlParams_.Set("prettyPrint", "false")
27214	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
27215	urls += "?" + c.urlParams_.Encode()
27216	req, err := http.NewRequest("PATCH", urls, body)
27217	if err != nil {
27218		return nil, err
27219	}
27220	req.Header = reqHeaders
27221	googleapi.Expand(req.URL, map[string]string{
27222		"name": c.nameid,
27223	})
27224	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27225}
27226
27227// Do executes the "dialogflow.projects.agent.sessions.entityTypes.patch" call.
27228// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
27229// will be non-nil. Any non-2xx status code is an error. Response
27230// headers are in either
27231// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
27232// (if a response was returned at all) in
27233// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
27234// whether the returned error was because http.StatusNotModified was
27235// returned.
27236func (c *ProjectsAgentSessionsEntityTypesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
27237	gensupport.SetOptions(c.urlParams_, opts...)
27238	res, err := c.doRequest("json")
27239	if res != nil && res.StatusCode == http.StatusNotModified {
27240		if res.Body != nil {
27241			res.Body.Close()
27242		}
27243		return nil, &googleapi.Error{
27244			Code:   res.StatusCode,
27245			Header: res.Header,
27246		}
27247	}
27248	if err != nil {
27249		return nil, err
27250	}
27251	defer googleapi.CloseBody(res)
27252	if err := googleapi.CheckResponse(res); err != nil {
27253		return nil, err
27254	}
27255	ret := &GoogleCloudDialogflowV2SessionEntityType{
27256		ServerResponse: googleapi.ServerResponse{
27257			Header:         res.Header,
27258			HTTPStatusCode: res.StatusCode,
27259		},
27260	}
27261	target := &ret
27262	if err := gensupport.DecodeResponse(target, res); err != nil {
27263		return nil, err
27264	}
27265	return ret, nil
27266	// {
27267	//   "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.",
27268	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/entityTypes/{entityTypesId}",
27269	//   "httpMethod": "PATCH",
27270	//   "id": "dialogflow.projects.agent.sessions.entityTypes.patch",
27271	//   "parameterOrder": [
27272	//     "name"
27273	//   ],
27274	//   "parameters": {
27275	//     "name": {
27276	//       "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.",
27277	//       "location": "path",
27278	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+/entityTypes/[^/]+$",
27279	//       "required": true,
27280	//       "type": "string"
27281	//     },
27282	//     "updateMask": {
27283	//       "description": "Optional. The mask to control which fields get updated.",
27284	//       "format": "google-fieldmask",
27285	//       "location": "query",
27286	//       "type": "string"
27287	//     }
27288	//   },
27289	//   "path": "v2/{+name}",
27290	//   "request": {
27291	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
27292	//   },
27293	//   "response": {
27294	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
27295	//   },
27296	//   "scopes": [
27297	//     "https://www.googleapis.com/auth/cloud-platform",
27298	//     "https://www.googleapis.com/auth/dialogflow"
27299	//   ]
27300	// }
27301
27302}
27303
27304// method id "dialogflow.projects.answerRecords.list":
27305
27306type ProjectsAnswerRecordsListCall struct {
27307	s            *Service
27308	parent       string
27309	urlParams_   gensupport.URLParams
27310	ifNoneMatch_ string
27311	ctx_         context.Context
27312	header_      http.Header
27313}
27314
27315// List: Returns the list of all answer records in the specified project
27316// in reverse chronological order.
27317//
27318// - parent: The project to list all answer records for in reverse
27319//   chronological order. Format: `projects//locations/`.
27320func (r *ProjectsAnswerRecordsService) List(parent string) *ProjectsAnswerRecordsListCall {
27321	c := &ProjectsAnswerRecordsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27322	c.parent = parent
27323	return c
27324}
27325
27326// Filter sets the optional parameter "filter": Required. Filters to
27327// restrict results to specific answer records. Filter on answer record
27328// type. Currently predicates on `type` is supported, valid values are
27329// `ARTICLE_ANSWER`, `FAQ_ANSWER`. For more information about filtering,
27330// see API Filtering (https://aip.dev/160).
27331func (c *ProjectsAnswerRecordsListCall) Filter(filter string) *ProjectsAnswerRecordsListCall {
27332	c.urlParams_.Set("filter", filter)
27333	return c
27334}
27335
27336// PageSize sets the optional parameter "pageSize": The maximum number
27337// of records to return in a single page. The server may return fewer
27338// records than this. If unspecified, we use 10. The maximum is 100.
27339func (c *ProjectsAnswerRecordsListCall) PageSize(pageSize int64) *ProjectsAnswerRecordsListCall {
27340	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
27341	return c
27342}
27343
27344// PageToken sets the optional parameter "pageToken": The
27345// ListAnswerRecordsResponse.next_page_token value returned from a
27346// previous list request used to continue listing on the next page.
27347func (c *ProjectsAnswerRecordsListCall) PageToken(pageToken string) *ProjectsAnswerRecordsListCall {
27348	c.urlParams_.Set("pageToken", pageToken)
27349	return c
27350}
27351
27352// Fields allows partial responses to be retrieved. See
27353// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27354// for more information.
27355func (c *ProjectsAnswerRecordsListCall) Fields(s ...googleapi.Field) *ProjectsAnswerRecordsListCall {
27356	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27357	return c
27358}
27359
27360// IfNoneMatch sets the optional parameter which makes the operation
27361// fail if the object's ETag matches the given value. This is useful for
27362// getting updates only after the object has changed since the last
27363// request. Use googleapi.IsNotModified to check whether the response
27364// error from Do is the result of In-None-Match.
27365func (c *ProjectsAnswerRecordsListCall) IfNoneMatch(entityTag string) *ProjectsAnswerRecordsListCall {
27366	c.ifNoneMatch_ = entityTag
27367	return c
27368}
27369
27370// Context sets the context to be used in this call's Do method. Any
27371// pending HTTP request will be aborted if the provided context is
27372// canceled.
27373func (c *ProjectsAnswerRecordsListCall) Context(ctx context.Context) *ProjectsAnswerRecordsListCall {
27374	c.ctx_ = ctx
27375	return c
27376}
27377
27378// Header returns an http.Header that can be modified by the caller to
27379// add HTTP headers to the request.
27380func (c *ProjectsAnswerRecordsListCall) Header() http.Header {
27381	if c.header_ == nil {
27382		c.header_ = make(http.Header)
27383	}
27384	return c.header_
27385}
27386
27387func (c *ProjectsAnswerRecordsListCall) doRequest(alt string) (*http.Response, error) {
27388	reqHeaders := make(http.Header)
27389	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
27390	for k, v := range c.header_ {
27391		reqHeaders[k] = v
27392	}
27393	reqHeaders.Set("User-Agent", c.s.userAgent())
27394	if c.ifNoneMatch_ != "" {
27395		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
27396	}
27397	var body io.Reader = nil
27398	c.urlParams_.Set("alt", alt)
27399	c.urlParams_.Set("prettyPrint", "false")
27400	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/answerRecords")
27401	urls += "?" + c.urlParams_.Encode()
27402	req, err := http.NewRequest("GET", urls, body)
27403	if err != nil {
27404		return nil, err
27405	}
27406	req.Header = reqHeaders
27407	googleapi.Expand(req.URL, map[string]string{
27408		"parent": c.parent,
27409	})
27410	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27411}
27412
27413// Do executes the "dialogflow.projects.answerRecords.list" call.
27414// Exactly one of *GoogleCloudDialogflowV2ListAnswerRecordsResponse or
27415// error will be non-nil. Any non-2xx status code is an error. Response
27416// headers are in either
27417// *GoogleCloudDialogflowV2ListAnswerRecordsResponse.ServerResponse.Heade
27418// r or (if a response was returned at all) in
27419// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
27420// whether the returned error was because http.StatusNotModified was
27421// returned.
27422func (c *ProjectsAnswerRecordsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListAnswerRecordsResponse, error) {
27423	gensupport.SetOptions(c.urlParams_, opts...)
27424	res, err := c.doRequest("json")
27425	if res != nil && res.StatusCode == http.StatusNotModified {
27426		if res.Body != nil {
27427			res.Body.Close()
27428		}
27429		return nil, &googleapi.Error{
27430			Code:   res.StatusCode,
27431			Header: res.Header,
27432		}
27433	}
27434	if err != nil {
27435		return nil, err
27436	}
27437	defer googleapi.CloseBody(res)
27438	if err := googleapi.CheckResponse(res); err != nil {
27439		return nil, err
27440	}
27441	ret := &GoogleCloudDialogflowV2ListAnswerRecordsResponse{
27442		ServerResponse: googleapi.ServerResponse{
27443			Header:         res.Header,
27444			HTTPStatusCode: res.StatusCode,
27445		},
27446	}
27447	target := &ret
27448	if err := gensupport.DecodeResponse(target, res); err != nil {
27449		return nil, err
27450	}
27451	return ret, nil
27452	// {
27453	//   "description": "Returns the list of all answer records in the specified project in reverse chronological order.",
27454	//   "flatPath": "v2/projects/{projectsId}/answerRecords",
27455	//   "httpMethod": "GET",
27456	//   "id": "dialogflow.projects.answerRecords.list",
27457	//   "parameterOrder": [
27458	//     "parent"
27459	//   ],
27460	//   "parameters": {
27461	//     "filter": {
27462	//       "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).",
27463	//       "location": "query",
27464	//       "type": "string"
27465	//     },
27466	//     "pageSize": {
27467	//       "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.",
27468	//       "format": "int32",
27469	//       "location": "query",
27470	//       "type": "integer"
27471	//     },
27472	//     "pageToken": {
27473	//       "description": "Optional. The ListAnswerRecordsResponse.next_page_token value returned from a previous list request used to continue listing on the next page.",
27474	//       "location": "query",
27475	//       "type": "string"
27476	//     },
27477	//     "parent": {
27478	//       "description": "Required. The project to list all answer records for in reverse chronological order. Format: `projects//locations/`.",
27479	//       "location": "path",
27480	//       "pattern": "^projects/[^/]+$",
27481	//       "required": true,
27482	//       "type": "string"
27483	//     }
27484	//   },
27485	//   "path": "v2/{+parent}/answerRecords",
27486	//   "response": {
27487	//     "$ref": "GoogleCloudDialogflowV2ListAnswerRecordsResponse"
27488	//   },
27489	//   "scopes": [
27490	//     "https://www.googleapis.com/auth/cloud-platform",
27491	//     "https://www.googleapis.com/auth/dialogflow"
27492	//   ]
27493	// }
27494
27495}
27496
27497// Pages invokes f for each page of results.
27498// A non-nil error returned from f will halt the iteration.
27499// The provided context supersedes any context provided to the Context method.
27500func (c *ProjectsAnswerRecordsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListAnswerRecordsResponse) error) error {
27501	c.ctx_ = ctx
27502	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
27503	for {
27504		x, err := c.Do()
27505		if err != nil {
27506			return err
27507		}
27508		if err := f(x); err != nil {
27509			return err
27510		}
27511		if x.NextPageToken == "" {
27512			return nil
27513		}
27514		c.PageToken(x.NextPageToken)
27515	}
27516}
27517
27518// method id "dialogflow.projects.answerRecords.patch":
27519
27520type ProjectsAnswerRecordsPatchCall struct {
27521	s                                   *Service
27522	nameid                              string
27523	googleclouddialogflowv2answerrecord *GoogleCloudDialogflowV2AnswerRecord
27524	urlParams_                          gensupport.URLParams
27525	ctx_                                context.Context
27526	header_                             http.Header
27527}
27528
27529// Patch: Updates the specified answer record.
27530//
27531// - name: The unique identifier of this answer record. Format:
27532//   `projects//locations//answerRecords/`.
27533func (r *ProjectsAnswerRecordsService) Patch(nameid string, googleclouddialogflowv2answerrecord *GoogleCloudDialogflowV2AnswerRecord) *ProjectsAnswerRecordsPatchCall {
27534	c := &ProjectsAnswerRecordsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27535	c.nameid = nameid
27536	c.googleclouddialogflowv2answerrecord = googleclouddialogflowv2answerrecord
27537	return c
27538}
27539
27540// UpdateMask sets the optional parameter "updateMask": Required. The
27541// mask to control which fields get updated.
27542func (c *ProjectsAnswerRecordsPatchCall) UpdateMask(updateMask string) *ProjectsAnswerRecordsPatchCall {
27543	c.urlParams_.Set("updateMask", updateMask)
27544	return c
27545}
27546
27547// Fields allows partial responses to be retrieved. See
27548// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27549// for more information.
27550func (c *ProjectsAnswerRecordsPatchCall) Fields(s ...googleapi.Field) *ProjectsAnswerRecordsPatchCall {
27551	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27552	return c
27553}
27554
27555// Context sets the context to be used in this call's Do method. Any
27556// pending HTTP request will be aborted if the provided context is
27557// canceled.
27558func (c *ProjectsAnswerRecordsPatchCall) Context(ctx context.Context) *ProjectsAnswerRecordsPatchCall {
27559	c.ctx_ = ctx
27560	return c
27561}
27562
27563// Header returns an http.Header that can be modified by the caller to
27564// add HTTP headers to the request.
27565func (c *ProjectsAnswerRecordsPatchCall) Header() http.Header {
27566	if c.header_ == nil {
27567		c.header_ = make(http.Header)
27568	}
27569	return c.header_
27570}
27571
27572func (c *ProjectsAnswerRecordsPatchCall) doRequest(alt string) (*http.Response, error) {
27573	reqHeaders := make(http.Header)
27574	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
27575	for k, v := range c.header_ {
27576		reqHeaders[k] = v
27577	}
27578	reqHeaders.Set("User-Agent", c.s.userAgent())
27579	var body io.Reader = nil
27580	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2answerrecord)
27581	if err != nil {
27582		return nil, err
27583	}
27584	reqHeaders.Set("Content-Type", "application/json")
27585	c.urlParams_.Set("alt", alt)
27586	c.urlParams_.Set("prettyPrint", "false")
27587	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
27588	urls += "?" + c.urlParams_.Encode()
27589	req, err := http.NewRequest("PATCH", urls, body)
27590	if err != nil {
27591		return nil, err
27592	}
27593	req.Header = reqHeaders
27594	googleapi.Expand(req.URL, map[string]string{
27595		"name": c.nameid,
27596	})
27597	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27598}
27599
27600// Do executes the "dialogflow.projects.answerRecords.patch" call.
27601// Exactly one of *GoogleCloudDialogflowV2AnswerRecord or error will be
27602// non-nil. Any non-2xx status code is an error. Response headers are in
27603// either *GoogleCloudDialogflowV2AnswerRecord.ServerResponse.Header or
27604// (if a response was returned at all) in
27605// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
27606// whether the returned error was because http.StatusNotModified was
27607// returned.
27608func (c *ProjectsAnswerRecordsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2AnswerRecord, error) {
27609	gensupport.SetOptions(c.urlParams_, opts...)
27610	res, err := c.doRequest("json")
27611	if res != nil && res.StatusCode == http.StatusNotModified {
27612		if res.Body != nil {
27613			res.Body.Close()
27614		}
27615		return nil, &googleapi.Error{
27616			Code:   res.StatusCode,
27617			Header: res.Header,
27618		}
27619	}
27620	if err != nil {
27621		return nil, err
27622	}
27623	defer googleapi.CloseBody(res)
27624	if err := googleapi.CheckResponse(res); err != nil {
27625		return nil, err
27626	}
27627	ret := &GoogleCloudDialogflowV2AnswerRecord{
27628		ServerResponse: googleapi.ServerResponse{
27629			Header:         res.Header,
27630			HTTPStatusCode: res.StatusCode,
27631		},
27632	}
27633	target := &ret
27634	if err := gensupport.DecodeResponse(target, res); err != nil {
27635		return nil, err
27636	}
27637	return ret, nil
27638	// {
27639	//   "description": "Updates the specified answer record.",
27640	//   "flatPath": "v2/projects/{projectsId}/answerRecords/{answerRecordsId}",
27641	//   "httpMethod": "PATCH",
27642	//   "id": "dialogflow.projects.answerRecords.patch",
27643	//   "parameterOrder": [
27644	//     "name"
27645	//   ],
27646	//   "parameters": {
27647	//     "name": {
27648	//       "description": "The unique identifier of this answer record. Format: `projects//locations//answerRecords/`.",
27649	//       "location": "path",
27650	//       "pattern": "^projects/[^/]+/answerRecords/[^/]+$",
27651	//       "required": true,
27652	//       "type": "string"
27653	//     },
27654	//     "updateMask": {
27655	//       "description": "Required. The mask to control which fields get updated.",
27656	//       "format": "google-fieldmask",
27657	//       "location": "query",
27658	//       "type": "string"
27659	//     }
27660	//   },
27661	//   "path": "v2/{+name}",
27662	//   "request": {
27663	//     "$ref": "GoogleCloudDialogflowV2AnswerRecord"
27664	//   },
27665	//   "response": {
27666	//     "$ref": "GoogleCloudDialogflowV2AnswerRecord"
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.conversationProfiles.create":
27677
27678type ProjectsConversationProfilesCreateCall struct {
27679	s                                          *Service
27680	parent                                     string
27681	googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile
27682	urlParams_                                 gensupport.URLParams
27683	ctx_                                       context.Context
27684	header_                                    http.Header
27685}
27686
27687// Create: Creates a conversation profile in the specified project.
27688// ConversationProfile.CreateTime and ConversationProfile.UpdateTime
27689// aren't populated in the response. You can retrieve them via
27690// GetConversationProfile API.
27691//
27692// - parent: The project to create a conversation profile for. Format:
27693//   `projects//locations/`.
27694func (r *ProjectsConversationProfilesService) Create(parent string, googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile) *ProjectsConversationProfilesCreateCall {
27695	c := &ProjectsConversationProfilesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27696	c.parent = parent
27697	c.googleclouddialogflowv2conversationprofile = googleclouddialogflowv2conversationprofile
27698	return c
27699}
27700
27701// Fields allows partial responses to be retrieved. See
27702// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27703// for more information.
27704func (c *ProjectsConversationProfilesCreateCall) Fields(s ...googleapi.Field) *ProjectsConversationProfilesCreateCall {
27705	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27706	return c
27707}
27708
27709// Context sets the context to be used in this call's Do method. Any
27710// pending HTTP request will be aborted if the provided context is
27711// canceled.
27712func (c *ProjectsConversationProfilesCreateCall) Context(ctx context.Context) *ProjectsConversationProfilesCreateCall {
27713	c.ctx_ = ctx
27714	return c
27715}
27716
27717// Header returns an http.Header that can be modified by the caller to
27718// add HTTP headers to the request.
27719func (c *ProjectsConversationProfilesCreateCall) Header() http.Header {
27720	if c.header_ == nil {
27721		c.header_ = make(http.Header)
27722	}
27723	return c.header_
27724}
27725
27726func (c *ProjectsConversationProfilesCreateCall) doRequest(alt string) (*http.Response, error) {
27727	reqHeaders := make(http.Header)
27728	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
27729	for k, v := range c.header_ {
27730		reqHeaders[k] = v
27731	}
27732	reqHeaders.Set("User-Agent", c.s.userAgent())
27733	var body io.Reader = nil
27734	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2conversationprofile)
27735	if err != nil {
27736		return nil, err
27737	}
27738	reqHeaders.Set("Content-Type", "application/json")
27739	c.urlParams_.Set("alt", alt)
27740	c.urlParams_.Set("prettyPrint", "false")
27741	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversationProfiles")
27742	urls += "?" + c.urlParams_.Encode()
27743	req, err := http.NewRequest("POST", urls, body)
27744	if err != nil {
27745		return nil, err
27746	}
27747	req.Header = reqHeaders
27748	googleapi.Expand(req.URL, map[string]string{
27749		"parent": c.parent,
27750	})
27751	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27752}
27753
27754// Do executes the "dialogflow.projects.conversationProfiles.create" call.
27755// Exactly one of *GoogleCloudDialogflowV2ConversationProfile or error
27756// will be non-nil. Any non-2xx status code is an error. Response
27757// headers are in either
27758// *GoogleCloudDialogflowV2ConversationProfile.ServerResponse.Header or
27759// (if a response was returned at all) in
27760// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
27761// whether the returned error was because http.StatusNotModified was
27762// returned.
27763func (c *ProjectsConversationProfilesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ConversationProfile, error) {
27764	gensupport.SetOptions(c.urlParams_, opts...)
27765	res, err := c.doRequest("json")
27766	if res != nil && res.StatusCode == http.StatusNotModified {
27767		if res.Body != nil {
27768			res.Body.Close()
27769		}
27770		return nil, &googleapi.Error{
27771			Code:   res.StatusCode,
27772			Header: res.Header,
27773		}
27774	}
27775	if err != nil {
27776		return nil, err
27777	}
27778	defer googleapi.CloseBody(res)
27779	if err := googleapi.CheckResponse(res); err != nil {
27780		return nil, err
27781	}
27782	ret := &GoogleCloudDialogflowV2ConversationProfile{
27783		ServerResponse: googleapi.ServerResponse{
27784			Header:         res.Header,
27785			HTTPStatusCode: res.StatusCode,
27786		},
27787	}
27788	target := &ret
27789	if err := gensupport.DecodeResponse(target, res); err != nil {
27790		return nil, err
27791	}
27792	return ret, nil
27793	// {
27794	//   "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.",
27795	//   "flatPath": "v2/projects/{projectsId}/conversationProfiles",
27796	//   "httpMethod": "POST",
27797	//   "id": "dialogflow.projects.conversationProfiles.create",
27798	//   "parameterOrder": [
27799	//     "parent"
27800	//   ],
27801	//   "parameters": {
27802	//     "parent": {
27803	//       "description": "Required. The project to create a conversation profile for. Format: `projects//locations/`.",
27804	//       "location": "path",
27805	//       "pattern": "^projects/[^/]+$",
27806	//       "required": true,
27807	//       "type": "string"
27808	//     }
27809	//   },
27810	//   "path": "v2/{+parent}/conversationProfiles",
27811	//   "request": {
27812	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
27813	//   },
27814	//   "response": {
27815	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
27816	//   },
27817	//   "scopes": [
27818	//     "https://www.googleapis.com/auth/cloud-platform",
27819	//     "https://www.googleapis.com/auth/dialogflow"
27820	//   ]
27821	// }
27822
27823}
27824
27825// method id "dialogflow.projects.conversationProfiles.delete":
27826
27827type ProjectsConversationProfilesDeleteCall struct {
27828	s          *Service
27829	name       string
27830	urlParams_ gensupport.URLParams
27831	ctx_       context.Context
27832	header_    http.Header
27833}
27834
27835// Delete: Deletes the specified conversation profile.
27836//
27837// - name: The name of the conversation profile to delete. Format:
27838//   `projects//locations//conversationProfiles/`.
27839func (r *ProjectsConversationProfilesService) Delete(name string) *ProjectsConversationProfilesDeleteCall {
27840	c := &ProjectsConversationProfilesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27841	c.name = name
27842	return c
27843}
27844
27845// Fields allows partial responses to be retrieved. See
27846// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27847// for more information.
27848func (c *ProjectsConversationProfilesDeleteCall) Fields(s ...googleapi.Field) *ProjectsConversationProfilesDeleteCall {
27849	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27850	return c
27851}
27852
27853// Context sets the context to be used in this call's Do method. Any
27854// pending HTTP request will be aborted if the provided context is
27855// canceled.
27856func (c *ProjectsConversationProfilesDeleteCall) Context(ctx context.Context) *ProjectsConversationProfilesDeleteCall {
27857	c.ctx_ = ctx
27858	return c
27859}
27860
27861// Header returns an http.Header that can be modified by the caller to
27862// add HTTP headers to the request.
27863func (c *ProjectsConversationProfilesDeleteCall) Header() http.Header {
27864	if c.header_ == nil {
27865		c.header_ = make(http.Header)
27866	}
27867	return c.header_
27868}
27869
27870func (c *ProjectsConversationProfilesDeleteCall) doRequest(alt string) (*http.Response, error) {
27871	reqHeaders := make(http.Header)
27872	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
27873	for k, v := range c.header_ {
27874		reqHeaders[k] = v
27875	}
27876	reqHeaders.Set("User-Agent", c.s.userAgent())
27877	var body io.Reader = nil
27878	c.urlParams_.Set("alt", alt)
27879	c.urlParams_.Set("prettyPrint", "false")
27880	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
27881	urls += "?" + c.urlParams_.Encode()
27882	req, err := http.NewRequest("DELETE", urls, body)
27883	if err != nil {
27884		return nil, err
27885	}
27886	req.Header = reqHeaders
27887	googleapi.Expand(req.URL, map[string]string{
27888		"name": c.name,
27889	})
27890	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27891}
27892
27893// Do executes the "dialogflow.projects.conversationProfiles.delete" call.
27894// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
27895// non-2xx status code is an error. Response headers are in either
27896// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
27897// returned at all) in error.(*googleapi.Error).Header. Use
27898// googleapi.IsNotModified to check whether the returned error was
27899// because http.StatusNotModified was returned.
27900func (c *ProjectsConversationProfilesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
27901	gensupport.SetOptions(c.urlParams_, opts...)
27902	res, err := c.doRequest("json")
27903	if res != nil && res.StatusCode == http.StatusNotModified {
27904		if res.Body != nil {
27905			res.Body.Close()
27906		}
27907		return nil, &googleapi.Error{
27908			Code:   res.StatusCode,
27909			Header: res.Header,
27910		}
27911	}
27912	if err != nil {
27913		return nil, err
27914	}
27915	defer googleapi.CloseBody(res)
27916	if err := googleapi.CheckResponse(res); err != nil {
27917		return nil, err
27918	}
27919	ret := &GoogleProtobufEmpty{
27920		ServerResponse: googleapi.ServerResponse{
27921			Header:         res.Header,
27922			HTTPStatusCode: res.StatusCode,
27923		},
27924	}
27925	target := &ret
27926	if err := gensupport.DecodeResponse(target, res); err != nil {
27927		return nil, err
27928	}
27929	return ret, nil
27930	// {
27931	//   "description": "Deletes the specified conversation profile.",
27932	//   "flatPath": "v2/projects/{projectsId}/conversationProfiles/{conversationProfilesId}",
27933	//   "httpMethod": "DELETE",
27934	//   "id": "dialogflow.projects.conversationProfiles.delete",
27935	//   "parameterOrder": [
27936	//     "name"
27937	//   ],
27938	//   "parameters": {
27939	//     "name": {
27940	//       "description": "Required. The name of the conversation profile to delete. Format: `projects//locations//conversationProfiles/`.",
27941	//       "location": "path",
27942	//       "pattern": "^projects/[^/]+/conversationProfiles/[^/]+$",
27943	//       "required": true,
27944	//       "type": "string"
27945	//     }
27946	//   },
27947	//   "path": "v2/{+name}",
27948	//   "response": {
27949	//     "$ref": "GoogleProtobufEmpty"
27950	//   },
27951	//   "scopes": [
27952	//     "https://www.googleapis.com/auth/cloud-platform",
27953	//     "https://www.googleapis.com/auth/dialogflow"
27954	//   ]
27955	// }
27956
27957}
27958
27959// method id "dialogflow.projects.conversationProfiles.get":
27960
27961type ProjectsConversationProfilesGetCall struct {
27962	s            *Service
27963	name         string
27964	urlParams_   gensupport.URLParams
27965	ifNoneMatch_ string
27966	ctx_         context.Context
27967	header_      http.Header
27968}
27969
27970// Get: Retrieves the specified conversation profile.
27971//
27972// - name: The resource name of the conversation profile. Format:
27973//   `projects//locations//conversationProfiles/`.
27974func (r *ProjectsConversationProfilesService) Get(name string) *ProjectsConversationProfilesGetCall {
27975	c := &ProjectsConversationProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27976	c.name = name
27977	return c
27978}
27979
27980// Fields allows partial responses to be retrieved. See
27981// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27982// for more information.
27983func (c *ProjectsConversationProfilesGetCall) Fields(s ...googleapi.Field) *ProjectsConversationProfilesGetCall {
27984	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27985	return c
27986}
27987
27988// IfNoneMatch sets the optional parameter which makes the operation
27989// fail if the object's ETag matches the given value. This is useful for
27990// getting updates only after the object has changed since the last
27991// request. Use googleapi.IsNotModified to check whether the response
27992// error from Do is the result of In-None-Match.
27993func (c *ProjectsConversationProfilesGetCall) IfNoneMatch(entityTag string) *ProjectsConversationProfilesGetCall {
27994	c.ifNoneMatch_ = entityTag
27995	return c
27996}
27997
27998// Context sets the context to be used in this call's Do method. Any
27999// pending HTTP request will be aborted if the provided context is
28000// canceled.
28001func (c *ProjectsConversationProfilesGetCall) Context(ctx context.Context) *ProjectsConversationProfilesGetCall {
28002	c.ctx_ = ctx
28003	return c
28004}
28005
28006// Header returns an http.Header that can be modified by the caller to
28007// add HTTP headers to the request.
28008func (c *ProjectsConversationProfilesGetCall) Header() http.Header {
28009	if c.header_ == nil {
28010		c.header_ = make(http.Header)
28011	}
28012	return c.header_
28013}
28014
28015func (c *ProjectsConversationProfilesGetCall) doRequest(alt string) (*http.Response, error) {
28016	reqHeaders := make(http.Header)
28017	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
28018	for k, v := range c.header_ {
28019		reqHeaders[k] = v
28020	}
28021	reqHeaders.Set("User-Agent", c.s.userAgent())
28022	if c.ifNoneMatch_ != "" {
28023		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
28024	}
28025	var body io.Reader = nil
28026	c.urlParams_.Set("alt", alt)
28027	c.urlParams_.Set("prettyPrint", "false")
28028	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
28029	urls += "?" + c.urlParams_.Encode()
28030	req, err := http.NewRequest("GET", urls, body)
28031	if err != nil {
28032		return nil, err
28033	}
28034	req.Header = reqHeaders
28035	googleapi.Expand(req.URL, map[string]string{
28036		"name": c.name,
28037	})
28038	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28039}
28040
28041// Do executes the "dialogflow.projects.conversationProfiles.get" call.
28042// Exactly one of *GoogleCloudDialogflowV2ConversationProfile or error
28043// will be non-nil. Any non-2xx status code is an error. Response
28044// headers are in either
28045// *GoogleCloudDialogflowV2ConversationProfile.ServerResponse.Header or
28046// (if a response was returned at all) in
28047// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
28048// whether the returned error was because http.StatusNotModified was
28049// returned.
28050func (c *ProjectsConversationProfilesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ConversationProfile, error) {
28051	gensupport.SetOptions(c.urlParams_, opts...)
28052	res, err := c.doRequest("json")
28053	if res != nil && res.StatusCode == http.StatusNotModified {
28054		if res.Body != nil {
28055			res.Body.Close()
28056		}
28057		return nil, &googleapi.Error{
28058			Code:   res.StatusCode,
28059			Header: res.Header,
28060		}
28061	}
28062	if err != nil {
28063		return nil, err
28064	}
28065	defer googleapi.CloseBody(res)
28066	if err := googleapi.CheckResponse(res); err != nil {
28067		return nil, err
28068	}
28069	ret := &GoogleCloudDialogflowV2ConversationProfile{
28070		ServerResponse: googleapi.ServerResponse{
28071			Header:         res.Header,
28072			HTTPStatusCode: res.StatusCode,
28073		},
28074	}
28075	target := &ret
28076	if err := gensupport.DecodeResponse(target, res); err != nil {
28077		return nil, err
28078	}
28079	return ret, nil
28080	// {
28081	//   "description": "Retrieves the specified conversation profile.",
28082	//   "flatPath": "v2/projects/{projectsId}/conversationProfiles/{conversationProfilesId}",
28083	//   "httpMethod": "GET",
28084	//   "id": "dialogflow.projects.conversationProfiles.get",
28085	//   "parameterOrder": [
28086	//     "name"
28087	//   ],
28088	//   "parameters": {
28089	//     "name": {
28090	//       "description": "Required. The resource name of the conversation profile. Format: `projects//locations//conversationProfiles/`.",
28091	//       "location": "path",
28092	//       "pattern": "^projects/[^/]+/conversationProfiles/[^/]+$",
28093	//       "required": true,
28094	//       "type": "string"
28095	//     }
28096	//   },
28097	//   "path": "v2/{+name}",
28098	//   "response": {
28099	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
28100	//   },
28101	//   "scopes": [
28102	//     "https://www.googleapis.com/auth/cloud-platform",
28103	//     "https://www.googleapis.com/auth/dialogflow"
28104	//   ]
28105	// }
28106
28107}
28108
28109// method id "dialogflow.projects.conversationProfiles.list":
28110
28111type ProjectsConversationProfilesListCall struct {
28112	s            *Service
28113	parent       string
28114	urlParams_   gensupport.URLParams
28115	ifNoneMatch_ string
28116	ctx_         context.Context
28117	header_      http.Header
28118}
28119
28120// List: Returns the list of all conversation profiles in the specified
28121// project.
28122//
28123// - parent: The project to list all conversation profiles from. Format:
28124//   `projects//locations/`.
28125func (r *ProjectsConversationProfilesService) List(parent string) *ProjectsConversationProfilesListCall {
28126	c := &ProjectsConversationProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28127	c.parent = parent
28128	return c
28129}
28130
28131// PageSize sets the optional parameter "pageSize": The maximum number
28132// of items to return in a single page. By default 100 and at most 1000.
28133func (c *ProjectsConversationProfilesListCall) PageSize(pageSize int64) *ProjectsConversationProfilesListCall {
28134	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
28135	return c
28136}
28137
28138// PageToken sets the optional parameter "pageToken": The
28139// next_page_token value returned from a previous list request.
28140func (c *ProjectsConversationProfilesListCall) PageToken(pageToken string) *ProjectsConversationProfilesListCall {
28141	c.urlParams_.Set("pageToken", pageToken)
28142	return c
28143}
28144
28145// Fields allows partial responses to be retrieved. See
28146// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28147// for more information.
28148func (c *ProjectsConversationProfilesListCall) Fields(s ...googleapi.Field) *ProjectsConversationProfilesListCall {
28149	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28150	return c
28151}
28152
28153// IfNoneMatch sets the optional parameter which makes the operation
28154// fail if the object's ETag matches the given value. This is useful for
28155// getting updates only after the object has changed since the last
28156// request. Use googleapi.IsNotModified to check whether the response
28157// error from Do is the result of In-None-Match.
28158func (c *ProjectsConversationProfilesListCall) IfNoneMatch(entityTag string) *ProjectsConversationProfilesListCall {
28159	c.ifNoneMatch_ = entityTag
28160	return c
28161}
28162
28163// Context sets the context to be used in this call's Do method. Any
28164// pending HTTP request will be aborted if the provided context is
28165// canceled.
28166func (c *ProjectsConversationProfilesListCall) Context(ctx context.Context) *ProjectsConversationProfilesListCall {
28167	c.ctx_ = ctx
28168	return c
28169}
28170
28171// Header returns an http.Header that can be modified by the caller to
28172// add HTTP headers to the request.
28173func (c *ProjectsConversationProfilesListCall) Header() http.Header {
28174	if c.header_ == nil {
28175		c.header_ = make(http.Header)
28176	}
28177	return c.header_
28178}
28179
28180func (c *ProjectsConversationProfilesListCall) doRequest(alt string) (*http.Response, error) {
28181	reqHeaders := make(http.Header)
28182	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
28183	for k, v := range c.header_ {
28184		reqHeaders[k] = v
28185	}
28186	reqHeaders.Set("User-Agent", c.s.userAgent())
28187	if c.ifNoneMatch_ != "" {
28188		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
28189	}
28190	var body io.Reader = nil
28191	c.urlParams_.Set("alt", alt)
28192	c.urlParams_.Set("prettyPrint", "false")
28193	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversationProfiles")
28194	urls += "?" + c.urlParams_.Encode()
28195	req, err := http.NewRequest("GET", urls, body)
28196	if err != nil {
28197		return nil, err
28198	}
28199	req.Header = reqHeaders
28200	googleapi.Expand(req.URL, map[string]string{
28201		"parent": c.parent,
28202	})
28203	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28204}
28205
28206// Do executes the "dialogflow.projects.conversationProfiles.list" call.
28207// Exactly one of
28208// *GoogleCloudDialogflowV2ListConversationProfilesResponse or error
28209// will be non-nil. Any non-2xx status code is an error. Response
28210// headers are in either
28211// *GoogleCloudDialogflowV2ListConversationProfilesResponse.ServerRespons
28212// e.Header or (if a response was returned at all) in
28213// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
28214// whether the returned error was because http.StatusNotModified was
28215// returned.
28216func (c *ProjectsConversationProfilesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListConversationProfilesResponse, error) {
28217	gensupport.SetOptions(c.urlParams_, opts...)
28218	res, err := c.doRequest("json")
28219	if res != nil && res.StatusCode == http.StatusNotModified {
28220		if res.Body != nil {
28221			res.Body.Close()
28222		}
28223		return nil, &googleapi.Error{
28224			Code:   res.StatusCode,
28225			Header: res.Header,
28226		}
28227	}
28228	if err != nil {
28229		return nil, err
28230	}
28231	defer googleapi.CloseBody(res)
28232	if err := googleapi.CheckResponse(res); err != nil {
28233		return nil, err
28234	}
28235	ret := &GoogleCloudDialogflowV2ListConversationProfilesResponse{
28236		ServerResponse: googleapi.ServerResponse{
28237			Header:         res.Header,
28238			HTTPStatusCode: res.StatusCode,
28239		},
28240	}
28241	target := &ret
28242	if err := gensupport.DecodeResponse(target, res); err != nil {
28243		return nil, err
28244	}
28245	return ret, nil
28246	// {
28247	//   "description": "Returns the list of all conversation profiles in the specified project.",
28248	//   "flatPath": "v2/projects/{projectsId}/conversationProfiles",
28249	//   "httpMethod": "GET",
28250	//   "id": "dialogflow.projects.conversationProfiles.list",
28251	//   "parameterOrder": [
28252	//     "parent"
28253	//   ],
28254	//   "parameters": {
28255	//     "pageSize": {
28256	//       "description": "The maximum number of items to return in a single page. By default 100 and at most 1000.",
28257	//       "format": "int32",
28258	//       "location": "query",
28259	//       "type": "integer"
28260	//     },
28261	//     "pageToken": {
28262	//       "description": "The next_page_token value returned from a previous list request.",
28263	//       "location": "query",
28264	//       "type": "string"
28265	//     },
28266	//     "parent": {
28267	//       "description": "Required. The project to list all conversation profiles from. Format: `projects//locations/`.",
28268	//       "location": "path",
28269	//       "pattern": "^projects/[^/]+$",
28270	//       "required": true,
28271	//       "type": "string"
28272	//     }
28273	//   },
28274	//   "path": "v2/{+parent}/conversationProfiles",
28275	//   "response": {
28276	//     "$ref": "GoogleCloudDialogflowV2ListConversationProfilesResponse"
28277	//   },
28278	//   "scopes": [
28279	//     "https://www.googleapis.com/auth/cloud-platform",
28280	//     "https://www.googleapis.com/auth/dialogflow"
28281	//   ]
28282	// }
28283
28284}
28285
28286// Pages invokes f for each page of results.
28287// A non-nil error returned from f will halt the iteration.
28288// The provided context supersedes any context provided to the Context method.
28289func (c *ProjectsConversationProfilesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListConversationProfilesResponse) error) error {
28290	c.ctx_ = ctx
28291	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
28292	for {
28293		x, err := c.Do()
28294		if err != nil {
28295			return err
28296		}
28297		if err := f(x); err != nil {
28298			return err
28299		}
28300		if x.NextPageToken == "" {
28301			return nil
28302		}
28303		c.PageToken(x.NextPageToken)
28304	}
28305}
28306
28307// method id "dialogflow.projects.conversationProfiles.patch":
28308
28309type ProjectsConversationProfilesPatchCall struct {
28310	s                                          *Service
28311	nameid                                     string
28312	googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile
28313	urlParams_                                 gensupport.URLParams
28314	ctx_                                       context.Context
28315	header_                                    http.Header
28316}
28317
28318// Patch: Updates the specified conversation profile.
28319// ConversationProfile.CreateTime and ConversationProfile.UpdateTime
28320// aren't populated in the response. You can retrieve them via
28321// GetConversationProfile API.
28322//
28323// - name: The unique identifier of this conversation profile. Format:
28324//   `projects//locations//conversationProfiles/`.
28325func (r *ProjectsConversationProfilesService) Patch(nameid string, googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile) *ProjectsConversationProfilesPatchCall {
28326	c := &ProjectsConversationProfilesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28327	c.nameid = nameid
28328	c.googleclouddialogflowv2conversationprofile = googleclouddialogflowv2conversationprofile
28329	return c
28330}
28331
28332// UpdateMask sets the optional parameter "updateMask": Required. The
28333// mask to control which fields to update.
28334func (c *ProjectsConversationProfilesPatchCall) UpdateMask(updateMask string) *ProjectsConversationProfilesPatchCall {
28335	c.urlParams_.Set("updateMask", updateMask)
28336	return c
28337}
28338
28339// Fields allows partial responses to be retrieved. See
28340// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28341// for more information.
28342func (c *ProjectsConversationProfilesPatchCall) Fields(s ...googleapi.Field) *ProjectsConversationProfilesPatchCall {
28343	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28344	return c
28345}
28346
28347// Context sets the context to be used in this call's Do method. Any
28348// pending HTTP request will be aborted if the provided context is
28349// canceled.
28350func (c *ProjectsConversationProfilesPatchCall) Context(ctx context.Context) *ProjectsConversationProfilesPatchCall {
28351	c.ctx_ = ctx
28352	return c
28353}
28354
28355// Header returns an http.Header that can be modified by the caller to
28356// add HTTP headers to the request.
28357func (c *ProjectsConversationProfilesPatchCall) Header() http.Header {
28358	if c.header_ == nil {
28359		c.header_ = make(http.Header)
28360	}
28361	return c.header_
28362}
28363
28364func (c *ProjectsConversationProfilesPatchCall) doRequest(alt string) (*http.Response, error) {
28365	reqHeaders := make(http.Header)
28366	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
28367	for k, v := range c.header_ {
28368		reqHeaders[k] = v
28369	}
28370	reqHeaders.Set("User-Agent", c.s.userAgent())
28371	var body io.Reader = nil
28372	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2conversationprofile)
28373	if err != nil {
28374		return nil, err
28375	}
28376	reqHeaders.Set("Content-Type", "application/json")
28377	c.urlParams_.Set("alt", alt)
28378	c.urlParams_.Set("prettyPrint", "false")
28379	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
28380	urls += "?" + c.urlParams_.Encode()
28381	req, err := http.NewRequest("PATCH", urls, body)
28382	if err != nil {
28383		return nil, err
28384	}
28385	req.Header = reqHeaders
28386	googleapi.Expand(req.URL, map[string]string{
28387		"name": c.nameid,
28388	})
28389	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28390}
28391
28392// Do executes the "dialogflow.projects.conversationProfiles.patch" call.
28393// Exactly one of *GoogleCloudDialogflowV2ConversationProfile or error
28394// will be non-nil. Any non-2xx status code is an error. Response
28395// headers are in either
28396// *GoogleCloudDialogflowV2ConversationProfile.ServerResponse.Header or
28397// (if a response was returned at all) in
28398// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
28399// whether the returned error was because http.StatusNotModified was
28400// returned.
28401func (c *ProjectsConversationProfilesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ConversationProfile, error) {
28402	gensupport.SetOptions(c.urlParams_, opts...)
28403	res, err := c.doRequest("json")
28404	if res != nil && res.StatusCode == http.StatusNotModified {
28405		if res.Body != nil {
28406			res.Body.Close()
28407		}
28408		return nil, &googleapi.Error{
28409			Code:   res.StatusCode,
28410			Header: res.Header,
28411		}
28412	}
28413	if err != nil {
28414		return nil, err
28415	}
28416	defer googleapi.CloseBody(res)
28417	if err := googleapi.CheckResponse(res); err != nil {
28418		return nil, err
28419	}
28420	ret := &GoogleCloudDialogflowV2ConversationProfile{
28421		ServerResponse: googleapi.ServerResponse{
28422			Header:         res.Header,
28423			HTTPStatusCode: res.StatusCode,
28424		},
28425	}
28426	target := &ret
28427	if err := gensupport.DecodeResponse(target, res); err != nil {
28428		return nil, err
28429	}
28430	return ret, nil
28431	// {
28432	//   "description": "Updates the specified conversation profile. ConversationProfile.CreateTime and ConversationProfile.UpdateTime aren't populated in the response. You can retrieve them via GetConversationProfile API.",
28433	//   "flatPath": "v2/projects/{projectsId}/conversationProfiles/{conversationProfilesId}",
28434	//   "httpMethod": "PATCH",
28435	//   "id": "dialogflow.projects.conversationProfiles.patch",
28436	//   "parameterOrder": [
28437	//     "name"
28438	//   ],
28439	//   "parameters": {
28440	//     "name": {
28441	//       "description": "The unique identifier of this conversation profile. Format: `projects//locations//conversationProfiles/`.",
28442	//       "location": "path",
28443	//       "pattern": "^projects/[^/]+/conversationProfiles/[^/]+$",
28444	//       "required": true,
28445	//       "type": "string"
28446	//     },
28447	//     "updateMask": {
28448	//       "description": "Required. The mask to control which fields to update.",
28449	//       "format": "google-fieldmask",
28450	//       "location": "query",
28451	//       "type": "string"
28452	//     }
28453	//   },
28454	//   "path": "v2/{+name}",
28455	//   "request": {
28456	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
28457	//   },
28458	//   "response": {
28459	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
28460	//   },
28461	//   "scopes": [
28462	//     "https://www.googleapis.com/auth/cloud-platform",
28463	//     "https://www.googleapis.com/auth/dialogflow"
28464	//   ]
28465	// }
28466
28467}
28468
28469// method id "dialogflow.projects.conversations.complete":
28470
28471type ProjectsConversationsCompleteCall struct {
28472	s                                                  *Service
28473	nameid                                             string
28474	googleclouddialogflowv2completeconversationrequest *GoogleCloudDialogflowV2CompleteConversationRequest
28475	urlParams_                                         gensupport.URLParams
28476	ctx_                                               context.Context
28477	header_                                            http.Header
28478}
28479
28480// Complete: Completes the specified conversation. Finished
28481// conversations are purged from the database after 30 days.
28482//
28483// - name: Resource identifier of the conversation to close. Format:
28484//   `projects//locations//conversations/`.
28485func (r *ProjectsConversationsService) Complete(nameid string, googleclouddialogflowv2completeconversationrequest *GoogleCloudDialogflowV2CompleteConversationRequest) *ProjectsConversationsCompleteCall {
28486	c := &ProjectsConversationsCompleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28487	c.nameid = nameid
28488	c.googleclouddialogflowv2completeconversationrequest = googleclouddialogflowv2completeconversationrequest
28489	return c
28490}
28491
28492// Fields allows partial responses to be retrieved. See
28493// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28494// for more information.
28495func (c *ProjectsConversationsCompleteCall) Fields(s ...googleapi.Field) *ProjectsConversationsCompleteCall {
28496	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28497	return c
28498}
28499
28500// Context sets the context to be used in this call's Do method. Any
28501// pending HTTP request will be aborted if the provided context is
28502// canceled.
28503func (c *ProjectsConversationsCompleteCall) Context(ctx context.Context) *ProjectsConversationsCompleteCall {
28504	c.ctx_ = ctx
28505	return c
28506}
28507
28508// Header returns an http.Header that can be modified by the caller to
28509// add HTTP headers to the request.
28510func (c *ProjectsConversationsCompleteCall) Header() http.Header {
28511	if c.header_ == nil {
28512		c.header_ = make(http.Header)
28513	}
28514	return c.header_
28515}
28516
28517func (c *ProjectsConversationsCompleteCall) doRequest(alt string) (*http.Response, error) {
28518	reqHeaders := make(http.Header)
28519	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
28520	for k, v := range c.header_ {
28521		reqHeaders[k] = v
28522	}
28523	reqHeaders.Set("User-Agent", c.s.userAgent())
28524	var body io.Reader = nil
28525	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2completeconversationrequest)
28526	if err != nil {
28527		return nil, err
28528	}
28529	reqHeaders.Set("Content-Type", "application/json")
28530	c.urlParams_.Set("alt", alt)
28531	c.urlParams_.Set("prettyPrint", "false")
28532	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:complete")
28533	urls += "?" + c.urlParams_.Encode()
28534	req, err := http.NewRequest("POST", urls, body)
28535	if err != nil {
28536		return nil, err
28537	}
28538	req.Header = reqHeaders
28539	googleapi.Expand(req.URL, map[string]string{
28540		"name": c.nameid,
28541	})
28542	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28543}
28544
28545// Do executes the "dialogflow.projects.conversations.complete" call.
28546// Exactly one of *GoogleCloudDialogflowV2Conversation or error will be
28547// non-nil. Any non-2xx status code is an error. Response headers are in
28548// either *GoogleCloudDialogflowV2Conversation.ServerResponse.Header or
28549// (if a response was returned at all) in
28550// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
28551// whether the returned error was because http.StatusNotModified was
28552// returned.
28553func (c *ProjectsConversationsCompleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Conversation, error) {
28554	gensupport.SetOptions(c.urlParams_, opts...)
28555	res, err := c.doRequest("json")
28556	if res != nil && res.StatusCode == http.StatusNotModified {
28557		if res.Body != nil {
28558			res.Body.Close()
28559		}
28560		return nil, &googleapi.Error{
28561			Code:   res.StatusCode,
28562			Header: res.Header,
28563		}
28564	}
28565	if err != nil {
28566		return nil, err
28567	}
28568	defer googleapi.CloseBody(res)
28569	if err := googleapi.CheckResponse(res); err != nil {
28570		return nil, err
28571	}
28572	ret := &GoogleCloudDialogflowV2Conversation{
28573		ServerResponse: googleapi.ServerResponse{
28574			Header:         res.Header,
28575			HTTPStatusCode: res.StatusCode,
28576		},
28577	}
28578	target := &ret
28579	if err := gensupport.DecodeResponse(target, res); err != nil {
28580		return nil, err
28581	}
28582	return ret, nil
28583	// {
28584	//   "description": "Completes the specified conversation. Finished conversations are purged from the database after 30 days.",
28585	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}:complete",
28586	//   "httpMethod": "POST",
28587	//   "id": "dialogflow.projects.conversations.complete",
28588	//   "parameterOrder": [
28589	//     "name"
28590	//   ],
28591	//   "parameters": {
28592	//     "name": {
28593	//       "description": "Required. Resource identifier of the conversation to close. Format: `projects//locations//conversations/`.",
28594	//       "location": "path",
28595	//       "pattern": "^projects/[^/]+/conversations/[^/]+$",
28596	//       "required": true,
28597	//       "type": "string"
28598	//     }
28599	//   },
28600	//   "path": "v2/{+name}:complete",
28601	//   "request": {
28602	//     "$ref": "GoogleCloudDialogflowV2CompleteConversationRequest"
28603	//   },
28604	//   "response": {
28605	//     "$ref": "GoogleCloudDialogflowV2Conversation"
28606	//   },
28607	//   "scopes": [
28608	//     "https://www.googleapis.com/auth/cloud-platform",
28609	//     "https://www.googleapis.com/auth/dialogflow"
28610	//   ]
28611	// }
28612
28613}
28614
28615// method id "dialogflow.projects.conversations.create":
28616
28617type ProjectsConversationsCreateCall struct {
28618	s                                   *Service
28619	parentid                            string
28620	googleclouddialogflowv2conversation *GoogleCloudDialogflowV2Conversation
28621	urlParams_                          gensupport.URLParams
28622	ctx_                                context.Context
28623	header_                             http.Header
28624}
28625
28626// Create: Creates a new conversation. Conversations are auto-completed
28627// after 24 hours. Conversation Lifecycle: There are two stages during a
28628// conversation: Automated Agent Stage and Assist Stage. For Automated
28629// Agent Stage, there will be a dialogflow agent responding to user
28630// queries. For Assist Stage, there's no dialogflow agent responding to
28631// user queries. But we will provide suggestions which are generated
28632// from conversation. If Conversation.conversation_profile is configured
28633// for a dialogflow agent, conversation will start from `Automated Agent
28634// Stage`, otherwise, it will start from `Assist Stage`. And during
28635// `Automated Agent Stage`, once an Intent with
28636// Intent.live_agent_handoff is triggered, conversation will transfer to
28637// Assist Stage.
28638//
28639// - parent: Resource identifier of the project creating the
28640//   conversation. Format: `projects//locations/`.
28641func (r *ProjectsConversationsService) Create(parentid string, googleclouddialogflowv2conversation *GoogleCloudDialogflowV2Conversation) *ProjectsConversationsCreateCall {
28642	c := &ProjectsConversationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28643	c.parentid = parentid
28644	c.googleclouddialogflowv2conversation = googleclouddialogflowv2conversation
28645	return c
28646}
28647
28648// ConversationId sets the optional parameter "conversationId":
28649// Identifier of the conversation. Generally it's auto generated by
28650// Google. Only set it if you cannot wait for the response to return a
28651// auto-generated one to you. The conversation ID must be compliant with
28652// the regression fomula "a-zA-Z*" with the characters length in range
28653// of [3,64]. If the field is provided, the caller is resposible for 1.
28654// the uniqueness of the ID, otherwise the request will be rejected. 2.
28655// the consistency for whether to use custom ID or not under a project
28656// to better ensure uniqueness.
28657func (c *ProjectsConversationsCreateCall) ConversationId(conversationId string) *ProjectsConversationsCreateCall {
28658	c.urlParams_.Set("conversationId", conversationId)
28659	return c
28660}
28661
28662// Fields allows partial responses to be retrieved. See
28663// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28664// for more information.
28665func (c *ProjectsConversationsCreateCall) Fields(s ...googleapi.Field) *ProjectsConversationsCreateCall {
28666	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28667	return c
28668}
28669
28670// Context sets the context to be used in this call's Do method. Any
28671// pending HTTP request will be aborted if the provided context is
28672// canceled.
28673func (c *ProjectsConversationsCreateCall) Context(ctx context.Context) *ProjectsConversationsCreateCall {
28674	c.ctx_ = ctx
28675	return c
28676}
28677
28678// Header returns an http.Header that can be modified by the caller to
28679// add HTTP headers to the request.
28680func (c *ProjectsConversationsCreateCall) Header() http.Header {
28681	if c.header_ == nil {
28682		c.header_ = make(http.Header)
28683	}
28684	return c.header_
28685}
28686
28687func (c *ProjectsConversationsCreateCall) doRequest(alt string) (*http.Response, error) {
28688	reqHeaders := make(http.Header)
28689	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
28690	for k, v := range c.header_ {
28691		reqHeaders[k] = v
28692	}
28693	reqHeaders.Set("User-Agent", c.s.userAgent())
28694	var body io.Reader = nil
28695	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2conversation)
28696	if err != nil {
28697		return nil, err
28698	}
28699	reqHeaders.Set("Content-Type", "application/json")
28700	c.urlParams_.Set("alt", alt)
28701	c.urlParams_.Set("prettyPrint", "false")
28702	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversations")
28703	urls += "?" + c.urlParams_.Encode()
28704	req, err := http.NewRequest("POST", urls, body)
28705	if err != nil {
28706		return nil, err
28707	}
28708	req.Header = reqHeaders
28709	googleapi.Expand(req.URL, map[string]string{
28710		"parent": c.parentid,
28711	})
28712	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28713}
28714
28715// Do executes the "dialogflow.projects.conversations.create" call.
28716// Exactly one of *GoogleCloudDialogflowV2Conversation or error will be
28717// non-nil. Any non-2xx status code is an error. Response headers are in
28718// either *GoogleCloudDialogflowV2Conversation.ServerResponse.Header or
28719// (if a response was returned at all) in
28720// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
28721// whether the returned error was because http.StatusNotModified was
28722// returned.
28723func (c *ProjectsConversationsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Conversation, error) {
28724	gensupport.SetOptions(c.urlParams_, opts...)
28725	res, err := c.doRequest("json")
28726	if res != nil && res.StatusCode == http.StatusNotModified {
28727		if res.Body != nil {
28728			res.Body.Close()
28729		}
28730		return nil, &googleapi.Error{
28731			Code:   res.StatusCode,
28732			Header: res.Header,
28733		}
28734	}
28735	if err != nil {
28736		return nil, err
28737	}
28738	defer googleapi.CloseBody(res)
28739	if err := googleapi.CheckResponse(res); err != nil {
28740		return nil, err
28741	}
28742	ret := &GoogleCloudDialogflowV2Conversation{
28743		ServerResponse: googleapi.ServerResponse{
28744			Header:         res.Header,
28745			HTTPStatusCode: res.StatusCode,
28746		},
28747	}
28748	target := &ret
28749	if err := gensupport.DecodeResponse(target, res); err != nil {
28750		return nil, err
28751	}
28752	return ret, nil
28753	// {
28754	//   "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.",
28755	//   "flatPath": "v2/projects/{projectsId}/conversations",
28756	//   "httpMethod": "POST",
28757	//   "id": "dialogflow.projects.conversations.create",
28758	//   "parameterOrder": [
28759	//     "parent"
28760	//   ],
28761	//   "parameters": {
28762	//     "conversationId": {
28763	//       "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.",
28764	//       "location": "query",
28765	//       "type": "string"
28766	//     },
28767	//     "parent": {
28768	//       "description": "Required. Resource identifier of the project creating the conversation. Format: `projects//locations/`.",
28769	//       "location": "path",
28770	//       "pattern": "^projects/[^/]+$",
28771	//       "required": true,
28772	//       "type": "string"
28773	//     }
28774	//   },
28775	//   "path": "v2/{+parent}/conversations",
28776	//   "request": {
28777	//     "$ref": "GoogleCloudDialogflowV2Conversation"
28778	//   },
28779	//   "response": {
28780	//     "$ref": "GoogleCloudDialogflowV2Conversation"
28781	//   },
28782	//   "scopes": [
28783	//     "https://www.googleapis.com/auth/cloud-platform",
28784	//     "https://www.googleapis.com/auth/dialogflow"
28785	//   ]
28786	// }
28787
28788}
28789
28790// method id "dialogflow.projects.conversations.get":
28791
28792type ProjectsConversationsGetCall struct {
28793	s            *Service
28794	name         string
28795	urlParams_   gensupport.URLParams
28796	ifNoneMatch_ string
28797	ctx_         context.Context
28798	header_      http.Header
28799}
28800
28801// Get: Retrieves the specific conversation.
28802//
28803// - name: The name of the conversation. Format:
28804//   `projects//locations//conversations/`.
28805func (r *ProjectsConversationsService) Get(name string) *ProjectsConversationsGetCall {
28806	c := &ProjectsConversationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28807	c.name = name
28808	return c
28809}
28810
28811// Fields allows partial responses to be retrieved. See
28812// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28813// for more information.
28814func (c *ProjectsConversationsGetCall) Fields(s ...googleapi.Field) *ProjectsConversationsGetCall {
28815	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28816	return c
28817}
28818
28819// IfNoneMatch sets the optional parameter which makes the operation
28820// fail if the object's ETag matches the given value. This is useful for
28821// getting updates only after the object has changed since the last
28822// request. Use googleapi.IsNotModified to check whether the response
28823// error from Do is the result of In-None-Match.
28824func (c *ProjectsConversationsGetCall) IfNoneMatch(entityTag string) *ProjectsConversationsGetCall {
28825	c.ifNoneMatch_ = entityTag
28826	return c
28827}
28828
28829// Context sets the context to be used in this call's Do method. Any
28830// pending HTTP request will be aborted if the provided context is
28831// canceled.
28832func (c *ProjectsConversationsGetCall) Context(ctx context.Context) *ProjectsConversationsGetCall {
28833	c.ctx_ = ctx
28834	return c
28835}
28836
28837// Header returns an http.Header that can be modified by the caller to
28838// add HTTP headers to the request.
28839func (c *ProjectsConversationsGetCall) Header() http.Header {
28840	if c.header_ == nil {
28841		c.header_ = make(http.Header)
28842	}
28843	return c.header_
28844}
28845
28846func (c *ProjectsConversationsGetCall) doRequest(alt string) (*http.Response, error) {
28847	reqHeaders := make(http.Header)
28848	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
28849	for k, v := range c.header_ {
28850		reqHeaders[k] = v
28851	}
28852	reqHeaders.Set("User-Agent", c.s.userAgent())
28853	if c.ifNoneMatch_ != "" {
28854		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
28855	}
28856	var body io.Reader = nil
28857	c.urlParams_.Set("alt", alt)
28858	c.urlParams_.Set("prettyPrint", "false")
28859	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
28860	urls += "?" + c.urlParams_.Encode()
28861	req, err := http.NewRequest("GET", urls, body)
28862	if err != nil {
28863		return nil, err
28864	}
28865	req.Header = reqHeaders
28866	googleapi.Expand(req.URL, map[string]string{
28867		"name": c.name,
28868	})
28869	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28870}
28871
28872// Do executes the "dialogflow.projects.conversations.get" call.
28873// Exactly one of *GoogleCloudDialogflowV2Conversation or error will be
28874// non-nil. Any non-2xx status code is an error. Response headers are in
28875// either *GoogleCloudDialogflowV2Conversation.ServerResponse.Header or
28876// (if a response was returned at all) in
28877// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
28878// whether the returned error was because http.StatusNotModified was
28879// returned.
28880func (c *ProjectsConversationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Conversation, error) {
28881	gensupport.SetOptions(c.urlParams_, opts...)
28882	res, err := c.doRequest("json")
28883	if res != nil && res.StatusCode == http.StatusNotModified {
28884		if res.Body != nil {
28885			res.Body.Close()
28886		}
28887		return nil, &googleapi.Error{
28888			Code:   res.StatusCode,
28889			Header: res.Header,
28890		}
28891	}
28892	if err != nil {
28893		return nil, err
28894	}
28895	defer googleapi.CloseBody(res)
28896	if err := googleapi.CheckResponse(res); err != nil {
28897		return nil, err
28898	}
28899	ret := &GoogleCloudDialogflowV2Conversation{
28900		ServerResponse: googleapi.ServerResponse{
28901			Header:         res.Header,
28902			HTTPStatusCode: res.StatusCode,
28903		},
28904	}
28905	target := &ret
28906	if err := gensupport.DecodeResponse(target, res); err != nil {
28907		return nil, err
28908	}
28909	return ret, nil
28910	// {
28911	//   "description": "Retrieves the specific conversation.",
28912	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}",
28913	//   "httpMethod": "GET",
28914	//   "id": "dialogflow.projects.conversations.get",
28915	//   "parameterOrder": [
28916	//     "name"
28917	//   ],
28918	//   "parameters": {
28919	//     "name": {
28920	//       "description": "Required. The name of the conversation. Format: `projects//locations//conversations/`.",
28921	//       "location": "path",
28922	//       "pattern": "^projects/[^/]+/conversations/[^/]+$",
28923	//       "required": true,
28924	//       "type": "string"
28925	//     }
28926	//   },
28927	//   "path": "v2/{+name}",
28928	//   "response": {
28929	//     "$ref": "GoogleCloudDialogflowV2Conversation"
28930	//   },
28931	//   "scopes": [
28932	//     "https://www.googleapis.com/auth/cloud-platform",
28933	//     "https://www.googleapis.com/auth/dialogflow"
28934	//   ]
28935	// }
28936
28937}
28938
28939// method id "dialogflow.projects.conversations.list":
28940
28941type ProjectsConversationsListCall struct {
28942	s            *Service
28943	parent       string
28944	urlParams_   gensupport.URLParams
28945	ifNoneMatch_ string
28946	ctx_         context.Context
28947	header_      http.Header
28948}
28949
28950// List: Returns the list of all conversations in the specified project.
28951//
28952// - parent: The project from which to list all conversation. Format:
28953//   `projects//locations/`.
28954func (r *ProjectsConversationsService) List(parent string) *ProjectsConversationsListCall {
28955	c := &ProjectsConversationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28956	c.parent = parent
28957	return c
28958}
28959
28960// Filter sets the optional parameter "filter": A filter expression that
28961// filters conversations listed in the response. In general, the
28962// expression must specify the field name, a comparison operator, and
28963// the value to use for filtering: - The value must be a string, a
28964// number, or a boolean. - The comparison operator must be either
28965// `=`,`!=`, `>`, or `<`. - To filter on multiple expressions, separate
28966// the expressions with `AND` or `OR` (omitting both implies `AND`). -
28967// For clarity, expressions can be enclosed in parentheses. Only
28968// `lifecycle_state` can be filtered on in this way. For example, the
28969// following expression only returns `COMPLETED` conversations:
28970// `lifecycle_state = "COMPLETED" For more information about filtering,
28971// see API Filtering (https://aip.dev/160).
28972func (c *ProjectsConversationsListCall) Filter(filter string) *ProjectsConversationsListCall {
28973	c.urlParams_.Set("filter", filter)
28974	return c
28975}
28976
28977// PageSize sets the optional parameter "pageSize": The maximum number
28978// of items to return in a single page. By default 100 and at most 1000.
28979func (c *ProjectsConversationsListCall) PageSize(pageSize int64) *ProjectsConversationsListCall {
28980	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
28981	return c
28982}
28983
28984// PageToken sets the optional parameter "pageToken": The
28985// next_page_token value returned from a previous list request.
28986func (c *ProjectsConversationsListCall) PageToken(pageToken string) *ProjectsConversationsListCall {
28987	c.urlParams_.Set("pageToken", pageToken)
28988	return c
28989}
28990
28991// Fields allows partial responses to be retrieved. See
28992// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28993// for more information.
28994func (c *ProjectsConversationsListCall) Fields(s ...googleapi.Field) *ProjectsConversationsListCall {
28995	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28996	return c
28997}
28998
28999// IfNoneMatch sets the optional parameter which makes the operation
29000// fail if the object's ETag matches the given value. This is useful for
29001// getting updates only after the object has changed since the last
29002// request. Use googleapi.IsNotModified to check whether the response
29003// error from Do is the result of In-None-Match.
29004func (c *ProjectsConversationsListCall) IfNoneMatch(entityTag string) *ProjectsConversationsListCall {
29005	c.ifNoneMatch_ = entityTag
29006	return c
29007}
29008
29009// Context sets the context to be used in this call's Do method. Any
29010// pending HTTP request will be aborted if the provided context is
29011// canceled.
29012func (c *ProjectsConversationsListCall) Context(ctx context.Context) *ProjectsConversationsListCall {
29013	c.ctx_ = ctx
29014	return c
29015}
29016
29017// Header returns an http.Header that can be modified by the caller to
29018// add HTTP headers to the request.
29019func (c *ProjectsConversationsListCall) Header() http.Header {
29020	if c.header_ == nil {
29021		c.header_ = make(http.Header)
29022	}
29023	return c.header_
29024}
29025
29026func (c *ProjectsConversationsListCall) doRequest(alt string) (*http.Response, error) {
29027	reqHeaders := make(http.Header)
29028	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
29029	for k, v := range c.header_ {
29030		reqHeaders[k] = v
29031	}
29032	reqHeaders.Set("User-Agent", c.s.userAgent())
29033	if c.ifNoneMatch_ != "" {
29034		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29035	}
29036	var body io.Reader = nil
29037	c.urlParams_.Set("alt", alt)
29038	c.urlParams_.Set("prettyPrint", "false")
29039	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversations")
29040	urls += "?" + c.urlParams_.Encode()
29041	req, err := http.NewRequest("GET", urls, body)
29042	if err != nil {
29043		return nil, err
29044	}
29045	req.Header = reqHeaders
29046	googleapi.Expand(req.URL, map[string]string{
29047		"parent": c.parent,
29048	})
29049	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29050}
29051
29052// Do executes the "dialogflow.projects.conversations.list" call.
29053// Exactly one of *GoogleCloudDialogflowV2ListConversationsResponse or
29054// error will be non-nil. Any non-2xx status code is an error. Response
29055// headers are in either
29056// *GoogleCloudDialogflowV2ListConversationsResponse.ServerResponse.Heade
29057// r or (if a response was returned at all) in
29058// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
29059// whether the returned error was because http.StatusNotModified was
29060// returned.
29061func (c *ProjectsConversationsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListConversationsResponse, error) {
29062	gensupport.SetOptions(c.urlParams_, opts...)
29063	res, err := c.doRequest("json")
29064	if res != nil && res.StatusCode == http.StatusNotModified {
29065		if res.Body != nil {
29066			res.Body.Close()
29067		}
29068		return nil, &googleapi.Error{
29069			Code:   res.StatusCode,
29070			Header: res.Header,
29071		}
29072	}
29073	if err != nil {
29074		return nil, err
29075	}
29076	defer googleapi.CloseBody(res)
29077	if err := googleapi.CheckResponse(res); err != nil {
29078		return nil, err
29079	}
29080	ret := &GoogleCloudDialogflowV2ListConversationsResponse{
29081		ServerResponse: googleapi.ServerResponse{
29082			Header:         res.Header,
29083			HTTPStatusCode: res.StatusCode,
29084		},
29085	}
29086	target := &ret
29087	if err := gensupport.DecodeResponse(target, res); err != nil {
29088		return nil, err
29089	}
29090	return ret, nil
29091	// {
29092	//   "description": "Returns the list of all conversations in the specified project.",
29093	//   "flatPath": "v2/projects/{projectsId}/conversations",
29094	//   "httpMethod": "GET",
29095	//   "id": "dialogflow.projects.conversations.list",
29096	//   "parameterOrder": [
29097	//     "parent"
29098	//   ],
29099	//   "parameters": {
29100	//     "filter": {
29101	//       "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).",
29102	//       "location": "query",
29103	//       "type": "string"
29104	//     },
29105	//     "pageSize": {
29106	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
29107	//       "format": "int32",
29108	//       "location": "query",
29109	//       "type": "integer"
29110	//     },
29111	//     "pageToken": {
29112	//       "description": "Optional. The next_page_token value returned from a previous list request.",
29113	//       "location": "query",
29114	//       "type": "string"
29115	//     },
29116	//     "parent": {
29117	//       "description": "Required. The project from which to list all conversation. Format: `projects//locations/`.",
29118	//       "location": "path",
29119	//       "pattern": "^projects/[^/]+$",
29120	//       "required": true,
29121	//       "type": "string"
29122	//     }
29123	//   },
29124	//   "path": "v2/{+parent}/conversations",
29125	//   "response": {
29126	//     "$ref": "GoogleCloudDialogflowV2ListConversationsResponse"
29127	//   },
29128	//   "scopes": [
29129	//     "https://www.googleapis.com/auth/cloud-platform",
29130	//     "https://www.googleapis.com/auth/dialogflow"
29131	//   ]
29132	// }
29133
29134}
29135
29136// Pages invokes f for each page of results.
29137// A non-nil error returned from f will halt the iteration.
29138// The provided context supersedes any context provided to the Context method.
29139func (c *ProjectsConversationsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListConversationsResponse) error) error {
29140	c.ctx_ = ctx
29141	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
29142	for {
29143		x, err := c.Do()
29144		if err != nil {
29145			return err
29146		}
29147		if err := f(x); err != nil {
29148			return err
29149		}
29150		if x.NextPageToken == "" {
29151			return nil
29152		}
29153		c.PageToken(x.NextPageToken)
29154	}
29155}
29156
29157// method id "dialogflow.projects.conversations.messages.list":
29158
29159type ProjectsConversationsMessagesListCall struct {
29160	s            *Service
29161	parent       string
29162	urlParams_   gensupport.URLParams
29163	ifNoneMatch_ string
29164	ctx_         context.Context
29165	header_      http.Header
29166}
29167
29168// List: Lists messages that belong to a given conversation. `messages`
29169// are ordered by `create_time` in descending order. To fetch updates
29170// without duplication, send request with filter
29171// `create_time_epoch_microseconds > [first item's create_time of
29172// previous request]` and empty page_token.
29173//
29174// - parent: The name of the conversation to list messages for. Format:
29175//   `projects//locations//conversations/`.
29176func (r *ProjectsConversationsMessagesService) List(parent string) *ProjectsConversationsMessagesListCall {
29177	c := &ProjectsConversationsMessagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29178	c.parent = parent
29179	return c
29180}
29181
29182// Filter sets the optional parameter "filter": Filter on message
29183// fields. Currently predicates on `create_time` and
29184// `create_time_epoch_microseconds` are supported. `create_time` only
29185// support milliseconds accuracy. E.g., `create_time_epoch_microseconds
29186// > 1551790877964485` or `create_time > 2017-01-15T01:30:15.01Z`. For
29187// more information about filtering, see API Filtering
29188// (https://aip.dev/160).
29189func (c *ProjectsConversationsMessagesListCall) Filter(filter string) *ProjectsConversationsMessagesListCall {
29190	c.urlParams_.Set("filter", filter)
29191	return c
29192}
29193
29194// PageSize sets the optional parameter "pageSize": The maximum number
29195// of items to return in a single page. By default 100 and at most 1000.
29196func (c *ProjectsConversationsMessagesListCall) PageSize(pageSize int64) *ProjectsConversationsMessagesListCall {
29197	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
29198	return c
29199}
29200
29201// PageToken sets the optional parameter "pageToken": The
29202// next_page_token value returned from a previous list request.
29203func (c *ProjectsConversationsMessagesListCall) PageToken(pageToken string) *ProjectsConversationsMessagesListCall {
29204	c.urlParams_.Set("pageToken", pageToken)
29205	return c
29206}
29207
29208// Fields allows partial responses to be retrieved. See
29209// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29210// for more information.
29211func (c *ProjectsConversationsMessagesListCall) Fields(s ...googleapi.Field) *ProjectsConversationsMessagesListCall {
29212	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29213	return c
29214}
29215
29216// IfNoneMatch sets the optional parameter which makes the operation
29217// fail if the object's ETag matches the given value. This is useful for
29218// getting updates only after the object has changed since the last
29219// request. Use googleapi.IsNotModified to check whether the response
29220// error from Do is the result of In-None-Match.
29221func (c *ProjectsConversationsMessagesListCall) IfNoneMatch(entityTag string) *ProjectsConversationsMessagesListCall {
29222	c.ifNoneMatch_ = entityTag
29223	return c
29224}
29225
29226// Context sets the context to be used in this call's Do method. Any
29227// pending HTTP request will be aborted if the provided context is
29228// canceled.
29229func (c *ProjectsConversationsMessagesListCall) Context(ctx context.Context) *ProjectsConversationsMessagesListCall {
29230	c.ctx_ = ctx
29231	return c
29232}
29233
29234// Header returns an http.Header that can be modified by the caller to
29235// add HTTP headers to the request.
29236func (c *ProjectsConversationsMessagesListCall) Header() http.Header {
29237	if c.header_ == nil {
29238		c.header_ = make(http.Header)
29239	}
29240	return c.header_
29241}
29242
29243func (c *ProjectsConversationsMessagesListCall) doRequest(alt string) (*http.Response, error) {
29244	reqHeaders := make(http.Header)
29245	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
29246	for k, v := range c.header_ {
29247		reqHeaders[k] = v
29248	}
29249	reqHeaders.Set("User-Agent", c.s.userAgent())
29250	if c.ifNoneMatch_ != "" {
29251		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29252	}
29253	var body io.Reader = nil
29254	c.urlParams_.Set("alt", alt)
29255	c.urlParams_.Set("prettyPrint", "false")
29256	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/messages")
29257	urls += "?" + c.urlParams_.Encode()
29258	req, err := http.NewRequest("GET", urls, body)
29259	if err != nil {
29260		return nil, err
29261	}
29262	req.Header = reqHeaders
29263	googleapi.Expand(req.URL, map[string]string{
29264		"parent": c.parent,
29265	})
29266	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29267}
29268
29269// Do executes the "dialogflow.projects.conversations.messages.list" call.
29270// Exactly one of *GoogleCloudDialogflowV2ListMessagesResponse or error
29271// will be non-nil. Any non-2xx status code is an error. Response
29272// headers are in either
29273// *GoogleCloudDialogflowV2ListMessagesResponse.ServerResponse.Header or
29274// (if a response was returned at all) in
29275// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
29276// whether the returned error was because http.StatusNotModified was
29277// returned.
29278func (c *ProjectsConversationsMessagesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListMessagesResponse, error) {
29279	gensupport.SetOptions(c.urlParams_, opts...)
29280	res, err := c.doRequest("json")
29281	if res != nil && res.StatusCode == http.StatusNotModified {
29282		if res.Body != nil {
29283			res.Body.Close()
29284		}
29285		return nil, &googleapi.Error{
29286			Code:   res.StatusCode,
29287			Header: res.Header,
29288		}
29289	}
29290	if err != nil {
29291		return nil, err
29292	}
29293	defer googleapi.CloseBody(res)
29294	if err := googleapi.CheckResponse(res); err != nil {
29295		return nil, err
29296	}
29297	ret := &GoogleCloudDialogflowV2ListMessagesResponse{
29298		ServerResponse: googleapi.ServerResponse{
29299			Header:         res.Header,
29300			HTTPStatusCode: res.StatusCode,
29301		},
29302	}
29303	target := &ret
29304	if err := gensupport.DecodeResponse(target, res); err != nil {
29305		return nil, err
29306	}
29307	return ret, nil
29308	// {
29309	//   "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.",
29310	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/messages",
29311	//   "httpMethod": "GET",
29312	//   "id": "dialogflow.projects.conversations.messages.list",
29313	//   "parameterOrder": [
29314	//     "parent"
29315	//   ],
29316	//   "parameters": {
29317	//     "filter": {
29318	//       "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).",
29319	//       "location": "query",
29320	//       "type": "string"
29321	//     },
29322	//     "pageSize": {
29323	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
29324	//       "format": "int32",
29325	//       "location": "query",
29326	//       "type": "integer"
29327	//     },
29328	//     "pageToken": {
29329	//       "description": "Optional. The next_page_token value returned from a previous list request.",
29330	//       "location": "query",
29331	//       "type": "string"
29332	//     },
29333	//     "parent": {
29334	//       "description": "Required. The name of the conversation to list messages for. Format: `projects//locations//conversations/`",
29335	//       "location": "path",
29336	//       "pattern": "^projects/[^/]+/conversations/[^/]+$",
29337	//       "required": true,
29338	//       "type": "string"
29339	//     }
29340	//   },
29341	//   "path": "v2/{+parent}/messages",
29342	//   "response": {
29343	//     "$ref": "GoogleCloudDialogflowV2ListMessagesResponse"
29344	//   },
29345	//   "scopes": [
29346	//     "https://www.googleapis.com/auth/cloud-platform",
29347	//     "https://www.googleapis.com/auth/dialogflow"
29348	//   ]
29349	// }
29350
29351}
29352
29353// Pages invokes f for each page of results.
29354// A non-nil error returned from f will halt the iteration.
29355// The provided context supersedes any context provided to the Context method.
29356func (c *ProjectsConversationsMessagesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListMessagesResponse) error) error {
29357	c.ctx_ = ctx
29358	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
29359	for {
29360		x, err := c.Do()
29361		if err != nil {
29362			return err
29363		}
29364		if err := f(x); err != nil {
29365			return err
29366		}
29367		if x.NextPageToken == "" {
29368			return nil
29369		}
29370		c.PageToken(x.NextPageToken)
29371	}
29372}
29373
29374// method id "dialogflow.projects.conversations.participants.analyzeContent":
29375
29376type ProjectsConversationsParticipantsAnalyzeContentCall struct {
29377	s                                            *Service
29378	participant                                  string
29379	googleclouddialogflowv2analyzecontentrequest *GoogleCloudDialogflowV2AnalyzeContentRequest
29380	urlParams_                                   gensupport.URLParams
29381	ctx_                                         context.Context
29382	header_                                      http.Header
29383}
29384
29385// AnalyzeContent: Adds a text (chat, for example), or audio (phone
29386// recording, for example) message from a participant into the
29387// conversation. Note: Always use agent versions for production traffic
29388// sent to virtual agents. See Versions and environments
29389// (https://cloud.google.com/dialogflow/es/docs/agents-versions).
29390//
29391// - participant: The name of the participant this text comes from.
29392//   Format: `projects//locations//conversations//participants/`.
29393func (r *ProjectsConversationsParticipantsService) AnalyzeContent(participant string, googleclouddialogflowv2analyzecontentrequest *GoogleCloudDialogflowV2AnalyzeContentRequest) *ProjectsConversationsParticipantsAnalyzeContentCall {
29394	c := &ProjectsConversationsParticipantsAnalyzeContentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29395	c.participant = participant
29396	c.googleclouddialogflowv2analyzecontentrequest = googleclouddialogflowv2analyzecontentrequest
29397	return c
29398}
29399
29400// Fields allows partial responses to be retrieved. See
29401// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29402// for more information.
29403func (c *ProjectsConversationsParticipantsAnalyzeContentCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsAnalyzeContentCall {
29404	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29405	return c
29406}
29407
29408// Context sets the context to be used in this call's Do method. Any
29409// pending HTTP request will be aborted if the provided context is
29410// canceled.
29411func (c *ProjectsConversationsParticipantsAnalyzeContentCall) Context(ctx context.Context) *ProjectsConversationsParticipantsAnalyzeContentCall {
29412	c.ctx_ = ctx
29413	return c
29414}
29415
29416// Header returns an http.Header that can be modified by the caller to
29417// add HTTP headers to the request.
29418func (c *ProjectsConversationsParticipantsAnalyzeContentCall) Header() http.Header {
29419	if c.header_ == nil {
29420		c.header_ = make(http.Header)
29421	}
29422	return c.header_
29423}
29424
29425func (c *ProjectsConversationsParticipantsAnalyzeContentCall) doRequest(alt string) (*http.Response, error) {
29426	reqHeaders := make(http.Header)
29427	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
29428	for k, v := range c.header_ {
29429		reqHeaders[k] = v
29430	}
29431	reqHeaders.Set("User-Agent", c.s.userAgent())
29432	var body io.Reader = nil
29433	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2analyzecontentrequest)
29434	if err != nil {
29435		return nil, err
29436	}
29437	reqHeaders.Set("Content-Type", "application/json")
29438	c.urlParams_.Set("alt", alt)
29439	c.urlParams_.Set("prettyPrint", "false")
29440	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+participant}:analyzeContent")
29441	urls += "?" + c.urlParams_.Encode()
29442	req, err := http.NewRequest("POST", urls, body)
29443	if err != nil {
29444		return nil, err
29445	}
29446	req.Header = reqHeaders
29447	googleapi.Expand(req.URL, map[string]string{
29448		"participant": c.participant,
29449	})
29450	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29451}
29452
29453// Do executes the "dialogflow.projects.conversations.participants.analyzeContent" call.
29454// Exactly one of *GoogleCloudDialogflowV2AnalyzeContentResponse or
29455// error will be non-nil. Any non-2xx status code is an error. Response
29456// headers are in either
29457// *GoogleCloudDialogflowV2AnalyzeContentResponse.ServerResponse.Header
29458// or (if a response was returned at all) in
29459// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
29460// whether the returned error was because http.StatusNotModified was
29461// returned.
29462func (c *ProjectsConversationsParticipantsAnalyzeContentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2AnalyzeContentResponse, error) {
29463	gensupport.SetOptions(c.urlParams_, opts...)
29464	res, err := c.doRequest("json")
29465	if res != nil && res.StatusCode == http.StatusNotModified {
29466		if res.Body != nil {
29467			res.Body.Close()
29468		}
29469		return nil, &googleapi.Error{
29470			Code:   res.StatusCode,
29471			Header: res.Header,
29472		}
29473	}
29474	if err != nil {
29475		return nil, err
29476	}
29477	defer googleapi.CloseBody(res)
29478	if err := googleapi.CheckResponse(res); err != nil {
29479		return nil, err
29480	}
29481	ret := &GoogleCloudDialogflowV2AnalyzeContentResponse{
29482		ServerResponse: googleapi.ServerResponse{
29483			Header:         res.Header,
29484			HTTPStatusCode: res.StatusCode,
29485		},
29486	}
29487	target := &ret
29488	if err := gensupport.DecodeResponse(target, res); err != nil {
29489		return nil, err
29490	}
29491	return ret, nil
29492	// {
29493	//   "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).",
29494	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants/{participantsId}:analyzeContent",
29495	//   "httpMethod": "POST",
29496	//   "id": "dialogflow.projects.conversations.participants.analyzeContent",
29497	//   "parameterOrder": [
29498	//     "participant"
29499	//   ],
29500	//   "parameters": {
29501	//     "participant": {
29502	//       "description": "Required. The name of the participant this text comes from. Format: `projects//locations//conversations//participants/`.",
29503	//       "location": "path",
29504	//       "pattern": "^projects/[^/]+/conversations/[^/]+/participants/[^/]+$",
29505	//       "required": true,
29506	//       "type": "string"
29507	//     }
29508	//   },
29509	//   "path": "v2/{+participant}:analyzeContent",
29510	//   "request": {
29511	//     "$ref": "GoogleCloudDialogflowV2AnalyzeContentRequest"
29512	//   },
29513	//   "response": {
29514	//     "$ref": "GoogleCloudDialogflowV2AnalyzeContentResponse"
29515	//   },
29516	//   "scopes": [
29517	//     "https://www.googleapis.com/auth/cloud-platform",
29518	//     "https://www.googleapis.com/auth/dialogflow"
29519	//   ]
29520	// }
29521
29522}
29523
29524// method id "dialogflow.projects.conversations.participants.create":
29525
29526type ProjectsConversationsParticipantsCreateCall struct {
29527	s                                  *Service
29528	parentid                           string
29529	googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant
29530	urlParams_                         gensupport.URLParams
29531	ctx_                               context.Context
29532	header_                            http.Header
29533}
29534
29535// Create: Creates a new participant in a conversation.
29536//
29537// - parent: Resource identifier of the conversation adding the
29538//   participant. Format: `projects//locations//conversations/`.
29539func (r *ProjectsConversationsParticipantsService) Create(parentid string, googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant) *ProjectsConversationsParticipantsCreateCall {
29540	c := &ProjectsConversationsParticipantsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29541	c.parentid = parentid
29542	c.googleclouddialogflowv2participant = googleclouddialogflowv2participant
29543	return c
29544}
29545
29546// Fields allows partial responses to be retrieved. See
29547// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29548// for more information.
29549func (c *ProjectsConversationsParticipantsCreateCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsCreateCall {
29550	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29551	return c
29552}
29553
29554// Context sets the context to be used in this call's Do method. Any
29555// pending HTTP request will be aborted if the provided context is
29556// canceled.
29557func (c *ProjectsConversationsParticipantsCreateCall) Context(ctx context.Context) *ProjectsConversationsParticipantsCreateCall {
29558	c.ctx_ = ctx
29559	return c
29560}
29561
29562// Header returns an http.Header that can be modified by the caller to
29563// add HTTP headers to the request.
29564func (c *ProjectsConversationsParticipantsCreateCall) Header() http.Header {
29565	if c.header_ == nil {
29566		c.header_ = make(http.Header)
29567	}
29568	return c.header_
29569}
29570
29571func (c *ProjectsConversationsParticipantsCreateCall) doRequest(alt string) (*http.Response, error) {
29572	reqHeaders := make(http.Header)
29573	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
29574	for k, v := range c.header_ {
29575		reqHeaders[k] = v
29576	}
29577	reqHeaders.Set("User-Agent", c.s.userAgent())
29578	var body io.Reader = nil
29579	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2participant)
29580	if err != nil {
29581		return nil, err
29582	}
29583	reqHeaders.Set("Content-Type", "application/json")
29584	c.urlParams_.Set("alt", alt)
29585	c.urlParams_.Set("prettyPrint", "false")
29586	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/participants")
29587	urls += "?" + c.urlParams_.Encode()
29588	req, err := http.NewRequest("POST", urls, body)
29589	if err != nil {
29590		return nil, err
29591	}
29592	req.Header = reqHeaders
29593	googleapi.Expand(req.URL, map[string]string{
29594		"parent": c.parentid,
29595	})
29596	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29597}
29598
29599// Do executes the "dialogflow.projects.conversations.participants.create" call.
29600// Exactly one of *GoogleCloudDialogflowV2Participant or error will be
29601// non-nil. Any non-2xx status code is an error. Response headers are in
29602// either *GoogleCloudDialogflowV2Participant.ServerResponse.Header or
29603// (if a response was returned at all) in
29604// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
29605// whether the returned error was because http.StatusNotModified was
29606// returned.
29607func (c *ProjectsConversationsParticipantsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Participant, error) {
29608	gensupport.SetOptions(c.urlParams_, opts...)
29609	res, err := c.doRequest("json")
29610	if res != nil && res.StatusCode == http.StatusNotModified {
29611		if res.Body != nil {
29612			res.Body.Close()
29613		}
29614		return nil, &googleapi.Error{
29615			Code:   res.StatusCode,
29616			Header: res.Header,
29617		}
29618	}
29619	if err != nil {
29620		return nil, err
29621	}
29622	defer googleapi.CloseBody(res)
29623	if err := googleapi.CheckResponse(res); err != nil {
29624		return nil, err
29625	}
29626	ret := &GoogleCloudDialogflowV2Participant{
29627		ServerResponse: googleapi.ServerResponse{
29628			Header:         res.Header,
29629			HTTPStatusCode: res.StatusCode,
29630		},
29631	}
29632	target := &ret
29633	if err := gensupport.DecodeResponse(target, res); err != nil {
29634		return nil, err
29635	}
29636	return ret, nil
29637	// {
29638	//   "description": "Creates a new participant in a conversation.",
29639	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants",
29640	//   "httpMethod": "POST",
29641	//   "id": "dialogflow.projects.conversations.participants.create",
29642	//   "parameterOrder": [
29643	//     "parent"
29644	//   ],
29645	//   "parameters": {
29646	//     "parent": {
29647	//       "description": "Required. Resource identifier of the conversation adding the participant. Format: `projects//locations//conversations/`.",
29648	//       "location": "path",
29649	//       "pattern": "^projects/[^/]+/conversations/[^/]+$",
29650	//       "required": true,
29651	//       "type": "string"
29652	//     }
29653	//   },
29654	//   "path": "v2/{+parent}/participants",
29655	//   "request": {
29656	//     "$ref": "GoogleCloudDialogflowV2Participant"
29657	//   },
29658	//   "response": {
29659	//     "$ref": "GoogleCloudDialogflowV2Participant"
29660	//   },
29661	//   "scopes": [
29662	//     "https://www.googleapis.com/auth/cloud-platform",
29663	//     "https://www.googleapis.com/auth/dialogflow"
29664	//   ]
29665	// }
29666
29667}
29668
29669// method id "dialogflow.projects.conversations.participants.get":
29670
29671type ProjectsConversationsParticipantsGetCall struct {
29672	s            *Service
29673	name         string
29674	urlParams_   gensupport.URLParams
29675	ifNoneMatch_ string
29676	ctx_         context.Context
29677	header_      http.Header
29678}
29679
29680// Get: Retrieves a conversation participant.
29681//
29682// - name: The name of the participant. Format:
29683//   `projects//locations//conversations//participants/`.
29684func (r *ProjectsConversationsParticipantsService) Get(name string) *ProjectsConversationsParticipantsGetCall {
29685	c := &ProjectsConversationsParticipantsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29686	c.name = name
29687	return c
29688}
29689
29690// Fields allows partial responses to be retrieved. See
29691// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29692// for more information.
29693func (c *ProjectsConversationsParticipantsGetCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsGetCall {
29694	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29695	return c
29696}
29697
29698// IfNoneMatch sets the optional parameter which makes the operation
29699// fail if the object's ETag matches the given value. This is useful for
29700// getting updates only after the object has changed since the last
29701// request. Use googleapi.IsNotModified to check whether the response
29702// error from Do is the result of In-None-Match.
29703func (c *ProjectsConversationsParticipantsGetCall) IfNoneMatch(entityTag string) *ProjectsConversationsParticipantsGetCall {
29704	c.ifNoneMatch_ = entityTag
29705	return c
29706}
29707
29708// Context sets the context to be used in this call's Do method. Any
29709// pending HTTP request will be aborted if the provided context is
29710// canceled.
29711func (c *ProjectsConversationsParticipantsGetCall) Context(ctx context.Context) *ProjectsConversationsParticipantsGetCall {
29712	c.ctx_ = ctx
29713	return c
29714}
29715
29716// Header returns an http.Header that can be modified by the caller to
29717// add HTTP headers to the request.
29718func (c *ProjectsConversationsParticipantsGetCall) Header() http.Header {
29719	if c.header_ == nil {
29720		c.header_ = make(http.Header)
29721	}
29722	return c.header_
29723}
29724
29725func (c *ProjectsConversationsParticipantsGetCall) doRequest(alt string) (*http.Response, error) {
29726	reqHeaders := make(http.Header)
29727	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
29728	for k, v := range c.header_ {
29729		reqHeaders[k] = v
29730	}
29731	reqHeaders.Set("User-Agent", c.s.userAgent())
29732	if c.ifNoneMatch_ != "" {
29733		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29734	}
29735	var body io.Reader = nil
29736	c.urlParams_.Set("alt", alt)
29737	c.urlParams_.Set("prettyPrint", "false")
29738	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
29739	urls += "?" + c.urlParams_.Encode()
29740	req, err := http.NewRequest("GET", urls, body)
29741	if err != nil {
29742		return nil, err
29743	}
29744	req.Header = reqHeaders
29745	googleapi.Expand(req.URL, map[string]string{
29746		"name": c.name,
29747	})
29748	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29749}
29750
29751// Do executes the "dialogflow.projects.conversations.participants.get" call.
29752// Exactly one of *GoogleCloudDialogflowV2Participant or error will be
29753// non-nil. Any non-2xx status code is an error. Response headers are in
29754// either *GoogleCloudDialogflowV2Participant.ServerResponse.Header or
29755// (if a response was returned at all) in
29756// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
29757// whether the returned error was because http.StatusNotModified was
29758// returned.
29759func (c *ProjectsConversationsParticipantsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Participant, error) {
29760	gensupport.SetOptions(c.urlParams_, opts...)
29761	res, err := c.doRequest("json")
29762	if res != nil && res.StatusCode == http.StatusNotModified {
29763		if res.Body != nil {
29764			res.Body.Close()
29765		}
29766		return nil, &googleapi.Error{
29767			Code:   res.StatusCode,
29768			Header: res.Header,
29769		}
29770	}
29771	if err != nil {
29772		return nil, err
29773	}
29774	defer googleapi.CloseBody(res)
29775	if err := googleapi.CheckResponse(res); err != nil {
29776		return nil, err
29777	}
29778	ret := &GoogleCloudDialogflowV2Participant{
29779		ServerResponse: googleapi.ServerResponse{
29780			Header:         res.Header,
29781			HTTPStatusCode: res.StatusCode,
29782		},
29783	}
29784	target := &ret
29785	if err := gensupport.DecodeResponse(target, res); err != nil {
29786		return nil, err
29787	}
29788	return ret, nil
29789	// {
29790	//   "description": "Retrieves a conversation participant.",
29791	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants/{participantsId}",
29792	//   "httpMethod": "GET",
29793	//   "id": "dialogflow.projects.conversations.participants.get",
29794	//   "parameterOrder": [
29795	//     "name"
29796	//   ],
29797	//   "parameters": {
29798	//     "name": {
29799	//       "description": "Required. The name of the participant. Format: `projects//locations//conversations//participants/`.",
29800	//       "location": "path",
29801	//       "pattern": "^projects/[^/]+/conversations/[^/]+/participants/[^/]+$",
29802	//       "required": true,
29803	//       "type": "string"
29804	//     }
29805	//   },
29806	//   "path": "v2/{+name}",
29807	//   "response": {
29808	//     "$ref": "GoogleCloudDialogflowV2Participant"
29809	//   },
29810	//   "scopes": [
29811	//     "https://www.googleapis.com/auth/cloud-platform",
29812	//     "https://www.googleapis.com/auth/dialogflow"
29813	//   ]
29814	// }
29815
29816}
29817
29818// method id "dialogflow.projects.conversations.participants.list":
29819
29820type ProjectsConversationsParticipantsListCall struct {
29821	s            *Service
29822	parent       string
29823	urlParams_   gensupport.URLParams
29824	ifNoneMatch_ string
29825	ctx_         context.Context
29826	header_      http.Header
29827}
29828
29829// List: Returns the list of all participants in the specified
29830// conversation.
29831//
29832// - parent: The conversation to list all participants from. Format:
29833//   `projects//locations//conversations/`.
29834func (r *ProjectsConversationsParticipantsService) List(parent string) *ProjectsConversationsParticipantsListCall {
29835	c := &ProjectsConversationsParticipantsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29836	c.parent = parent
29837	return c
29838}
29839
29840// PageSize sets the optional parameter "pageSize": The maximum number
29841// of items to return in a single page. By default 100 and at most 1000.
29842func (c *ProjectsConversationsParticipantsListCall) PageSize(pageSize int64) *ProjectsConversationsParticipantsListCall {
29843	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
29844	return c
29845}
29846
29847// PageToken sets the optional parameter "pageToken": The
29848// next_page_token value returned from a previous list request.
29849func (c *ProjectsConversationsParticipantsListCall) PageToken(pageToken string) *ProjectsConversationsParticipantsListCall {
29850	c.urlParams_.Set("pageToken", pageToken)
29851	return c
29852}
29853
29854// Fields allows partial responses to be retrieved. See
29855// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29856// for more information.
29857func (c *ProjectsConversationsParticipantsListCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsListCall {
29858	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29859	return c
29860}
29861
29862// IfNoneMatch sets the optional parameter which makes the operation
29863// fail if the object's ETag matches the given value. This is useful for
29864// getting updates only after the object has changed since the last
29865// request. Use googleapi.IsNotModified to check whether the response
29866// error from Do is the result of In-None-Match.
29867func (c *ProjectsConversationsParticipantsListCall) IfNoneMatch(entityTag string) *ProjectsConversationsParticipantsListCall {
29868	c.ifNoneMatch_ = entityTag
29869	return c
29870}
29871
29872// Context sets the context to be used in this call's Do method. Any
29873// pending HTTP request will be aborted if the provided context is
29874// canceled.
29875func (c *ProjectsConversationsParticipantsListCall) Context(ctx context.Context) *ProjectsConversationsParticipantsListCall {
29876	c.ctx_ = ctx
29877	return c
29878}
29879
29880// Header returns an http.Header that can be modified by the caller to
29881// add HTTP headers to the request.
29882func (c *ProjectsConversationsParticipantsListCall) Header() http.Header {
29883	if c.header_ == nil {
29884		c.header_ = make(http.Header)
29885	}
29886	return c.header_
29887}
29888
29889func (c *ProjectsConversationsParticipantsListCall) doRequest(alt string) (*http.Response, error) {
29890	reqHeaders := make(http.Header)
29891	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
29892	for k, v := range c.header_ {
29893		reqHeaders[k] = v
29894	}
29895	reqHeaders.Set("User-Agent", c.s.userAgent())
29896	if c.ifNoneMatch_ != "" {
29897		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29898	}
29899	var body io.Reader = nil
29900	c.urlParams_.Set("alt", alt)
29901	c.urlParams_.Set("prettyPrint", "false")
29902	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/participants")
29903	urls += "?" + c.urlParams_.Encode()
29904	req, err := http.NewRequest("GET", urls, body)
29905	if err != nil {
29906		return nil, err
29907	}
29908	req.Header = reqHeaders
29909	googleapi.Expand(req.URL, map[string]string{
29910		"parent": c.parent,
29911	})
29912	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29913}
29914
29915// Do executes the "dialogflow.projects.conversations.participants.list" call.
29916// Exactly one of *GoogleCloudDialogflowV2ListParticipantsResponse or
29917// error will be non-nil. Any non-2xx status code is an error. Response
29918// headers are in either
29919// *GoogleCloudDialogflowV2ListParticipantsResponse.ServerResponse.Header
29920//  or (if a response was returned at all) in
29921// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
29922// whether the returned error was because http.StatusNotModified was
29923// returned.
29924func (c *ProjectsConversationsParticipantsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListParticipantsResponse, error) {
29925	gensupport.SetOptions(c.urlParams_, opts...)
29926	res, err := c.doRequest("json")
29927	if res != nil && res.StatusCode == http.StatusNotModified {
29928		if res.Body != nil {
29929			res.Body.Close()
29930		}
29931		return nil, &googleapi.Error{
29932			Code:   res.StatusCode,
29933			Header: res.Header,
29934		}
29935	}
29936	if err != nil {
29937		return nil, err
29938	}
29939	defer googleapi.CloseBody(res)
29940	if err := googleapi.CheckResponse(res); err != nil {
29941		return nil, err
29942	}
29943	ret := &GoogleCloudDialogflowV2ListParticipantsResponse{
29944		ServerResponse: googleapi.ServerResponse{
29945			Header:         res.Header,
29946			HTTPStatusCode: res.StatusCode,
29947		},
29948	}
29949	target := &ret
29950	if err := gensupport.DecodeResponse(target, res); err != nil {
29951		return nil, err
29952	}
29953	return ret, nil
29954	// {
29955	//   "description": "Returns the list of all participants in the specified conversation.",
29956	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants",
29957	//   "httpMethod": "GET",
29958	//   "id": "dialogflow.projects.conversations.participants.list",
29959	//   "parameterOrder": [
29960	//     "parent"
29961	//   ],
29962	//   "parameters": {
29963	//     "pageSize": {
29964	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
29965	//       "format": "int32",
29966	//       "location": "query",
29967	//       "type": "integer"
29968	//     },
29969	//     "pageToken": {
29970	//       "description": "Optional. The next_page_token value returned from a previous list request.",
29971	//       "location": "query",
29972	//       "type": "string"
29973	//     },
29974	//     "parent": {
29975	//       "description": "Required. The conversation to list all participants from. Format: `projects//locations//conversations/`.",
29976	//       "location": "path",
29977	//       "pattern": "^projects/[^/]+/conversations/[^/]+$",
29978	//       "required": true,
29979	//       "type": "string"
29980	//     }
29981	//   },
29982	//   "path": "v2/{+parent}/participants",
29983	//   "response": {
29984	//     "$ref": "GoogleCloudDialogflowV2ListParticipantsResponse"
29985	//   },
29986	//   "scopes": [
29987	//     "https://www.googleapis.com/auth/cloud-platform",
29988	//     "https://www.googleapis.com/auth/dialogflow"
29989	//   ]
29990	// }
29991
29992}
29993
29994// Pages invokes f for each page of results.
29995// A non-nil error returned from f will halt the iteration.
29996// The provided context supersedes any context provided to the Context method.
29997func (c *ProjectsConversationsParticipantsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListParticipantsResponse) error) error {
29998	c.ctx_ = ctx
29999	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
30000	for {
30001		x, err := c.Do()
30002		if err != nil {
30003			return err
30004		}
30005		if err := f(x); err != nil {
30006			return err
30007		}
30008		if x.NextPageToken == "" {
30009			return nil
30010		}
30011		c.PageToken(x.NextPageToken)
30012	}
30013}
30014
30015// method id "dialogflow.projects.conversations.participants.patch":
30016
30017type ProjectsConversationsParticipantsPatchCall struct {
30018	s                                  *Service
30019	nameid                             string
30020	googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant
30021	urlParams_                         gensupport.URLParams
30022	ctx_                               context.Context
30023	header_                            http.Header
30024}
30025
30026// Patch: Updates the specified participant.
30027//
30028// - name: Optional. The unique identifier of this participant. Format:
30029//   `projects//locations//conversations//participants/`.
30030func (r *ProjectsConversationsParticipantsService) Patch(nameid string, googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant) *ProjectsConversationsParticipantsPatchCall {
30031	c := &ProjectsConversationsParticipantsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30032	c.nameid = nameid
30033	c.googleclouddialogflowv2participant = googleclouddialogflowv2participant
30034	return c
30035}
30036
30037// UpdateMask sets the optional parameter "updateMask": Required. The
30038// mask to specify which fields to update.
30039func (c *ProjectsConversationsParticipantsPatchCall) UpdateMask(updateMask string) *ProjectsConversationsParticipantsPatchCall {
30040	c.urlParams_.Set("updateMask", updateMask)
30041	return c
30042}
30043
30044// Fields allows partial responses to be retrieved. See
30045// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30046// for more information.
30047func (c *ProjectsConversationsParticipantsPatchCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsPatchCall {
30048	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30049	return c
30050}
30051
30052// Context sets the context to be used in this call's Do method. Any
30053// pending HTTP request will be aborted if the provided context is
30054// canceled.
30055func (c *ProjectsConversationsParticipantsPatchCall) Context(ctx context.Context) *ProjectsConversationsParticipantsPatchCall {
30056	c.ctx_ = ctx
30057	return c
30058}
30059
30060// Header returns an http.Header that can be modified by the caller to
30061// add HTTP headers to the request.
30062func (c *ProjectsConversationsParticipantsPatchCall) Header() http.Header {
30063	if c.header_ == nil {
30064		c.header_ = make(http.Header)
30065	}
30066	return c.header_
30067}
30068
30069func (c *ProjectsConversationsParticipantsPatchCall) doRequest(alt string) (*http.Response, error) {
30070	reqHeaders := make(http.Header)
30071	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
30072	for k, v := range c.header_ {
30073		reqHeaders[k] = v
30074	}
30075	reqHeaders.Set("User-Agent", c.s.userAgent())
30076	var body io.Reader = nil
30077	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2participant)
30078	if err != nil {
30079		return nil, err
30080	}
30081	reqHeaders.Set("Content-Type", "application/json")
30082	c.urlParams_.Set("alt", alt)
30083	c.urlParams_.Set("prettyPrint", "false")
30084	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
30085	urls += "?" + c.urlParams_.Encode()
30086	req, err := http.NewRequest("PATCH", urls, body)
30087	if err != nil {
30088		return nil, err
30089	}
30090	req.Header = reqHeaders
30091	googleapi.Expand(req.URL, map[string]string{
30092		"name": c.nameid,
30093	})
30094	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30095}
30096
30097// Do executes the "dialogflow.projects.conversations.participants.patch" call.
30098// Exactly one of *GoogleCloudDialogflowV2Participant or error will be
30099// non-nil. Any non-2xx status code is an error. Response headers are in
30100// either *GoogleCloudDialogflowV2Participant.ServerResponse.Header or
30101// (if a response was returned at all) in
30102// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
30103// whether the returned error was because http.StatusNotModified was
30104// returned.
30105func (c *ProjectsConversationsParticipantsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Participant, error) {
30106	gensupport.SetOptions(c.urlParams_, opts...)
30107	res, err := c.doRequest("json")
30108	if res != nil && res.StatusCode == http.StatusNotModified {
30109		if res.Body != nil {
30110			res.Body.Close()
30111		}
30112		return nil, &googleapi.Error{
30113			Code:   res.StatusCode,
30114			Header: res.Header,
30115		}
30116	}
30117	if err != nil {
30118		return nil, err
30119	}
30120	defer googleapi.CloseBody(res)
30121	if err := googleapi.CheckResponse(res); err != nil {
30122		return nil, err
30123	}
30124	ret := &GoogleCloudDialogflowV2Participant{
30125		ServerResponse: googleapi.ServerResponse{
30126			Header:         res.Header,
30127			HTTPStatusCode: res.StatusCode,
30128		},
30129	}
30130	target := &ret
30131	if err := gensupport.DecodeResponse(target, res); err != nil {
30132		return nil, err
30133	}
30134	return ret, nil
30135	// {
30136	//   "description": "Updates the specified participant.",
30137	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants/{participantsId}",
30138	//   "httpMethod": "PATCH",
30139	//   "id": "dialogflow.projects.conversations.participants.patch",
30140	//   "parameterOrder": [
30141	//     "name"
30142	//   ],
30143	//   "parameters": {
30144	//     "name": {
30145	//       "description": "Optional. The unique identifier of this participant. Format: `projects//locations//conversations//participants/`.",
30146	//       "location": "path",
30147	//       "pattern": "^projects/[^/]+/conversations/[^/]+/participants/[^/]+$",
30148	//       "required": true,
30149	//       "type": "string"
30150	//     },
30151	//     "updateMask": {
30152	//       "description": "Required. The mask to specify which fields to update.",
30153	//       "format": "google-fieldmask",
30154	//       "location": "query",
30155	//       "type": "string"
30156	//     }
30157	//   },
30158	//   "path": "v2/{+name}",
30159	//   "request": {
30160	//     "$ref": "GoogleCloudDialogflowV2Participant"
30161	//   },
30162	//   "response": {
30163	//     "$ref": "GoogleCloudDialogflowV2Participant"
30164	//   },
30165	//   "scopes": [
30166	//     "https://www.googleapis.com/auth/cloud-platform",
30167	//     "https://www.googleapis.com/auth/dialogflow"
30168	//   ]
30169	// }
30170
30171}
30172
30173// method id "dialogflow.projects.conversations.participants.suggestions.suggestArticles":
30174
30175type ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall struct {
30176	s                                             *Service
30177	parent                                        string
30178	googleclouddialogflowv2suggestarticlesrequest *GoogleCloudDialogflowV2SuggestArticlesRequest
30179	urlParams_                                    gensupport.URLParams
30180	ctx_                                          context.Context
30181	header_                                       http.Header
30182}
30183
30184// SuggestArticles: Gets suggested articles for a participant based on
30185// specific historical messages.
30186//
30187// - parent: The name of the participant to fetch suggestion for.
30188//   Format: `projects//locations//conversations//participants/`.
30189func (r *ProjectsConversationsParticipantsSuggestionsService) SuggestArticles(parent string, googleclouddialogflowv2suggestarticlesrequest *GoogleCloudDialogflowV2SuggestArticlesRequest) *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall {
30190	c := &ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30191	c.parent = parent
30192	c.googleclouddialogflowv2suggestarticlesrequest = googleclouddialogflowv2suggestarticlesrequest
30193	return c
30194}
30195
30196// Fields allows partial responses to be retrieved. See
30197// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30198// for more information.
30199func (c *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall {
30200	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30201	return c
30202}
30203
30204// Context sets the context to be used in this call's Do method. Any
30205// pending HTTP request will be aborted if the provided context is
30206// canceled.
30207func (c *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall) Context(ctx context.Context) *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall {
30208	c.ctx_ = ctx
30209	return c
30210}
30211
30212// Header returns an http.Header that can be modified by the caller to
30213// add HTTP headers to the request.
30214func (c *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall) Header() http.Header {
30215	if c.header_ == nil {
30216		c.header_ = make(http.Header)
30217	}
30218	return c.header_
30219}
30220
30221func (c *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall) doRequest(alt string) (*http.Response, error) {
30222	reqHeaders := make(http.Header)
30223	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
30224	for k, v := range c.header_ {
30225		reqHeaders[k] = v
30226	}
30227	reqHeaders.Set("User-Agent", c.s.userAgent())
30228	var body io.Reader = nil
30229	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2suggestarticlesrequest)
30230	if err != nil {
30231		return nil, err
30232	}
30233	reqHeaders.Set("Content-Type", "application/json")
30234	c.urlParams_.Set("alt", alt)
30235	c.urlParams_.Set("prettyPrint", "false")
30236	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/suggestions:suggestArticles")
30237	urls += "?" + c.urlParams_.Encode()
30238	req, err := http.NewRequest("POST", urls, body)
30239	if err != nil {
30240		return nil, err
30241	}
30242	req.Header = reqHeaders
30243	googleapi.Expand(req.URL, map[string]string{
30244		"parent": c.parent,
30245	})
30246	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30247}
30248
30249// Do executes the "dialogflow.projects.conversations.participants.suggestions.suggestArticles" call.
30250// Exactly one of *GoogleCloudDialogflowV2SuggestArticlesResponse or
30251// error will be non-nil. Any non-2xx status code is an error. Response
30252// headers are in either
30253// *GoogleCloudDialogflowV2SuggestArticlesResponse.ServerResponse.Header
30254// or (if a response was returned at all) in
30255// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
30256// whether the returned error was because http.StatusNotModified was
30257// returned.
30258func (c *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SuggestArticlesResponse, error) {
30259	gensupport.SetOptions(c.urlParams_, opts...)
30260	res, err := c.doRequest("json")
30261	if res != nil && res.StatusCode == http.StatusNotModified {
30262		if res.Body != nil {
30263			res.Body.Close()
30264		}
30265		return nil, &googleapi.Error{
30266			Code:   res.StatusCode,
30267			Header: res.Header,
30268		}
30269	}
30270	if err != nil {
30271		return nil, err
30272	}
30273	defer googleapi.CloseBody(res)
30274	if err := googleapi.CheckResponse(res); err != nil {
30275		return nil, err
30276	}
30277	ret := &GoogleCloudDialogflowV2SuggestArticlesResponse{
30278		ServerResponse: googleapi.ServerResponse{
30279			Header:         res.Header,
30280			HTTPStatusCode: res.StatusCode,
30281		},
30282	}
30283	target := &ret
30284	if err := gensupport.DecodeResponse(target, res); err != nil {
30285		return nil, err
30286	}
30287	return ret, nil
30288	// {
30289	//   "description": "Gets suggested articles for a participant based on specific historical messages.",
30290	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants/{participantsId}/suggestions:suggestArticles",
30291	//   "httpMethod": "POST",
30292	//   "id": "dialogflow.projects.conversations.participants.suggestions.suggestArticles",
30293	//   "parameterOrder": [
30294	//     "parent"
30295	//   ],
30296	//   "parameters": {
30297	//     "parent": {
30298	//       "description": "Required. The name of the participant to fetch suggestion for. Format: `projects//locations//conversations//participants/`.",
30299	//       "location": "path",
30300	//       "pattern": "^projects/[^/]+/conversations/[^/]+/participants/[^/]+$",
30301	//       "required": true,
30302	//       "type": "string"
30303	//     }
30304	//   },
30305	//   "path": "v2/{+parent}/suggestions:suggestArticles",
30306	//   "request": {
30307	//     "$ref": "GoogleCloudDialogflowV2SuggestArticlesRequest"
30308	//   },
30309	//   "response": {
30310	//     "$ref": "GoogleCloudDialogflowV2SuggestArticlesResponse"
30311	//   },
30312	//   "scopes": [
30313	//     "https://www.googleapis.com/auth/cloud-platform",
30314	//     "https://www.googleapis.com/auth/dialogflow"
30315	//   ]
30316	// }
30317
30318}
30319
30320// method id "dialogflow.projects.conversations.participants.suggestions.suggestFaqAnswers":
30321
30322type ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall struct {
30323	s                                               *Service
30324	parent                                          string
30325	googleclouddialogflowv2suggestfaqanswersrequest *GoogleCloudDialogflowV2SuggestFaqAnswersRequest
30326	urlParams_                                      gensupport.URLParams
30327	ctx_                                            context.Context
30328	header_                                         http.Header
30329}
30330
30331// SuggestFaqAnswers: Gets suggested faq answers for a participant based
30332// on specific historical messages.
30333//
30334// - parent: The name of the participant to fetch suggestion for.
30335//   Format: `projects//locations//conversations//participants/`.
30336func (r *ProjectsConversationsParticipantsSuggestionsService) SuggestFaqAnswers(parent string, googleclouddialogflowv2suggestfaqanswersrequest *GoogleCloudDialogflowV2SuggestFaqAnswersRequest) *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall {
30337	c := &ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30338	c.parent = parent
30339	c.googleclouddialogflowv2suggestfaqanswersrequest = googleclouddialogflowv2suggestfaqanswersrequest
30340	return c
30341}
30342
30343// Fields allows partial responses to be retrieved. See
30344// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30345// for more information.
30346func (c *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall {
30347	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30348	return c
30349}
30350
30351// Context sets the context to be used in this call's Do method. Any
30352// pending HTTP request will be aborted if the provided context is
30353// canceled.
30354func (c *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Context(ctx context.Context) *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall {
30355	c.ctx_ = ctx
30356	return c
30357}
30358
30359// Header returns an http.Header that can be modified by the caller to
30360// add HTTP headers to the request.
30361func (c *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Header() http.Header {
30362	if c.header_ == nil {
30363		c.header_ = make(http.Header)
30364	}
30365	return c.header_
30366}
30367
30368func (c *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) doRequest(alt string) (*http.Response, error) {
30369	reqHeaders := make(http.Header)
30370	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
30371	for k, v := range c.header_ {
30372		reqHeaders[k] = v
30373	}
30374	reqHeaders.Set("User-Agent", c.s.userAgent())
30375	var body io.Reader = nil
30376	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2suggestfaqanswersrequest)
30377	if err != nil {
30378		return nil, err
30379	}
30380	reqHeaders.Set("Content-Type", "application/json")
30381	c.urlParams_.Set("alt", alt)
30382	c.urlParams_.Set("prettyPrint", "false")
30383	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/suggestions:suggestFaqAnswers")
30384	urls += "?" + c.urlParams_.Encode()
30385	req, err := http.NewRequest("POST", urls, body)
30386	if err != nil {
30387		return nil, err
30388	}
30389	req.Header = reqHeaders
30390	googleapi.Expand(req.URL, map[string]string{
30391		"parent": c.parent,
30392	})
30393	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30394}
30395
30396// Do executes the "dialogflow.projects.conversations.participants.suggestions.suggestFaqAnswers" call.
30397// Exactly one of *GoogleCloudDialogflowV2SuggestFaqAnswersResponse or
30398// error will be non-nil. Any non-2xx status code is an error. Response
30399// headers are in either
30400// *GoogleCloudDialogflowV2SuggestFaqAnswersResponse.ServerResponse.Heade
30401// r or (if a response was returned at all) in
30402// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
30403// whether the returned error was because http.StatusNotModified was
30404// returned.
30405func (c *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SuggestFaqAnswersResponse, error) {
30406	gensupport.SetOptions(c.urlParams_, opts...)
30407	res, err := c.doRequest("json")
30408	if res != nil && res.StatusCode == http.StatusNotModified {
30409		if res.Body != nil {
30410			res.Body.Close()
30411		}
30412		return nil, &googleapi.Error{
30413			Code:   res.StatusCode,
30414			Header: res.Header,
30415		}
30416	}
30417	if err != nil {
30418		return nil, err
30419	}
30420	defer googleapi.CloseBody(res)
30421	if err := googleapi.CheckResponse(res); err != nil {
30422		return nil, err
30423	}
30424	ret := &GoogleCloudDialogflowV2SuggestFaqAnswersResponse{
30425		ServerResponse: googleapi.ServerResponse{
30426			Header:         res.Header,
30427			HTTPStatusCode: res.StatusCode,
30428		},
30429	}
30430	target := &ret
30431	if err := gensupport.DecodeResponse(target, res); err != nil {
30432		return nil, err
30433	}
30434	return ret, nil
30435	// {
30436	//   "description": "Gets suggested faq answers for a participant based on specific historical messages.",
30437	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants/{participantsId}/suggestions:suggestFaqAnswers",
30438	//   "httpMethod": "POST",
30439	//   "id": "dialogflow.projects.conversations.participants.suggestions.suggestFaqAnswers",
30440	//   "parameterOrder": [
30441	//     "parent"
30442	//   ],
30443	//   "parameters": {
30444	//     "parent": {
30445	//       "description": "Required. The name of the participant to fetch suggestion for. Format: `projects//locations//conversations//participants/`.",
30446	//       "location": "path",
30447	//       "pattern": "^projects/[^/]+/conversations/[^/]+/participants/[^/]+$",
30448	//       "required": true,
30449	//       "type": "string"
30450	//     }
30451	//   },
30452	//   "path": "v2/{+parent}/suggestions:suggestFaqAnswers",
30453	//   "request": {
30454	//     "$ref": "GoogleCloudDialogflowV2SuggestFaqAnswersRequest"
30455	//   },
30456	//   "response": {
30457	//     "$ref": "GoogleCloudDialogflowV2SuggestFaqAnswersResponse"
30458	//   },
30459	//   "scopes": [
30460	//     "https://www.googleapis.com/auth/cloud-platform",
30461	//     "https://www.googleapis.com/auth/dialogflow"
30462	//   ]
30463	// }
30464
30465}
30466
30467// method id "dialogflow.projects.knowledgeBases.create":
30468
30469type ProjectsKnowledgeBasesCreateCall struct {
30470	s                                    *Service
30471	parent                               string
30472	googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase
30473	urlParams_                           gensupport.URLParams
30474	ctx_                                 context.Context
30475	header_                              http.Header
30476}
30477
30478// Create: Creates a knowledge base.
30479//
30480// - parent: The project to create a knowledge base for. Format:
30481//   `projects//locations/`.
30482func (r *ProjectsKnowledgeBasesService) Create(parent string, googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase) *ProjectsKnowledgeBasesCreateCall {
30483	c := &ProjectsKnowledgeBasesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30484	c.parent = parent
30485	c.googleclouddialogflowv2knowledgebase = googleclouddialogflowv2knowledgebase
30486	return c
30487}
30488
30489// Fields allows partial responses to be retrieved. See
30490// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30491// for more information.
30492func (c *ProjectsKnowledgeBasesCreateCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesCreateCall {
30493	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30494	return c
30495}
30496
30497// Context sets the context to be used in this call's Do method. Any
30498// pending HTTP request will be aborted if the provided context is
30499// canceled.
30500func (c *ProjectsKnowledgeBasesCreateCall) Context(ctx context.Context) *ProjectsKnowledgeBasesCreateCall {
30501	c.ctx_ = ctx
30502	return c
30503}
30504
30505// Header returns an http.Header that can be modified by the caller to
30506// add HTTP headers to the request.
30507func (c *ProjectsKnowledgeBasesCreateCall) Header() http.Header {
30508	if c.header_ == nil {
30509		c.header_ = make(http.Header)
30510	}
30511	return c.header_
30512}
30513
30514func (c *ProjectsKnowledgeBasesCreateCall) doRequest(alt string) (*http.Response, error) {
30515	reqHeaders := make(http.Header)
30516	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
30517	for k, v := range c.header_ {
30518		reqHeaders[k] = v
30519	}
30520	reqHeaders.Set("User-Agent", c.s.userAgent())
30521	var body io.Reader = nil
30522	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2knowledgebase)
30523	if err != nil {
30524		return nil, err
30525	}
30526	reqHeaders.Set("Content-Type", "application/json")
30527	c.urlParams_.Set("alt", alt)
30528	c.urlParams_.Set("prettyPrint", "false")
30529	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/knowledgeBases")
30530	urls += "?" + c.urlParams_.Encode()
30531	req, err := http.NewRequest("POST", urls, body)
30532	if err != nil {
30533		return nil, err
30534	}
30535	req.Header = reqHeaders
30536	googleapi.Expand(req.URL, map[string]string{
30537		"parent": c.parent,
30538	})
30539	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30540}
30541
30542// Do executes the "dialogflow.projects.knowledgeBases.create" call.
30543// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
30544// non-nil. Any non-2xx status code is an error. Response headers are in
30545// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
30546// (if a response was returned at all) in
30547// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
30548// whether the returned error was because http.StatusNotModified was
30549// returned.
30550func (c *ProjectsKnowledgeBasesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
30551	gensupport.SetOptions(c.urlParams_, opts...)
30552	res, err := c.doRequest("json")
30553	if res != nil && res.StatusCode == http.StatusNotModified {
30554		if res.Body != nil {
30555			res.Body.Close()
30556		}
30557		return nil, &googleapi.Error{
30558			Code:   res.StatusCode,
30559			Header: res.Header,
30560		}
30561	}
30562	if err != nil {
30563		return nil, err
30564	}
30565	defer googleapi.CloseBody(res)
30566	if err := googleapi.CheckResponse(res); err != nil {
30567		return nil, err
30568	}
30569	ret := &GoogleCloudDialogflowV2KnowledgeBase{
30570		ServerResponse: googleapi.ServerResponse{
30571			Header:         res.Header,
30572			HTTPStatusCode: res.StatusCode,
30573		},
30574	}
30575	target := &ret
30576	if err := gensupport.DecodeResponse(target, res); err != nil {
30577		return nil, err
30578	}
30579	return ret, nil
30580	// {
30581	//   "description": "Creates a knowledge base.",
30582	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases",
30583	//   "httpMethod": "POST",
30584	//   "id": "dialogflow.projects.knowledgeBases.create",
30585	//   "parameterOrder": [
30586	//     "parent"
30587	//   ],
30588	//   "parameters": {
30589	//     "parent": {
30590	//       "description": "Required. The project to create a knowledge base for. Format: `projects//locations/`.",
30591	//       "location": "path",
30592	//       "pattern": "^projects/[^/]+$",
30593	//       "required": true,
30594	//       "type": "string"
30595	//     }
30596	//   },
30597	//   "path": "v2/{+parent}/knowledgeBases",
30598	//   "request": {
30599	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
30600	//   },
30601	//   "response": {
30602	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
30603	//   },
30604	//   "scopes": [
30605	//     "https://www.googleapis.com/auth/cloud-platform",
30606	//     "https://www.googleapis.com/auth/dialogflow"
30607	//   ]
30608	// }
30609
30610}
30611
30612// method id "dialogflow.projects.knowledgeBases.delete":
30613
30614type ProjectsKnowledgeBasesDeleteCall struct {
30615	s          *Service
30616	name       string
30617	urlParams_ gensupport.URLParams
30618	ctx_       context.Context
30619	header_    http.Header
30620}
30621
30622// Delete: Deletes the specified knowledge base.
30623//
30624// - name: The name of the knowledge base to delete. Format:
30625//   `projects//locations//knowledgeBases/`.
30626func (r *ProjectsKnowledgeBasesService) Delete(name string) *ProjectsKnowledgeBasesDeleteCall {
30627	c := &ProjectsKnowledgeBasesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30628	c.name = name
30629	return c
30630}
30631
30632// Force sets the optional parameter "force": Force deletes the
30633// knowledge base. When set to true, any documents in the knowledge base
30634// are also deleted.
30635func (c *ProjectsKnowledgeBasesDeleteCall) Force(force bool) *ProjectsKnowledgeBasesDeleteCall {
30636	c.urlParams_.Set("force", fmt.Sprint(force))
30637	return c
30638}
30639
30640// Fields allows partial responses to be retrieved. See
30641// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30642// for more information.
30643func (c *ProjectsKnowledgeBasesDeleteCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDeleteCall {
30644	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30645	return c
30646}
30647
30648// Context sets the context to be used in this call's Do method. Any
30649// pending HTTP request will be aborted if the provided context is
30650// canceled.
30651func (c *ProjectsKnowledgeBasesDeleteCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDeleteCall {
30652	c.ctx_ = ctx
30653	return c
30654}
30655
30656// Header returns an http.Header that can be modified by the caller to
30657// add HTTP headers to the request.
30658func (c *ProjectsKnowledgeBasesDeleteCall) Header() http.Header {
30659	if c.header_ == nil {
30660		c.header_ = make(http.Header)
30661	}
30662	return c.header_
30663}
30664
30665func (c *ProjectsKnowledgeBasesDeleteCall) doRequest(alt string) (*http.Response, error) {
30666	reqHeaders := make(http.Header)
30667	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
30668	for k, v := range c.header_ {
30669		reqHeaders[k] = v
30670	}
30671	reqHeaders.Set("User-Agent", c.s.userAgent())
30672	var body io.Reader = nil
30673	c.urlParams_.Set("alt", alt)
30674	c.urlParams_.Set("prettyPrint", "false")
30675	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
30676	urls += "?" + c.urlParams_.Encode()
30677	req, err := http.NewRequest("DELETE", urls, body)
30678	if err != nil {
30679		return nil, err
30680	}
30681	req.Header = reqHeaders
30682	googleapi.Expand(req.URL, map[string]string{
30683		"name": c.name,
30684	})
30685	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30686}
30687
30688// Do executes the "dialogflow.projects.knowledgeBases.delete" call.
30689// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
30690// non-2xx status code is an error. Response headers are in either
30691// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
30692// returned at all) in error.(*googleapi.Error).Header. Use
30693// googleapi.IsNotModified to check whether the returned error was
30694// because http.StatusNotModified was returned.
30695func (c *ProjectsKnowledgeBasesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
30696	gensupport.SetOptions(c.urlParams_, opts...)
30697	res, err := c.doRequest("json")
30698	if res != nil && res.StatusCode == http.StatusNotModified {
30699		if res.Body != nil {
30700			res.Body.Close()
30701		}
30702		return nil, &googleapi.Error{
30703			Code:   res.StatusCode,
30704			Header: res.Header,
30705		}
30706	}
30707	if err != nil {
30708		return nil, err
30709	}
30710	defer googleapi.CloseBody(res)
30711	if err := googleapi.CheckResponse(res); err != nil {
30712		return nil, err
30713	}
30714	ret := &GoogleProtobufEmpty{
30715		ServerResponse: googleapi.ServerResponse{
30716			Header:         res.Header,
30717			HTTPStatusCode: res.StatusCode,
30718		},
30719	}
30720	target := &ret
30721	if err := gensupport.DecodeResponse(target, res); err != nil {
30722		return nil, err
30723	}
30724	return ret, nil
30725	// {
30726	//   "description": "Deletes the specified knowledge base.",
30727	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}",
30728	//   "httpMethod": "DELETE",
30729	//   "id": "dialogflow.projects.knowledgeBases.delete",
30730	//   "parameterOrder": [
30731	//     "name"
30732	//   ],
30733	//   "parameters": {
30734	//     "force": {
30735	//       "description": "Optional. Force deletes the knowledge base. When set to true, any documents in the knowledge base are also deleted.",
30736	//       "location": "query",
30737	//       "type": "boolean"
30738	//     },
30739	//     "name": {
30740	//       "description": "Required. The name of the knowledge base to delete. Format: `projects//locations//knowledgeBases/`.",
30741	//       "location": "path",
30742	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+$",
30743	//       "required": true,
30744	//       "type": "string"
30745	//     }
30746	//   },
30747	//   "path": "v2/{+name}",
30748	//   "response": {
30749	//     "$ref": "GoogleProtobufEmpty"
30750	//   },
30751	//   "scopes": [
30752	//     "https://www.googleapis.com/auth/cloud-platform",
30753	//     "https://www.googleapis.com/auth/dialogflow"
30754	//   ]
30755	// }
30756
30757}
30758
30759// method id "dialogflow.projects.knowledgeBases.get":
30760
30761type ProjectsKnowledgeBasesGetCall struct {
30762	s            *Service
30763	name         string
30764	urlParams_   gensupport.URLParams
30765	ifNoneMatch_ string
30766	ctx_         context.Context
30767	header_      http.Header
30768}
30769
30770// Get: Retrieves the specified knowledge base.
30771//
30772// - name: The name of the knowledge base to retrieve. Format
30773//   `projects//locations//knowledgeBases/`.
30774func (r *ProjectsKnowledgeBasesService) Get(name string) *ProjectsKnowledgeBasesGetCall {
30775	c := &ProjectsKnowledgeBasesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30776	c.name = name
30777	return c
30778}
30779
30780// Fields allows partial responses to be retrieved. See
30781// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30782// for more information.
30783func (c *ProjectsKnowledgeBasesGetCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesGetCall {
30784	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30785	return c
30786}
30787
30788// IfNoneMatch sets the optional parameter which makes the operation
30789// fail if the object's ETag matches the given value. This is useful for
30790// getting updates only after the object has changed since the last
30791// request. Use googleapi.IsNotModified to check whether the response
30792// error from Do is the result of In-None-Match.
30793func (c *ProjectsKnowledgeBasesGetCall) IfNoneMatch(entityTag string) *ProjectsKnowledgeBasesGetCall {
30794	c.ifNoneMatch_ = entityTag
30795	return c
30796}
30797
30798// Context sets the context to be used in this call's Do method. Any
30799// pending HTTP request will be aborted if the provided context is
30800// canceled.
30801func (c *ProjectsKnowledgeBasesGetCall) Context(ctx context.Context) *ProjectsKnowledgeBasesGetCall {
30802	c.ctx_ = ctx
30803	return c
30804}
30805
30806// Header returns an http.Header that can be modified by the caller to
30807// add HTTP headers to the request.
30808func (c *ProjectsKnowledgeBasesGetCall) Header() http.Header {
30809	if c.header_ == nil {
30810		c.header_ = make(http.Header)
30811	}
30812	return c.header_
30813}
30814
30815func (c *ProjectsKnowledgeBasesGetCall) doRequest(alt string) (*http.Response, error) {
30816	reqHeaders := make(http.Header)
30817	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
30818	for k, v := range c.header_ {
30819		reqHeaders[k] = v
30820	}
30821	reqHeaders.Set("User-Agent", c.s.userAgent())
30822	if c.ifNoneMatch_ != "" {
30823		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30824	}
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("GET", 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.knowledgeBases.get" call.
30842// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
30843// non-nil. Any non-2xx status code is an error. Response headers are in
30844// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
30845// (if a response was returned at all) in
30846// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
30847// whether the returned error was because http.StatusNotModified was
30848// returned.
30849func (c *ProjectsKnowledgeBasesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
30850	gensupport.SetOptions(c.urlParams_, opts...)
30851	res, err := c.doRequest("json")
30852	if res != nil && res.StatusCode == http.StatusNotModified {
30853		if res.Body != nil {
30854			res.Body.Close()
30855		}
30856		return nil, &googleapi.Error{
30857			Code:   res.StatusCode,
30858			Header: res.Header,
30859		}
30860	}
30861	if err != nil {
30862		return nil, err
30863	}
30864	defer googleapi.CloseBody(res)
30865	if err := googleapi.CheckResponse(res); err != nil {
30866		return nil, err
30867	}
30868	ret := &GoogleCloudDialogflowV2KnowledgeBase{
30869		ServerResponse: googleapi.ServerResponse{
30870			Header:         res.Header,
30871			HTTPStatusCode: res.StatusCode,
30872		},
30873	}
30874	target := &ret
30875	if err := gensupport.DecodeResponse(target, res); err != nil {
30876		return nil, err
30877	}
30878	return ret, nil
30879	// {
30880	//   "description": "Retrieves the specified knowledge base.",
30881	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}",
30882	//   "httpMethod": "GET",
30883	//   "id": "dialogflow.projects.knowledgeBases.get",
30884	//   "parameterOrder": [
30885	//     "name"
30886	//   ],
30887	//   "parameters": {
30888	//     "name": {
30889	//       "description": "Required. The name of the knowledge base to retrieve. Format `projects//locations//knowledgeBases/`.",
30890	//       "location": "path",
30891	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+$",
30892	//       "required": true,
30893	//       "type": "string"
30894	//     }
30895	//   },
30896	//   "path": "v2/{+name}",
30897	//   "response": {
30898	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
30899	//   },
30900	//   "scopes": [
30901	//     "https://www.googleapis.com/auth/cloud-platform",
30902	//     "https://www.googleapis.com/auth/dialogflow"
30903	//   ]
30904	// }
30905
30906}
30907
30908// method id "dialogflow.projects.knowledgeBases.list":
30909
30910type ProjectsKnowledgeBasesListCall struct {
30911	s            *Service
30912	parent       string
30913	urlParams_   gensupport.URLParams
30914	ifNoneMatch_ string
30915	ctx_         context.Context
30916	header_      http.Header
30917}
30918
30919// List: Returns the list of all knowledge bases of the specified agent.
30920//
30921// - parent: The project to list of knowledge bases for. Format:
30922//   `projects//locations/`.
30923func (r *ProjectsKnowledgeBasesService) List(parent string) *ProjectsKnowledgeBasesListCall {
30924	c := &ProjectsKnowledgeBasesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30925	c.parent = parent
30926	return c
30927}
30928
30929// PageSize sets the optional parameter "pageSize": The maximum number
30930// of items to return in a single page. By default 10 and at most 100.
30931func (c *ProjectsKnowledgeBasesListCall) PageSize(pageSize int64) *ProjectsKnowledgeBasesListCall {
30932	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
30933	return c
30934}
30935
30936// PageToken sets the optional parameter "pageToken": The
30937// next_page_token value returned from a previous list request.
30938func (c *ProjectsKnowledgeBasesListCall) PageToken(pageToken string) *ProjectsKnowledgeBasesListCall {
30939	c.urlParams_.Set("pageToken", pageToken)
30940	return c
30941}
30942
30943// Fields allows partial responses to be retrieved. See
30944// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30945// for more information.
30946func (c *ProjectsKnowledgeBasesListCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesListCall {
30947	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30948	return c
30949}
30950
30951// IfNoneMatch sets the optional parameter which makes the operation
30952// fail if the object's ETag matches the given value. This is useful for
30953// getting updates only after the object has changed since the last
30954// request. Use googleapi.IsNotModified to check whether the response
30955// error from Do is the result of In-None-Match.
30956func (c *ProjectsKnowledgeBasesListCall) IfNoneMatch(entityTag string) *ProjectsKnowledgeBasesListCall {
30957	c.ifNoneMatch_ = entityTag
30958	return c
30959}
30960
30961// Context sets the context to be used in this call's Do method. Any
30962// pending HTTP request will be aborted if the provided context is
30963// canceled.
30964func (c *ProjectsKnowledgeBasesListCall) Context(ctx context.Context) *ProjectsKnowledgeBasesListCall {
30965	c.ctx_ = ctx
30966	return c
30967}
30968
30969// Header returns an http.Header that can be modified by the caller to
30970// add HTTP headers to the request.
30971func (c *ProjectsKnowledgeBasesListCall) Header() http.Header {
30972	if c.header_ == nil {
30973		c.header_ = make(http.Header)
30974	}
30975	return c.header_
30976}
30977
30978func (c *ProjectsKnowledgeBasesListCall) doRequest(alt string) (*http.Response, error) {
30979	reqHeaders := make(http.Header)
30980	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
30981	for k, v := range c.header_ {
30982		reqHeaders[k] = v
30983	}
30984	reqHeaders.Set("User-Agent", c.s.userAgent())
30985	if c.ifNoneMatch_ != "" {
30986		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30987	}
30988	var body io.Reader = nil
30989	c.urlParams_.Set("alt", alt)
30990	c.urlParams_.Set("prettyPrint", "false")
30991	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/knowledgeBases")
30992	urls += "?" + c.urlParams_.Encode()
30993	req, err := http.NewRequest("GET", urls, body)
30994	if err != nil {
30995		return nil, err
30996	}
30997	req.Header = reqHeaders
30998	googleapi.Expand(req.URL, map[string]string{
30999		"parent": c.parent,
31000	})
31001	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31002}
31003
31004// Do executes the "dialogflow.projects.knowledgeBases.list" call.
31005// Exactly one of *GoogleCloudDialogflowV2ListKnowledgeBasesResponse or
31006// error will be non-nil. Any non-2xx status code is an error. Response
31007// headers are in either
31008// *GoogleCloudDialogflowV2ListKnowledgeBasesResponse.ServerResponse.Head
31009// er or (if a response was returned at all) in
31010// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
31011// whether the returned error was because http.StatusNotModified was
31012// returned.
31013func (c *ProjectsKnowledgeBasesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListKnowledgeBasesResponse, error) {
31014	gensupport.SetOptions(c.urlParams_, opts...)
31015	res, err := c.doRequest("json")
31016	if res != nil && res.StatusCode == http.StatusNotModified {
31017		if res.Body != nil {
31018			res.Body.Close()
31019		}
31020		return nil, &googleapi.Error{
31021			Code:   res.StatusCode,
31022			Header: res.Header,
31023		}
31024	}
31025	if err != nil {
31026		return nil, err
31027	}
31028	defer googleapi.CloseBody(res)
31029	if err := googleapi.CheckResponse(res); err != nil {
31030		return nil, err
31031	}
31032	ret := &GoogleCloudDialogflowV2ListKnowledgeBasesResponse{
31033		ServerResponse: googleapi.ServerResponse{
31034			Header:         res.Header,
31035			HTTPStatusCode: res.StatusCode,
31036		},
31037	}
31038	target := &ret
31039	if err := gensupport.DecodeResponse(target, res); err != nil {
31040		return nil, err
31041	}
31042	return ret, nil
31043	// {
31044	//   "description": "Returns the list of all knowledge bases of the specified agent.",
31045	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases",
31046	//   "httpMethod": "GET",
31047	//   "id": "dialogflow.projects.knowledgeBases.list",
31048	//   "parameterOrder": [
31049	//     "parent"
31050	//   ],
31051	//   "parameters": {
31052	//     "pageSize": {
31053	//       "description": "The maximum number of items to return in a single page. By default 10 and at most 100.",
31054	//       "format": "int32",
31055	//       "location": "query",
31056	//       "type": "integer"
31057	//     },
31058	//     "pageToken": {
31059	//       "description": "The next_page_token value returned from a previous list request.",
31060	//       "location": "query",
31061	//       "type": "string"
31062	//     },
31063	//     "parent": {
31064	//       "description": "Required. The project to list of knowledge bases for. Format: `projects//locations/`.",
31065	//       "location": "path",
31066	//       "pattern": "^projects/[^/]+$",
31067	//       "required": true,
31068	//       "type": "string"
31069	//     }
31070	//   },
31071	//   "path": "v2/{+parent}/knowledgeBases",
31072	//   "response": {
31073	//     "$ref": "GoogleCloudDialogflowV2ListKnowledgeBasesResponse"
31074	//   },
31075	//   "scopes": [
31076	//     "https://www.googleapis.com/auth/cloud-platform",
31077	//     "https://www.googleapis.com/auth/dialogflow"
31078	//   ]
31079	// }
31080
31081}
31082
31083// Pages invokes f for each page of results.
31084// A non-nil error returned from f will halt the iteration.
31085// The provided context supersedes any context provided to the Context method.
31086func (c *ProjectsKnowledgeBasesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListKnowledgeBasesResponse) error) error {
31087	c.ctx_ = ctx
31088	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
31089	for {
31090		x, err := c.Do()
31091		if err != nil {
31092			return err
31093		}
31094		if err := f(x); err != nil {
31095			return err
31096		}
31097		if x.NextPageToken == "" {
31098			return nil
31099		}
31100		c.PageToken(x.NextPageToken)
31101	}
31102}
31103
31104// method id "dialogflow.projects.knowledgeBases.patch":
31105
31106type ProjectsKnowledgeBasesPatchCall struct {
31107	s                                    *Service
31108	name                                 string
31109	googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase
31110	urlParams_                           gensupport.URLParams
31111	ctx_                                 context.Context
31112	header_                              http.Header
31113}
31114
31115// Patch: Updates the specified knowledge base.
31116//
31117// - name: The knowledge base resource name. The name must be empty when
31118//   creating a knowledge base. Format:
31119//   `projects//locations//knowledgeBases/`.
31120func (r *ProjectsKnowledgeBasesService) Patch(name string, googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase) *ProjectsKnowledgeBasesPatchCall {
31121	c := &ProjectsKnowledgeBasesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31122	c.name = name
31123	c.googleclouddialogflowv2knowledgebase = googleclouddialogflowv2knowledgebase
31124	return c
31125}
31126
31127// UpdateMask sets the optional parameter "updateMask": Not specified
31128// means `update all`. Currently, only `display_name` can be updated, an
31129// InvalidArgument will be returned for attempting to update other
31130// fields.
31131func (c *ProjectsKnowledgeBasesPatchCall) UpdateMask(updateMask string) *ProjectsKnowledgeBasesPatchCall {
31132	c.urlParams_.Set("updateMask", updateMask)
31133	return c
31134}
31135
31136// Fields allows partial responses to be retrieved. See
31137// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31138// for more information.
31139func (c *ProjectsKnowledgeBasesPatchCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesPatchCall {
31140	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31141	return c
31142}
31143
31144// Context sets the context to be used in this call's Do method. Any
31145// pending HTTP request will be aborted if the provided context is
31146// canceled.
31147func (c *ProjectsKnowledgeBasesPatchCall) Context(ctx context.Context) *ProjectsKnowledgeBasesPatchCall {
31148	c.ctx_ = ctx
31149	return c
31150}
31151
31152// Header returns an http.Header that can be modified by the caller to
31153// add HTTP headers to the request.
31154func (c *ProjectsKnowledgeBasesPatchCall) Header() http.Header {
31155	if c.header_ == nil {
31156		c.header_ = make(http.Header)
31157	}
31158	return c.header_
31159}
31160
31161func (c *ProjectsKnowledgeBasesPatchCall) doRequest(alt string) (*http.Response, error) {
31162	reqHeaders := make(http.Header)
31163	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
31164	for k, v := range c.header_ {
31165		reqHeaders[k] = v
31166	}
31167	reqHeaders.Set("User-Agent", c.s.userAgent())
31168	var body io.Reader = nil
31169	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2knowledgebase)
31170	if err != nil {
31171		return nil, err
31172	}
31173	reqHeaders.Set("Content-Type", "application/json")
31174	c.urlParams_.Set("alt", alt)
31175	c.urlParams_.Set("prettyPrint", "false")
31176	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
31177	urls += "?" + c.urlParams_.Encode()
31178	req, err := http.NewRequest("PATCH", urls, body)
31179	if err != nil {
31180		return nil, err
31181	}
31182	req.Header = reqHeaders
31183	googleapi.Expand(req.URL, map[string]string{
31184		"name": c.name,
31185	})
31186	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31187}
31188
31189// Do executes the "dialogflow.projects.knowledgeBases.patch" call.
31190// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
31191// non-nil. Any non-2xx status code is an error. Response headers are in
31192// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
31193// (if a response was returned at all) in
31194// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
31195// whether the returned error was because http.StatusNotModified was
31196// returned.
31197func (c *ProjectsKnowledgeBasesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
31198	gensupport.SetOptions(c.urlParams_, opts...)
31199	res, err := c.doRequest("json")
31200	if res != nil && res.StatusCode == http.StatusNotModified {
31201		if res.Body != nil {
31202			res.Body.Close()
31203		}
31204		return nil, &googleapi.Error{
31205			Code:   res.StatusCode,
31206			Header: res.Header,
31207		}
31208	}
31209	if err != nil {
31210		return nil, err
31211	}
31212	defer googleapi.CloseBody(res)
31213	if err := googleapi.CheckResponse(res); err != nil {
31214		return nil, err
31215	}
31216	ret := &GoogleCloudDialogflowV2KnowledgeBase{
31217		ServerResponse: googleapi.ServerResponse{
31218			Header:         res.Header,
31219			HTTPStatusCode: res.StatusCode,
31220		},
31221	}
31222	target := &ret
31223	if err := gensupport.DecodeResponse(target, res); err != nil {
31224		return nil, err
31225	}
31226	return ret, nil
31227	// {
31228	//   "description": "Updates the specified knowledge base.",
31229	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}",
31230	//   "httpMethod": "PATCH",
31231	//   "id": "dialogflow.projects.knowledgeBases.patch",
31232	//   "parameterOrder": [
31233	//     "name"
31234	//   ],
31235	//   "parameters": {
31236	//     "name": {
31237	//       "description": "The knowledge base resource name. The name must be empty when creating a knowledge base. Format: `projects//locations//knowledgeBases/`.",
31238	//       "location": "path",
31239	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+$",
31240	//       "required": true,
31241	//       "type": "string"
31242	//     },
31243	//     "updateMask": {
31244	//       "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.",
31245	//       "format": "google-fieldmask",
31246	//       "location": "query",
31247	//       "type": "string"
31248	//     }
31249	//   },
31250	//   "path": "v2/{+name}",
31251	//   "request": {
31252	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
31253	//   },
31254	//   "response": {
31255	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
31256	//   },
31257	//   "scopes": [
31258	//     "https://www.googleapis.com/auth/cloud-platform",
31259	//     "https://www.googleapis.com/auth/dialogflow"
31260	//   ]
31261	// }
31262
31263}
31264
31265// method id "dialogflow.projects.knowledgeBases.documents.create":
31266
31267type ProjectsKnowledgeBasesDocumentsCreateCall struct {
31268	s                               *Service
31269	parent                          string
31270	googleclouddialogflowv2document *GoogleCloudDialogflowV2Document
31271	urlParams_                      gensupport.URLParams
31272	ctx_                            context.Context
31273	header_                         http.Header
31274}
31275
31276// Create: Creates a new document. Operation
31277//
31278// - parent: The knowledge base to create a document for. Format:
31279//   `projects//locations//knowledgeBases/`.
31280func (r *ProjectsKnowledgeBasesDocumentsService) Create(parent string, googleclouddialogflowv2document *GoogleCloudDialogflowV2Document) *ProjectsKnowledgeBasesDocumentsCreateCall {
31281	c := &ProjectsKnowledgeBasesDocumentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31282	c.parent = parent
31283	c.googleclouddialogflowv2document = googleclouddialogflowv2document
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 *ProjectsKnowledgeBasesDocumentsCreateCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDocumentsCreateCall {
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 *ProjectsKnowledgeBasesDocumentsCreateCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDocumentsCreateCall {
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 *ProjectsKnowledgeBasesDocumentsCreateCall) Header() http.Header {
31306	if c.header_ == nil {
31307		c.header_ = make(http.Header)
31308	}
31309	return c.header_
31310}
31311
31312func (c *ProjectsKnowledgeBasesDocumentsCreateCall) doRequest(alt string) (*http.Response, error) {
31313	reqHeaders := make(http.Header)
31314	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
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.googleclouddialogflowv2document)
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/{+parent}/documents")
31328	urls += "?" + c.urlParams_.Encode()
31329	req, err := http.NewRequest("POST", urls, body)
31330	if err != nil {
31331		return nil, err
31332	}
31333	req.Header = reqHeaders
31334	googleapi.Expand(req.URL, map[string]string{
31335		"parent": c.parent,
31336	})
31337	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31338}
31339
31340// Do executes the "dialogflow.projects.knowledgeBases.documents.create" call.
31341// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
31342// Any non-2xx status code is an error. Response headers are in either
31343// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
31344// was returned at all) in error.(*googleapi.Error).Header. Use
31345// googleapi.IsNotModified to check whether the returned error was
31346// because http.StatusNotModified was returned.
31347func (c *ProjectsKnowledgeBasesDocumentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
31348	gensupport.SetOptions(c.urlParams_, opts...)
31349	res, err := c.doRequest("json")
31350	if res != nil && res.StatusCode == http.StatusNotModified {
31351		if res.Body != nil {
31352			res.Body.Close()
31353		}
31354		return nil, &googleapi.Error{
31355			Code:   res.StatusCode,
31356			Header: res.Header,
31357		}
31358	}
31359	if err != nil {
31360		return nil, err
31361	}
31362	defer googleapi.CloseBody(res)
31363	if err := googleapi.CheckResponse(res); err != nil {
31364		return nil, err
31365	}
31366	ret := &GoogleLongrunningOperation{
31367		ServerResponse: googleapi.ServerResponse{
31368			Header:         res.Header,
31369			HTTPStatusCode: res.StatusCode,
31370		},
31371	}
31372	target := &ret
31373	if err := gensupport.DecodeResponse(target, res); err != nil {
31374		return nil, err
31375	}
31376	return ret, nil
31377	// {
31378	//   "description": "Creates a new document. Operation ",
31379	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}/documents",
31380	//   "httpMethod": "POST",
31381	//   "id": "dialogflow.projects.knowledgeBases.documents.create",
31382	//   "parameterOrder": [
31383	//     "parent"
31384	//   ],
31385	//   "parameters": {
31386	//     "parent": {
31387	//       "description": "Required. The knowledge base to create a document for. Format: `projects//locations//knowledgeBases/`.",
31388	//       "location": "path",
31389	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+$",
31390	//       "required": true,
31391	//       "type": "string"
31392	//     }
31393	//   },
31394	//   "path": "v2/{+parent}/documents",
31395	//   "request": {
31396	//     "$ref": "GoogleCloudDialogflowV2Document"
31397	//   },
31398	//   "response": {
31399	//     "$ref": "GoogleLongrunningOperation"
31400	//   },
31401	//   "scopes": [
31402	//     "https://www.googleapis.com/auth/cloud-platform",
31403	//     "https://www.googleapis.com/auth/dialogflow"
31404	//   ]
31405	// }
31406
31407}
31408
31409// method id "dialogflow.projects.knowledgeBases.documents.delete":
31410
31411type ProjectsKnowledgeBasesDocumentsDeleteCall struct {
31412	s          *Service
31413	name       string
31414	urlParams_ gensupport.URLParams
31415	ctx_       context.Context
31416	header_    http.Header
31417}
31418
31419// Delete: Deletes the specified document. Operation
31420//
31421// - name: The name of the document to delete. Format:
31422//   `projects//locations//knowledgeBases//documents/`.
31423func (r *ProjectsKnowledgeBasesDocumentsService) Delete(name string) *ProjectsKnowledgeBasesDocumentsDeleteCall {
31424	c := &ProjectsKnowledgeBasesDocumentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31425	c.name = name
31426	return c
31427}
31428
31429// Fields allows partial responses to be retrieved. See
31430// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31431// for more information.
31432func (c *ProjectsKnowledgeBasesDocumentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDocumentsDeleteCall {
31433	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31434	return c
31435}
31436
31437// Context sets the context to be used in this call's Do method. Any
31438// pending HTTP request will be aborted if the provided context is
31439// canceled.
31440func (c *ProjectsKnowledgeBasesDocumentsDeleteCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDocumentsDeleteCall {
31441	c.ctx_ = ctx
31442	return c
31443}
31444
31445// Header returns an http.Header that can be modified by the caller to
31446// add HTTP headers to the request.
31447func (c *ProjectsKnowledgeBasesDocumentsDeleteCall) Header() http.Header {
31448	if c.header_ == nil {
31449		c.header_ = make(http.Header)
31450	}
31451	return c.header_
31452}
31453
31454func (c *ProjectsKnowledgeBasesDocumentsDeleteCall) doRequest(alt string) (*http.Response, error) {
31455	reqHeaders := make(http.Header)
31456	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
31457	for k, v := range c.header_ {
31458		reqHeaders[k] = v
31459	}
31460	reqHeaders.Set("User-Agent", c.s.userAgent())
31461	var body io.Reader = nil
31462	c.urlParams_.Set("alt", alt)
31463	c.urlParams_.Set("prettyPrint", "false")
31464	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
31465	urls += "?" + c.urlParams_.Encode()
31466	req, err := http.NewRequest("DELETE", urls, body)
31467	if err != nil {
31468		return nil, err
31469	}
31470	req.Header = reqHeaders
31471	googleapi.Expand(req.URL, map[string]string{
31472		"name": c.name,
31473	})
31474	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31475}
31476
31477// Do executes the "dialogflow.projects.knowledgeBases.documents.delete" call.
31478// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
31479// Any non-2xx status code is an error. Response headers are in either
31480// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
31481// was returned at all) in error.(*googleapi.Error).Header. Use
31482// googleapi.IsNotModified to check whether the returned error was
31483// because http.StatusNotModified was returned.
31484func (c *ProjectsKnowledgeBasesDocumentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
31485	gensupport.SetOptions(c.urlParams_, opts...)
31486	res, err := c.doRequest("json")
31487	if res != nil && res.StatusCode == http.StatusNotModified {
31488		if res.Body != nil {
31489			res.Body.Close()
31490		}
31491		return nil, &googleapi.Error{
31492			Code:   res.StatusCode,
31493			Header: res.Header,
31494		}
31495	}
31496	if err != nil {
31497		return nil, err
31498	}
31499	defer googleapi.CloseBody(res)
31500	if err := googleapi.CheckResponse(res); err != nil {
31501		return nil, err
31502	}
31503	ret := &GoogleLongrunningOperation{
31504		ServerResponse: googleapi.ServerResponse{
31505			Header:         res.Header,
31506			HTTPStatusCode: res.StatusCode,
31507		},
31508	}
31509	target := &ret
31510	if err := gensupport.DecodeResponse(target, res); err != nil {
31511		return nil, err
31512	}
31513	return ret, nil
31514	// {
31515	//   "description": "Deletes the specified document. Operation ",
31516	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
31517	//   "httpMethod": "DELETE",
31518	//   "id": "dialogflow.projects.knowledgeBases.documents.delete",
31519	//   "parameterOrder": [
31520	//     "name"
31521	//   ],
31522	//   "parameters": {
31523	//     "name": {
31524	//       "description": "Required. The name of the document to delete. Format: `projects//locations//knowledgeBases//documents/`.",
31525	//       "location": "path",
31526	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
31527	//       "required": true,
31528	//       "type": "string"
31529	//     }
31530	//   },
31531	//   "path": "v2/{+name}",
31532	//   "response": {
31533	//     "$ref": "GoogleLongrunningOperation"
31534	//   },
31535	//   "scopes": [
31536	//     "https://www.googleapis.com/auth/cloud-platform",
31537	//     "https://www.googleapis.com/auth/dialogflow"
31538	//   ]
31539	// }
31540
31541}
31542
31543// method id "dialogflow.projects.knowledgeBases.documents.get":
31544
31545type ProjectsKnowledgeBasesDocumentsGetCall struct {
31546	s            *Service
31547	name         string
31548	urlParams_   gensupport.URLParams
31549	ifNoneMatch_ string
31550	ctx_         context.Context
31551	header_      http.Header
31552}
31553
31554// Get: Retrieves the specified document.
31555//
31556// - name: The name of the document to retrieve. Format
31557//   `projects//locations//knowledgeBases//documents/`.
31558func (r *ProjectsKnowledgeBasesDocumentsService) Get(name string) *ProjectsKnowledgeBasesDocumentsGetCall {
31559	c := &ProjectsKnowledgeBasesDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31560	c.name = name
31561	return c
31562}
31563
31564// Fields allows partial responses to be retrieved. See
31565// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31566// for more information.
31567func (c *ProjectsKnowledgeBasesDocumentsGetCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDocumentsGetCall {
31568	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31569	return c
31570}
31571
31572// IfNoneMatch sets the optional parameter which makes the operation
31573// fail if the object's ETag matches the given value. This is useful for
31574// getting updates only after the object has changed since the last
31575// request. Use googleapi.IsNotModified to check whether the response
31576// error from Do is the result of In-None-Match.
31577func (c *ProjectsKnowledgeBasesDocumentsGetCall) IfNoneMatch(entityTag string) *ProjectsKnowledgeBasesDocumentsGetCall {
31578	c.ifNoneMatch_ = entityTag
31579	return c
31580}
31581
31582// Context sets the context to be used in this call's Do method. Any
31583// pending HTTP request will be aborted if the provided context is
31584// canceled.
31585func (c *ProjectsKnowledgeBasesDocumentsGetCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDocumentsGetCall {
31586	c.ctx_ = ctx
31587	return c
31588}
31589
31590// Header returns an http.Header that can be modified by the caller to
31591// add HTTP headers to the request.
31592func (c *ProjectsKnowledgeBasesDocumentsGetCall) Header() http.Header {
31593	if c.header_ == nil {
31594		c.header_ = make(http.Header)
31595	}
31596	return c.header_
31597}
31598
31599func (c *ProjectsKnowledgeBasesDocumentsGetCall) doRequest(alt string) (*http.Response, error) {
31600	reqHeaders := make(http.Header)
31601	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
31602	for k, v := range c.header_ {
31603		reqHeaders[k] = v
31604	}
31605	reqHeaders.Set("User-Agent", c.s.userAgent())
31606	if c.ifNoneMatch_ != "" {
31607		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31608	}
31609	var body io.Reader = nil
31610	c.urlParams_.Set("alt", alt)
31611	c.urlParams_.Set("prettyPrint", "false")
31612	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
31613	urls += "?" + c.urlParams_.Encode()
31614	req, err := http.NewRequest("GET", urls, body)
31615	if err != nil {
31616		return nil, err
31617	}
31618	req.Header = reqHeaders
31619	googleapi.Expand(req.URL, map[string]string{
31620		"name": c.name,
31621	})
31622	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31623}
31624
31625// Do executes the "dialogflow.projects.knowledgeBases.documents.get" call.
31626// Exactly one of *GoogleCloudDialogflowV2Document or error will be
31627// non-nil. Any non-2xx status code is an error. Response headers are in
31628// either *GoogleCloudDialogflowV2Document.ServerResponse.Header or (if
31629// a response was returned at all) in error.(*googleapi.Error).Header.
31630// Use googleapi.IsNotModified to check whether the returned error was
31631// because http.StatusNotModified was returned.
31632func (c *ProjectsKnowledgeBasesDocumentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Document, error) {
31633	gensupport.SetOptions(c.urlParams_, opts...)
31634	res, err := c.doRequest("json")
31635	if res != nil && res.StatusCode == http.StatusNotModified {
31636		if res.Body != nil {
31637			res.Body.Close()
31638		}
31639		return nil, &googleapi.Error{
31640			Code:   res.StatusCode,
31641			Header: res.Header,
31642		}
31643	}
31644	if err != nil {
31645		return nil, err
31646	}
31647	defer googleapi.CloseBody(res)
31648	if err := googleapi.CheckResponse(res); err != nil {
31649		return nil, err
31650	}
31651	ret := &GoogleCloudDialogflowV2Document{
31652		ServerResponse: googleapi.ServerResponse{
31653			Header:         res.Header,
31654			HTTPStatusCode: res.StatusCode,
31655		},
31656	}
31657	target := &ret
31658	if err := gensupport.DecodeResponse(target, res); err != nil {
31659		return nil, err
31660	}
31661	return ret, nil
31662	// {
31663	//   "description": "Retrieves the specified document.",
31664	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
31665	//   "httpMethod": "GET",
31666	//   "id": "dialogflow.projects.knowledgeBases.documents.get",
31667	//   "parameterOrder": [
31668	//     "name"
31669	//   ],
31670	//   "parameters": {
31671	//     "name": {
31672	//       "description": "Required. The name of the document to retrieve. Format `projects//locations//knowledgeBases//documents/`.",
31673	//       "location": "path",
31674	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
31675	//       "required": true,
31676	//       "type": "string"
31677	//     }
31678	//   },
31679	//   "path": "v2/{+name}",
31680	//   "response": {
31681	//     "$ref": "GoogleCloudDialogflowV2Document"
31682	//   },
31683	//   "scopes": [
31684	//     "https://www.googleapis.com/auth/cloud-platform",
31685	//     "https://www.googleapis.com/auth/dialogflow"
31686	//   ]
31687	// }
31688
31689}
31690
31691// method id "dialogflow.projects.knowledgeBases.documents.list":
31692
31693type ProjectsKnowledgeBasesDocumentsListCall struct {
31694	s            *Service
31695	parent       string
31696	urlParams_   gensupport.URLParams
31697	ifNoneMatch_ string
31698	ctx_         context.Context
31699	header_      http.Header
31700}
31701
31702// List: Returns the list of all documents of the knowledge base.
31703//
31704// - parent: The knowledge base to list all documents for. Format:
31705//   `projects//locations//knowledgeBases/`.
31706func (r *ProjectsKnowledgeBasesDocumentsService) List(parent string) *ProjectsKnowledgeBasesDocumentsListCall {
31707	c := &ProjectsKnowledgeBasesDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31708	c.parent = parent
31709	return c
31710}
31711
31712// PageSize sets the optional parameter "pageSize": The maximum number
31713// of items to return in a single page. By default 10 and at most 100.
31714func (c *ProjectsKnowledgeBasesDocumentsListCall) PageSize(pageSize int64) *ProjectsKnowledgeBasesDocumentsListCall {
31715	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
31716	return c
31717}
31718
31719// PageToken sets the optional parameter "pageToken": The
31720// next_page_token value returned from a previous list request.
31721func (c *ProjectsKnowledgeBasesDocumentsListCall) PageToken(pageToken string) *ProjectsKnowledgeBasesDocumentsListCall {
31722	c.urlParams_.Set("pageToken", pageToken)
31723	return c
31724}
31725
31726// Fields allows partial responses to be retrieved. See
31727// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31728// for more information.
31729func (c *ProjectsKnowledgeBasesDocumentsListCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDocumentsListCall {
31730	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31731	return c
31732}
31733
31734// IfNoneMatch sets the optional parameter which makes the operation
31735// fail if the object's ETag matches the given value. This is useful for
31736// getting updates only after the object has changed since the last
31737// request. Use googleapi.IsNotModified to check whether the response
31738// error from Do is the result of In-None-Match.
31739func (c *ProjectsKnowledgeBasesDocumentsListCall) IfNoneMatch(entityTag string) *ProjectsKnowledgeBasesDocumentsListCall {
31740	c.ifNoneMatch_ = entityTag
31741	return c
31742}
31743
31744// Context sets the context to be used in this call's Do method. Any
31745// pending HTTP request will be aborted if the provided context is
31746// canceled.
31747func (c *ProjectsKnowledgeBasesDocumentsListCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDocumentsListCall {
31748	c.ctx_ = ctx
31749	return c
31750}
31751
31752// Header returns an http.Header that can be modified by the caller to
31753// add HTTP headers to the request.
31754func (c *ProjectsKnowledgeBasesDocumentsListCall) Header() http.Header {
31755	if c.header_ == nil {
31756		c.header_ = make(http.Header)
31757	}
31758	return c.header_
31759}
31760
31761func (c *ProjectsKnowledgeBasesDocumentsListCall) doRequest(alt string) (*http.Response, error) {
31762	reqHeaders := make(http.Header)
31763	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
31764	for k, v := range c.header_ {
31765		reqHeaders[k] = v
31766	}
31767	reqHeaders.Set("User-Agent", c.s.userAgent())
31768	if c.ifNoneMatch_ != "" {
31769		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31770	}
31771	var body io.Reader = nil
31772	c.urlParams_.Set("alt", alt)
31773	c.urlParams_.Set("prettyPrint", "false")
31774	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/documents")
31775	urls += "?" + c.urlParams_.Encode()
31776	req, err := http.NewRequest("GET", urls, body)
31777	if err != nil {
31778		return nil, err
31779	}
31780	req.Header = reqHeaders
31781	googleapi.Expand(req.URL, map[string]string{
31782		"parent": c.parent,
31783	})
31784	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31785}
31786
31787// Do executes the "dialogflow.projects.knowledgeBases.documents.list" call.
31788// Exactly one of *GoogleCloudDialogflowV2ListDocumentsResponse or error
31789// will be non-nil. Any non-2xx status code is an error. Response
31790// headers are in either
31791// *GoogleCloudDialogflowV2ListDocumentsResponse.ServerResponse.Header
31792// or (if a response was returned at all) in
31793// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
31794// whether the returned error was because http.StatusNotModified was
31795// returned.
31796func (c *ProjectsKnowledgeBasesDocumentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListDocumentsResponse, error) {
31797	gensupport.SetOptions(c.urlParams_, opts...)
31798	res, err := c.doRequest("json")
31799	if res != nil && res.StatusCode == http.StatusNotModified {
31800		if res.Body != nil {
31801			res.Body.Close()
31802		}
31803		return nil, &googleapi.Error{
31804			Code:   res.StatusCode,
31805			Header: res.Header,
31806		}
31807	}
31808	if err != nil {
31809		return nil, err
31810	}
31811	defer googleapi.CloseBody(res)
31812	if err := googleapi.CheckResponse(res); err != nil {
31813		return nil, err
31814	}
31815	ret := &GoogleCloudDialogflowV2ListDocumentsResponse{
31816		ServerResponse: googleapi.ServerResponse{
31817			Header:         res.Header,
31818			HTTPStatusCode: res.StatusCode,
31819		},
31820	}
31821	target := &ret
31822	if err := gensupport.DecodeResponse(target, res); err != nil {
31823		return nil, err
31824	}
31825	return ret, nil
31826	// {
31827	//   "description": "Returns the list of all documents of the knowledge base.",
31828	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}/documents",
31829	//   "httpMethod": "GET",
31830	//   "id": "dialogflow.projects.knowledgeBases.documents.list",
31831	//   "parameterOrder": [
31832	//     "parent"
31833	//   ],
31834	//   "parameters": {
31835	//     "pageSize": {
31836	//       "description": "The maximum number of items to return in a single page. By default 10 and at most 100.",
31837	//       "format": "int32",
31838	//       "location": "query",
31839	//       "type": "integer"
31840	//     },
31841	//     "pageToken": {
31842	//       "description": "The next_page_token value returned from a previous list request.",
31843	//       "location": "query",
31844	//       "type": "string"
31845	//     },
31846	//     "parent": {
31847	//       "description": "Required. The knowledge base to list all documents for. Format: `projects//locations//knowledgeBases/`.",
31848	//       "location": "path",
31849	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+$",
31850	//       "required": true,
31851	//       "type": "string"
31852	//     }
31853	//   },
31854	//   "path": "v2/{+parent}/documents",
31855	//   "response": {
31856	//     "$ref": "GoogleCloudDialogflowV2ListDocumentsResponse"
31857	//   },
31858	//   "scopes": [
31859	//     "https://www.googleapis.com/auth/cloud-platform",
31860	//     "https://www.googleapis.com/auth/dialogflow"
31861	//   ]
31862	// }
31863
31864}
31865
31866// Pages invokes f for each page of results.
31867// A non-nil error returned from f will halt the iteration.
31868// The provided context supersedes any context provided to the Context method.
31869func (c *ProjectsKnowledgeBasesDocumentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListDocumentsResponse) error) error {
31870	c.ctx_ = ctx
31871	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
31872	for {
31873		x, err := c.Do()
31874		if err != nil {
31875			return err
31876		}
31877		if err := f(x); err != nil {
31878			return err
31879		}
31880		if x.NextPageToken == "" {
31881			return nil
31882		}
31883		c.PageToken(x.NextPageToken)
31884	}
31885}
31886
31887// method id "dialogflow.projects.knowledgeBases.documents.patch":
31888
31889type ProjectsKnowledgeBasesDocumentsPatchCall struct {
31890	s                               *Service
31891	name                            string
31892	googleclouddialogflowv2document *GoogleCloudDialogflowV2Document
31893	urlParams_                      gensupport.URLParams
31894	ctx_                            context.Context
31895	header_                         http.Header
31896}
31897
31898// Patch: Updates the specified document. Operation
31899//
31900// - name: Optional. The document resource name. The name must be empty
31901//   when creating a document. Format:
31902//   `projects//locations//knowledgeBases//documents/`.
31903func (r *ProjectsKnowledgeBasesDocumentsService) Patch(name string, googleclouddialogflowv2document *GoogleCloudDialogflowV2Document) *ProjectsKnowledgeBasesDocumentsPatchCall {
31904	c := &ProjectsKnowledgeBasesDocumentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31905	c.name = name
31906	c.googleclouddialogflowv2document = googleclouddialogflowv2document
31907	return c
31908}
31909
31910// UpdateMask sets the optional parameter "updateMask": Not specified
31911// means `update all`. Currently, only `display_name` can be updated, an
31912// InvalidArgument will be returned for attempting to update other
31913// fields.
31914func (c *ProjectsKnowledgeBasesDocumentsPatchCall) UpdateMask(updateMask string) *ProjectsKnowledgeBasesDocumentsPatchCall {
31915	c.urlParams_.Set("updateMask", updateMask)
31916	return c
31917}
31918
31919// Fields allows partial responses to be retrieved. See
31920// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31921// for more information.
31922func (c *ProjectsKnowledgeBasesDocumentsPatchCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDocumentsPatchCall {
31923	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31924	return c
31925}
31926
31927// Context sets the context to be used in this call's Do method. Any
31928// pending HTTP request will be aborted if the provided context is
31929// canceled.
31930func (c *ProjectsKnowledgeBasesDocumentsPatchCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDocumentsPatchCall {
31931	c.ctx_ = ctx
31932	return c
31933}
31934
31935// Header returns an http.Header that can be modified by the caller to
31936// add HTTP headers to the request.
31937func (c *ProjectsKnowledgeBasesDocumentsPatchCall) Header() http.Header {
31938	if c.header_ == nil {
31939		c.header_ = make(http.Header)
31940	}
31941	return c.header_
31942}
31943
31944func (c *ProjectsKnowledgeBasesDocumentsPatchCall) doRequest(alt string) (*http.Response, error) {
31945	reqHeaders := make(http.Header)
31946	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
31947	for k, v := range c.header_ {
31948		reqHeaders[k] = v
31949	}
31950	reqHeaders.Set("User-Agent", c.s.userAgent())
31951	var body io.Reader = nil
31952	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2document)
31953	if err != nil {
31954		return nil, err
31955	}
31956	reqHeaders.Set("Content-Type", "application/json")
31957	c.urlParams_.Set("alt", alt)
31958	c.urlParams_.Set("prettyPrint", "false")
31959	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
31960	urls += "?" + c.urlParams_.Encode()
31961	req, err := http.NewRequest("PATCH", urls, body)
31962	if err != nil {
31963		return nil, err
31964	}
31965	req.Header = reqHeaders
31966	googleapi.Expand(req.URL, map[string]string{
31967		"name": c.name,
31968	})
31969	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31970}
31971
31972// Do executes the "dialogflow.projects.knowledgeBases.documents.patch" call.
31973// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
31974// Any non-2xx status code is an error. Response headers are in either
31975// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
31976// was returned at all) in error.(*googleapi.Error).Header. Use
31977// googleapi.IsNotModified to check whether the returned error was
31978// because http.StatusNotModified was returned.
31979func (c *ProjectsKnowledgeBasesDocumentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
31980	gensupport.SetOptions(c.urlParams_, opts...)
31981	res, err := c.doRequest("json")
31982	if res != nil && res.StatusCode == http.StatusNotModified {
31983		if res.Body != nil {
31984			res.Body.Close()
31985		}
31986		return nil, &googleapi.Error{
31987			Code:   res.StatusCode,
31988			Header: res.Header,
31989		}
31990	}
31991	if err != nil {
31992		return nil, err
31993	}
31994	defer googleapi.CloseBody(res)
31995	if err := googleapi.CheckResponse(res); err != nil {
31996		return nil, err
31997	}
31998	ret := &GoogleLongrunningOperation{
31999		ServerResponse: googleapi.ServerResponse{
32000			Header:         res.Header,
32001			HTTPStatusCode: res.StatusCode,
32002		},
32003	}
32004	target := &ret
32005	if err := gensupport.DecodeResponse(target, res); err != nil {
32006		return nil, err
32007	}
32008	return ret, nil
32009	// {
32010	//   "description": "Updates the specified document. Operation ",
32011	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
32012	//   "httpMethod": "PATCH",
32013	//   "id": "dialogflow.projects.knowledgeBases.documents.patch",
32014	//   "parameterOrder": [
32015	//     "name"
32016	//   ],
32017	//   "parameters": {
32018	//     "name": {
32019	//       "description": "Optional. The document resource name. The name must be empty when creating a document. Format: `projects//locations//knowledgeBases//documents/`.",
32020	//       "location": "path",
32021	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
32022	//       "required": true,
32023	//       "type": "string"
32024	//     },
32025	//     "updateMask": {
32026	//       "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.",
32027	//       "format": "google-fieldmask",
32028	//       "location": "query",
32029	//       "type": "string"
32030	//     }
32031	//   },
32032	//   "path": "v2/{+name}",
32033	//   "request": {
32034	//     "$ref": "GoogleCloudDialogflowV2Document"
32035	//   },
32036	//   "response": {
32037	//     "$ref": "GoogleLongrunningOperation"
32038	//   },
32039	//   "scopes": [
32040	//     "https://www.googleapis.com/auth/cloud-platform",
32041	//     "https://www.googleapis.com/auth/dialogflow"
32042	//   ]
32043	// }
32044
32045}
32046
32047// method id "dialogflow.projects.knowledgeBases.documents.reload":
32048
32049type ProjectsKnowledgeBasesDocumentsReloadCall struct {
32050	s                                            *Service
32051	name                                         string
32052	googleclouddialogflowv2reloaddocumentrequest *GoogleCloudDialogflowV2ReloadDocumentRequest
32053	urlParams_                                   gensupport.URLParams
32054	ctx_                                         context.Context
32055	header_                                      http.Header
32056}
32057
32058// Reload: Reloads the specified document from its specified source,
32059// content_uri or content. The previously loaded content of the document
32060// will be deleted. Note: Even when the content of the document has not
32061// changed, there still may be side effects because of internal
32062// implementation changes. Note: The
32063// `projects.agent.knowledgeBases.documents` resource is deprecated;
32064// only use `projects.knowledgeBases.documents`. Operation
32065//
32066// - name: The name of the document to reload. Format:
32067//   `projects//locations//knowledgeBases//documents/`.
32068func (r *ProjectsKnowledgeBasesDocumentsService) Reload(name string, googleclouddialogflowv2reloaddocumentrequest *GoogleCloudDialogflowV2ReloadDocumentRequest) *ProjectsKnowledgeBasesDocumentsReloadCall {
32069	c := &ProjectsKnowledgeBasesDocumentsReloadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32070	c.name = name
32071	c.googleclouddialogflowv2reloaddocumentrequest = googleclouddialogflowv2reloaddocumentrequest
32072	return c
32073}
32074
32075// Fields allows partial responses to be retrieved. See
32076// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32077// for more information.
32078func (c *ProjectsKnowledgeBasesDocumentsReloadCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDocumentsReloadCall {
32079	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32080	return c
32081}
32082
32083// Context sets the context to be used in this call's Do method. Any
32084// pending HTTP request will be aborted if the provided context is
32085// canceled.
32086func (c *ProjectsKnowledgeBasesDocumentsReloadCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDocumentsReloadCall {
32087	c.ctx_ = ctx
32088	return c
32089}
32090
32091// Header returns an http.Header that can be modified by the caller to
32092// add HTTP headers to the request.
32093func (c *ProjectsKnowledgeBasesDocumentsReloadCall) Header() http.Header {
32094	if c.header_ == nil {
32095		c.header_ = make(http.Header)
32096	}
32097	return c.header_
32098}
32099
32100func (c *ProjectsKnowledgeBasesDocumentsReloadCall) doRequest(alt string) (*http.Response, error) {
32101	reqHeaders := make(http.Header)
32102	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
32103	for k, v := range c.header_ {
32104		reqHeaders[k] = v
32105	}
32106	reqHeaders.Set("User-Agent", c.s.userAgent())
32107	var body io.Reader = nil
32108	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2reloaddocumentrequest)
32109	if err != nil {
32110		return nil, err
32111	}
32112	reqHeaders.Set("Content-Type", "application/json")
32113	c.urlParams_.Set("alt", alt)
32114	c.urlParams_.Set("prettyPrint", "false")
32115	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:reload")
32116	urls += "?" + c.urlParams_.Encode()
32117	req, err := http.NewRequest("POST", urls, body)
32118	if err != nil {
32119		return nil, err
32120	}
32121	req.Header = reqHeaders
32122	googleapi.Expand(req.URL, map[string]string{
32123		"name": c.name,
32124	})
32125	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32126}
32127
32128// Do executes the "dialogflow.projects.knowledgeBases.documents.reload" call.
32129// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
32130// Any non-2xx status code is an error. Response headers are in either
32131// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
32132// was returned at all) in error.(*googleapi.Error).Header. Use
32133// googleapi.IsNotModified to check whether the returned error was
32134// because http.StatusNotModified was returned.
32135func (c *ProjectsKnowledgeBasesDocumentsReloadCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
32136	gensupport.SetOptions(c.urlParams_, opts...)
32137	res, err := c.doRequest("json")
32138	if res != nil && res.StatusCode == http.StatusNotModified {
32139		if res.Body != nil {
32140			res.Body.Close()
32141		}
32142		return nil, &googleapi.Error{
32143			Code:   res.StatusCode,
32144			Header: res.Header,
32145		}
32146	}
32147	if err != nil {
32148		return nil, err
32149	}
32150	defer googleapi.CloseBody(res)
32151	if err := googleapi.CheckResponse(res); err != nil {
32152		return nil, err
32153	}
32154	ret := &GoogleLongrunningOperation{
32155		ServerResponse: googleapi.ServerResponse{
32156			Header:         res.Header,
32157			HTTPStatusCode: res.StatusCode,
32158		},
32159	}
32160	target := &ret
32161	if err := gensupport.DecodeResponse(target, res); err != nil {
32162		return nil, err
32163	}
32164	return ret, nil
32165	// {
32166	//   "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. Note: The `projects.agent.knowledgeBases.documents` resource is deprecated; only use `projects.knowledgeBases.documents`. Operation ",
32167	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}:reload",
32168	//   "httpMethod": "POST",
32169	//   "id": "dialogflow.projects.knowledgeBases.documents.reload",
32170	//   "parameterOrder": [
32171	//     "name"
32172	//   ],
32173	//   "parameters": {
32174	//     "name": {
32175	//       "description": "Required. The name of the document to reload. Format: `projects//locations//knowledgeBases//documents/`",
32176	//       "location": "path",
32177	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
32178	//       "required": true,
32179	//       "type": "string"
32180	//     }
32181	//   },
32182	//   "path": "v2/{+name}:reload",
32183	//   "request": {
32184	//     "$ref": "GoogleCloudDialogflowV2ReloadDocumentRequest"
32185	//   },
32186	//   "response": {
32187	//     "$ref": "GoogleLongrunningOperation"
32188	//   },
32189	//   "scopes": [
32190	//     "https://www.googleapis.com/auth/cloud-platform",
32191	//     "https://www.googleapis.com/auth/dialogflow"
32192	//   ]
32193	// }
32194
32195}
32196
32197// method id "dialogflow.projects.locations.deleteAgent":
32198
32199type ProjectsLocationsDeleteAgentCall struct {
32200	s          *Service
32201	parent     string
32202	urlParams_ gensupport.URLParams
32203	ctx_       context.Context
32204	header_    http.Header
32205}
32206
32207// DeleteAgent: Deletes the specified agent.
32208//
32209// - parent: The project that the agent to delete is associated with.
32210//   Format: `projects/`.
32211func (r *ProjectsLocationsService) DeleteAgent(parent string) *ProjectsLocationsDeleteAgentCall {
32212	c := &ProjectsLocationsDeleteAgentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32213	c.parent = parent
32214	return c
32215}
32216
32217// Fields allows partial responses to be retrieved. See
32218// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32219// for more information.
32220func (c *ProjectsLocationsDeleteAgentCall) Fields(s ...googleapi.Field) *ProjectsLocationsDeleteAgentCall {
32221	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32222	return c
32223}
32224
32225// Context sets the context to be used in this call's Do method. Any
32226// pending HTTP request will be aborted if the provided context is
32227// canceled.
32228func (c *ProjectsLocationsDeleteAgentCall) Context(ctx context.Context) *ProjectsLocationsDeleteAgentCall {
32229	c.ctx_ = ctx
32230	return c
32231}
32232
32233// Header returns an http.Header that can be modified by the caller to
32234// add HTTP headers to the request.
32235func (c *ProjectsLocationsDeleteAgentCall) Header() http.Header {
32236	if c.header_ == nil {
32237		c.header_ = make(http.Header)
32238	}
32239	return c.header_
32240}
32241
32242func (c *ProjectsLocationsDeleteAgentCall) doRequest(alt string) (*http.Response, error) {
32243	reqHeaders := make(http.Header)
32244	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
32245	for k, v := range c.header_ {
32246		reqHeaders[k] = v
32247	}
32248	reqHeaders.Set("User-Agent", c.s.userAgent())
32249	var body io.Reader = nil
32250	c.urlParams_.Set("alt", alt)
32251	c.urlParams_.Set("prettyPrint", "false")
32252	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent")
32253	urls += "?" + c.urlParams_.Encode()
32254	req, err := http.NewRequest("DELETE", urls, body)
32255	if err != nil {
32256		return nil, err
32257	}
32258	req.Header = reqHeaders
32259	googleapi.Expand(req.URL, map[string]string{
32260		"parent": c.parent,
32261	})
32262	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32263}
32264
32265// Do executes the "dialogflow.projects.locations.deleteAgent" call.
32266// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
32267// non-2xx status code is an error. Response headers are in either
32268// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
32269// returned at all) in error.(*googleapi.Error).Header. Use
32270// googleapi.IsNotModified to check whether the returned error was
32271// because http.StatusNotModified was returned.
32272func (c *ProjectsLocationsDeleteAgentCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
32273	gensupport.SetOptions(c.urlParams_, opts...)
32274	res, err := c.doRequest("json")
32275	if res != nil && res.StatusCode == http.StatusNotModified {
32276		if res.Body != nil {
32277			res.Body.Close()
32278		}
32279		return nil, &googleapi.Error{
32280			Code:   res.StatusCode,
32281			Header: res.Header,
32282		}
32283	}
32284	if err != nil {
32285		return nil, err
32286	}
32287	defer googleapi.CloseBody(res)
32288	if err := googleapi.CheckResponse(res); err != nil {
32289		return nil, err
32290	}
32291	ret := &GoogleProtobufEmpty{
32292		ServerResponse: googleapi.ServerResponse{
32293			Header:         res.Header,
32294			HTTPStatusCode: res.StatusCode,
32295		},
32296	}
32297	target := &ret
32298	if err := gensupport.DecodeResponse(target, res); err != nil {
32299		return nil, err
32300	}
32301	return ret, nil
32302	// {
32303	//   "description": "Deletes the specified agent.",
32304	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent",
32305	//   "httpMethod": "DELETE",
32306	//   "id": "dialogflow.projects.locations.deleteAgent",
32307	//   "parameterOrder": [
32308	//     "parent"
32309	//   ],
32310	//   "parameters": {
32311	//     "parent": {
32312	//       "description": "Required. The project that the agent to delete is associated with. Format: `projects/`.",
32313	//       "location": "path",
32314	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
32315	//       "required": true,
32316	//       "type": "string"
32317	//     }
32318	//   },
32319	//   "path": "v2/{+parent}/agent",
32320	//   "response": {
32321	//     "$ref": "GoogleProtobufEmpty"
32322	//   },
32323	//   "scopes": [
32324	//     "https://www.googleapis.com/auth/cloud-platform",
32325	//     "https://www.googleapis.com/auth/dialogflow"
32326	//   ]
32327	// }
32328
32329}
32330
32331// method id "dialogflow.projects.locations.getAgent":
32332
32333type ProjectsLocationsGetAgentCall struct {
32334	s            *Service
32335	parent       string
32336	urlParams_   gensupport.URLParams
32337	ifNoneMatch_ string
32338	ctx_         context.Context
32339	header_      http.Header
32340}
32341
32342// GetAgent: Retrieves the specified agent.
32343//
32344// - parent: The project that the agent to fetch is associated with.
32345//   Format: `projects/`.
32346func (r *ProjectsLocationsService) GetAgent(parent string) *ProjectsLocationsGetAgentCall {
32347	c := &ProjectsLocationsGetAgentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32348	c.parent = parent
32349	return c
32350}
32351
32352// Fields allows partial responses to be retrieved. See
32353// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32354// for more information.
32355func (c *ProjectsLocationsGetAgentCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetAgentCall {
32356	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32357	return c
32358}
32359
32360// IfNoneMatch sets the optional parameter which makes the operation
32361// fail if the object's ETag matches the given value. This is useful for
32362// getting updates only after the object has changed since the last
32363// request. Use googleapi.IsNotModified to check whether the response
32364// error from Do is the result of In-None-Match.
32365func (c *ProjectsLocationsGetAgentCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetAgentCall {
32366	c.ifNoneMatch_ = entityTag
32367	return c
32368}
32369
32370// Context sets the context to be used in this call's Do method. Any
32371// pending HTTP request will be aborted if the provided context is
32372// canceled.
32373func (c *ProjectsLocationsGetAgentCall) Context(ctx context.Context) *ProjectsLocationsGetAgentCall {
32374	c.ctx_ = ctx
32375	return c
32376}
32377
32378// Header returns an http.Header that can be modified by the caller to
32379// add HTTP headers to the request.
32380func (c *ProjectsLocationsGetAgentCall) Header() http.Header {
32381	if c.header_ == nil {
32382		c.header_ = make(http.Header)
32383	}
32384	return c.header_
32385}
32386
32387func (c *ProjectsLocationsGetAgentCall) doRequest(alt string) (*http.Response, error) {
32388	reqHeaders := make(http.Header)
32389	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
32390	for k, v := range c.header_ {
32391		reqHeaders[k] = v
32392	}
32393	reqHeaders.Set("User-Agent", c.s.userAgent())
32394	if c.ifNoneMatch_ != "" {
32395		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32396	}
32397	var body io.Reader = nil
32398	c.urlParams_.Set("alt", alt)
32399	c.urlParams_.Set("prettyPrint", "false")
32400	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent")
32401	urls += "?" + c.urlParams_.Encode()
32402	req, err := http.NewRequest("GET", urls, body)
32403	if err != nil {
32404		return nil, err
32405	}
32406	req.Header = reqHeaders
32407	googleapi.Expand(req.URL, map[string]string{
32408		"parent": c.parent,
32409	})
32410	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32411}
32412
32413// Do executes the "dialogflow.projects.locations.getAgent" call.
32414// Exactly one of *GoogleCloudDialogflowV2Agent or error will be
32415// non-nil. Any non-2xx status code is an error. Response headers are in
32416// either *GoogleCloudDialogflowV2Agent.ServerResponse.Header or (if a
32417// response was returned at all) in error.(*googleapi.Error).Header. Use
32418// googleapi.IsNotModified to check whether the returned error was
32419// because http.StatusNotModified was returned.
32420func (c *ProjectsLocationsGetAgentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Agent, error) {
32421	gensupport.SetOptions(c.urlParams_, opts...)
32422	res, err := c.doRequest("json")
32423	if res != nil && res.StatusCode == http.StatusNotModified {
32424		if res.Body != nil {
32425			res.Body.Close()
32426		}
32427		return nil, &googleapi.Error{
32428			Code:   res.StatusCode,
32429			Header: res.Header,
32430		}
32431	}
32432	if err != nil {
32433		return nil, err
32434	}
32435	defer googleapi.CloseBody(res)
32436	if err := googleapi.CheckResponse(res); err != nil {
32437		return nil, err
32438	}
32439	ret := &GoogleCloudDialogflowV2Agent{
32440		ServerResponse: googleapi.ServerResponse{
32441			Header:         res.Header,
32442			HTTPStatusCode: res.StatusCode,
32443		},
32444	}
32445	target := &ret
32446	if err := gensupport.DecodeResponse(target, res); err != nil {
32447		return nil, err
32448	}
32449	return ret, nil
32450	// {
32451	//   "description": "Retrieves the specified agent.",
32452	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent",
32453	//   "httpMethod": "GET",
32454	//   "id": "dialogflow.projects.locations.getAgent",
32455	//   "parameterOrder": [
32456	//     "parent"
32457	//   ],
32458	//   "parameters": {
32459	//     "parent": {
32460	//       "description": "Required. The project that the agent to fetch is associated with. Format: `projects/`.",
32461	//       "location": "path",
32462	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
32463	//       "required": true,
32464	//       "type": "string"
32465	//     }
32466	//   },
32467	//   "path": "v2/{+parent}/agent",
32468	//   "response": {
32469	//     "$ref": "GoogleCloudDialogflowV2Agent"
32470	//   },
32471	//   "scopes": [
32472	//     "https://www.googleapis.com/auth/cloud-platform",
32473	//     "https://www.googleapis.com/auth/dialogflow"
32474	//   ]
32475	// }
32476
32477}
32478
32479// method id "dialogflow.projects.locations.setAgent":
32480
32481type ProjectsLocationsSetAgentCall struct {
32482	s                            *Service
32483	parent                       string
32484	googleclouddialogflowv2agent *GoogleCloudDialogflowV2Agent
32485	urlParams_                   gensupport.URLParams
32486	ctx_                         context.Context
32487	header_                      http.Header
32488}
32489
32490// SetAgent: Creates/updates the specified agent.
32491//
32492// - parent: The project of this agent. Format: `projects/`.
32493func (r *ProjectsLocationsService) SetAgent(parent string, googleclouddialogflowv2agent *GoogleCloudDialogflowV2Agent) *ProjectsLocationsSetAgentCall {
32494	c := &ProjectsLocationsSetAgentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32495	c.parent = parent
32496	c.googleclouddialogflowv2agent = googleclouddialogflowv2agent
32497	return c
32498}
32499
32500// UpdateMask sets the optional parameter "updateMask": The mask to
32501// control which fields get updated.
32502func (c *ProjectsLocationsSetAgentCall) UpdateMask(updateMask string) *ProjectsLocationsSetAgentCall {
32503	c.urlParams_.Set("updateMask", updateMask)
32504	return c
32505}
32506
32507// Fields allows partial responses to be retrieved. See
32508// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32509// for more information.
32510func (c *ProjectsLocationsSetAgentCall) Fields(s ...googleapi.Field) *ProjectsLocationsSetAgentCall {
32511	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32512	return c
32513}
32514
32515// Context sets the context to be used in this call's Do method. Any
32516// pending HTTP request will be aborted if the provided context is
32517// canceled.
32518func (c *ProjectsLocationsSetAgentCall) Context(ctx context.Context) *ProjectsLocationsSetAgentCall {
32519	c.ctx_ = ctx
32520	return c
32521}
32522
32523// Header returns an http.Header that can be modified by the caller to
32524// add HTTP headers to the request.
32525func (c *ProjectsLocationsSetAgentCall) Header() http.Header {
32526	if c.header_ == nil {
32527		c.header_ = make(http.Header)
32528	}
32529	return c.header_
32530}
32531
32532func (c *ProjectsLocationsSetAgentCall) doRequest(alt string) (*http.Response, error) {
32533	reqHeaders := make(http.Header)
32534	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
32535	for k, v := range c.header_ {
32536		reqHeaders[k] = v
32537	}
32538	reqHeaders.Set("User-Agent", c.s.userAgent())
32539	var body io.Reader = nil
32540	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2agent)
32541	if err != nil {
32542		return nil, err
32543	}
32544	reqHeaders.Set("Content-Type", "application/json")
32545	c.urlParams_.Set("alt", alt)
32546	c.urlParams_.Set("prettyPrint", "false")
32547	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent")
32548	urls += "?" + c.urlParams_.Encode()
32549	req, err := http.NewRequest("POST", urls, body)
32550	if err != nil {
32551		return nil, err
32552	}
32553	req.Header = reqHeaders
32554	googleapi.Expand(req.URL, map[string]string{
32555		"parent": c.parent,
32556	})
32557	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32558}
32559
32560// Do executes the "dialogflow.projects.locations.setAgent" call.
32561// Exactly one of *GoogleCloudDialogflowV2Agent or error will be
32562// non-nil. Any non-2xx status code is an error. Response headers are in
32563// either *GoogleCloudDialogflowV2Agent.ServerResponse.Header or (if a
32564// response was returned at all) in error.(*googleapi.Error).Header. Use
32565// googleapi.IsNotModified to check whether the returned error was
32566// because http.StatusNotModified was returned.
32567func (c *ProjectsLocationsSetAgentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Agent, error) {
32568	gensupport.SetOptions(c.urlParams_, opts...)
32569	res, err := c.doRequest("json")
32570	if res != nil && res.StatusCode == http.StatusNotModified {
32571		if res.Body != nil {
32572			res.Body.Close()
32573		}
32574		return nil, &googleapi.Error{
32575			Code:   res.StatusCode,
32576			Header: res.Header,
32577		}
32578	}
32579	if err != nil {
32580		return nil, err
32581	}
32582	defer googleapi.CloseBody(res)
32583	if err := googleapi.CheckResponse(res); err != nil {
32584		return nil, err
32585	}
32586	ret := &GoogleCloudDialogflowV2Agent{
32587		ServerResponse: googleapi.ServerResponse{
32588			Header:         res.Header,
32589			HTTPStatusCode: res.StatusCode,
32590		},
32591	}
32592	target := &ret
32593	if err := gensupport.DecodeResponse(target, res); err != nil {
32594		return nil, err
32595	}
32596	return ret, nil
32597	// {
32598	//   "description": "Creates/updates the specified agent.",
32599	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent",
32600	//   "httpMethod": "POST",
32601	//   "id": "dialogflow.projects.locations.setAgent",
32602	//   "parameterOrder": [
32603	//     "parent"
32604	//   ],
32605	//   "parameters": {
32606	//     "parent": {
32607	//       "description": "Required. The project of this agent. Format: `projects/`.",
32608	//       "location": "path",
32609	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
32610	//       "required": true,
32611	//       "type": "string"
32612	//     },
32613	//     "updateMask": {
32614	//       "description": "Optional. The mask to control which fields get updated.",
32615	//       "format": "google-fieldmask",
32616	//       "location": "query",
32617	//       "type": "string"
32618	//     }
32619	//   },
32620	//   "path": "v2/{+parent}/agent",
32621	//   "request": {
32622	//     "$ref": "GoogleCloudDialogflowV2Agent"
32623	//   },
32624	//   "response": {
32625	//     "$ref": "GoogleCloudDialogflowV2Agent"
32626	//   },
32627	//   "scopes": [
32628	//     "https://www.googleapis.com/auth/cloud-platform",
32629	//     "https://www.googleapis.com/auth/dialogflow"
32630	//   ]
32631	// }
32632
32633}
32634
32635// method id "dialogflow.projects.locations.agent.export":
32636
32637type ProjectsLocationsAgentExportCall struct {
32638	s                                         *Service
32639	parent                                    string
32640	googleclouddialogflowv2exportagentrequest *GoogleCloudDialogflowV2ExportAgentRequest
32641	urlParams_                                gensupport.URLParams
32642	ctx_                                      context.Context
32643	header_                                   http.Header
32644}
32645
32646// Export: Exports the specified agent to a ZIP file. Operation
32647//
32648// - parent: The project that the agent to export is associated with.
32649//   Format: `projects/`.
32650func (r *ProjectsLocationsAgentService) Export(parent string, googleclouddialogflowv2exportagentrequest *GoogleCloudDialogflowV2ExportAgentRequest) *ProjectsLocationsAgentExportCall {
32651	c := &ProjectsLocationsAgentExportCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32652	c.parent = parent
32653	c.googleclouddialogflowv2exportagentrequest = googleclouddialogflowv2exportagentrequest
32654	return c
32655}
32656
32657// Fields allows partial responses to be retrieved. See
32658// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32659// for more information.
32660func (c *ProjectsLocationsAgentExportCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentExportCall {
32661	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32662	return c
32663}
32664
32665// Context sets the context to be used in this call's Do method. Any
32666// pending HTTP request will be aborted if the provided context is
32667// canceled.
32668func (c *ProjectsLocationsAgentExportCall) Context(ctx context.Context) *ProjectsLocationsAgentExportCall {
32669	c.ctx_ = ctx
32670	return c
32671}
32672
32673// Header returns an http.Header that can be modified by the caller to
32674// add HTTP headers to the request.
32675func (c *ProjectsLocationsAgentExportCall) Header() http.Header {
32676	if c.header_ == nil {
32677		c.header_ = make(http.Header)
32678	}
32679	return c.header_
32680}
32681
32682func (c *ProjectsLocationsAgentExportCall) doRequest(alt string) (*http.Response, error) {
32683	reqHeaders := make(http.Header)
32684	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
32685	for k, v := range c.header_ {
32686		reqHeaders[k] = v
32687	}
32688	reqHeaders.Set("User-Agent", c.s.userAgent())
32689	var body io.Reader = nil
32690	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2exportagentrequest)
32691	if err != nil {
32692		return nil, err
32693	}
32694	reqHeaders.Set("Content-Type", "application/json")
32695	c.urlParams_.Set("alt", alt)
32696	c.urlParams_.Set("prettyPrint", "false")
32697	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:export")
32698	urls += "?" + c.urlParams_.Encode()
32699	req, err := http.NewRequest("POST", urls, body)
32700	if err != nil {
32701		return nil, err
32702	}
32703	req.Header = reqHeaders
32704	googleapi.Expand(req.URL, map[string]string{
32705		"parent": c.parent,
32706	})
32707	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32708}
32709
32710// Do executes the "dialogflow.projects.locations.agent.export" call.
32711// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
32712// Any non-2xx status code is an error. Response headers are in either
32713// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
32714// was returned at all) in error.(*googleapi.Error).Header. Use
32715// googleapi.IsNotModified to check whether the returned error was
32716// because http.StatusNotModified was returned.
32717func (c *ProjectsLocationsAgentExportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
32718	gensupport.SetOptions(c.urlParams_, opts...)
32719	res, err := c.doRequest("json")
32720	if res != nil && res.StatusCode == http.StatusNotModified {
32721		if res.Body != nil {
32722			res.Body.Close()
32723		}
32724		return nil, &googleapi.Error{
32725			Code:   res.StatusCode,
32726			Header: res.Header,
32727		}
32728	}
32729	if err != nil {
32730		return nil, err
32731	}
32732	defer googleapi.CloseBody(res)
32733	if err := googleapi.CheckResponse(res); err != nil {
32734		return nil, err
32735	}
32736	ret := &GoogleLongrunningOperation{
32737		ServerResponse: googleapi.ServerResponse{
32738			Header:         res.Header,
32739			HTTPStatusCode: res.StatusCode,
32740		},
32741	}
32742	target := &ret
32743	if err := gensupport.DecodeResponse(target, res); err != nil {
32744		return nil, err
32745	}
32746	return ret, nil
32747	// {
32748	//   "description": "Exports the specified agent to a ZIP file. Operation ",
32749	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent:export",
32750	//   "httpMethod": "POST",
32751	//   "id": "dialogflow.projects.locations.agent.export",
32752	//   "parameterOrder": [
32753	//     "parent"
32754	//   ],
32755	//   "parameters": {
32756	//     "parent": {
32757	//       "description": "Required. The project that the agent to export is associated with. Format: `projects/`.",
32758	//       "location": "path",
32759	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
32760	//       "required": true,
32761	//       "type": "string"
32762	//     }
32763	//   },
32764	//   "path": "v2/{+parent}/agent:export",
32765	//   "request": {
32766	//     "$ref": "GoogleCloudDialogflowV2ExportAgentRequest"
32767	//   },
32768	//   "response": {
32769	//     "$ref": "GoogleLongrunningOperation"
32770	//   },
32771	//   "scopes": [
32772	//     "https://www.googleapis.com/auth/cloud-platform",
32773	//     "https://www.googleapis.com/auth/dialogflow"
32774	//   ]
32775	// }
32776
32777}
32778
32779// method id "dialogflow.projects.locations.agent.getFulfillment":
32780
32781type ProjectsLocationsAgentGetFulfillmentCall struct {
32782	s            *Service
32783	name         string
32784	urlParams_   gensupport.URLParams
32785	ifNoneMatch_ string
32786	ctx_         context.Context
32787	header_      http.Header
32788}
32789
32790// GetFulfillment: Retrieves the fulfillment.
32791//
32792// - name: The name of the fulfillment. Format:
32793//   `projects//agent/fulfillment`.
32794func (r *ProjectsLocationsAgentService) GetFulfillment(name string) *ProjectsLocationsAgentGetFulfillmentCall {
32795	c := &ProjectsLocationsAgentGetFulfillmentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32796	c.name = name
32797	return c
32798}
32799
32800// Fields allows partial responses to be retrieved. See
32801// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32802// for more information.
32803func (c *ProjectsLocationsAgentGetFulfillmentCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentGetFulfillmentCall {
32804	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32805	return c
32806}
32807
32808// IfNoneMatch sets the optional parameter which makes the operation
32809// fail if the object's ETag matches the given value. This is useful for
32810// getting updates only after the object has changed since the last
32811// request. Use googleapi.IsNotModified to check whether the response
32812// error from Do is the result of In-None-Match.
32813func (c *ProjectsLocationsAgentGetFulfillmentCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentGetFulfillmentCall {
32814	c.ifNoneMatch_ = entityTag
32815	return c
32816}
32817
32818// Context sets the context to be used in this call's Do method. Any
32819// pending HTTP request will be aborted if the provided context is
32820// canceled.
32821func (c *ProjectsLocationsAgentGetFulfillmentCall) Context(ctx context.Context) *ProjectsLocationsAgentGetFulfillmentCall {
32822	c.ctx_ = ctx
32823	return c
32824}
32825
32826// Header returns an http.Header that can be modified by the caller to
32827// add HTTP headers to the request.
32828func (c *ProjectsLocationsAgentGetFulfillmentCall) Header() http.Header {
32829	if c.header_ == nil {
32830		c.header_ = make(http.Header)
32831	}
32832	return c.header_
32833}
32834
32835func (c *ProjectsLocationsAgentGetFulfillmentCall) doRequest(alt string) (*http.Response, error) {
32836	reqHeaders := make(http.Header)
32837	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
32838	for k, v := range c.header_ {
32839		reqHeaders[k] = v
32840	}
32841	reqHeaders.Set("User-Agent", c.s.userAgent())
32842	if c.ifNoneMatch_ != "" {
32843		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32844	}
32845	var body io.Reader = nil
32846	c.urlParams_.Set("alt", alt)
32847	c.urlParams_.Set("prettyPrint", "false")
32848	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
32849	urls += "?" + c.urlParams_.Encode()
32850	req, err := http.NewRequest("GET", urls, body)
32851	if err != nil {
32852		return nil, err
32853	}
32854	req.Header = reqHeaders
32855	googleapi.Expand(req.URL, map[string]string{
32856		"name": c.name,
32857	})
32858	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32859}
32860
32861// Do executes the "dialogflow.projects.locations.agent.getFulfillment" call.
32862// Exactly one of *GoogleCloudDialogflowV2Fulfillment or error will be
32863// non-nil. Any non-2xx status code is an error. Response headers are in
32864// either *GoogleCloudDialogflowV2Fulfillment.ServerResponse.Header or
32865// (if a response was returned at all) in
32866// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
32867// whether the returned error was because http.StatusNotModified was
32868// returned.
32869func (c *ProjectsLocationsAgentGetFulfillmentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Fulfillment, error) {
32870	gensupport.SetOptions(c.urlParams_, opts...)
32871	res, err := c.doRequest("json")
32872	if res != nil && res.StatusCode == http.StatusNotModified {
32873		if res.Body != nil {
32874			res.Body.Close()
32875		}
32876		return nil, &googleapi.Error{
32877			Code:   res.StatusCode,
32878			Header: res.Header,
32879		}
32880	}
32881	if err != nil {
32882		return nil, err
32883	}
32884	defer googleapi.CloseBody(res)
32885	if err := googleapi.CheckResponse(res); err != nil {
32886		return nil, err
32887	}
32888	ret := &GoogleCloudDialogflowV2Fulfillment{
32889		ServerResponse: googleapi.ServerResponse{
32890			Header:         res.Header,
32891			HTTPStatusCode: res.StatusCode,
32892		},
32893	}
32894	target := &ret
32895	if err := gensupport.DecodeResponse(target, res); err != nil {
32896		return nil, err
32897	}
32898	return ret, nil
32899	// {
32900	//   "description": "Retrieves the fulfillment.",
32901	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/fulfillment",
32902	//   "httpMethod": "GET",
32903	//   "id": "dialogflow.projects.locations.agent.getFulfillment",
32904	//   "parameterOrder": [
32905	//     "name"
32906	//   ],
32907	//   "parameters": {
32908	//     "name": {
32909	//       "description": "Required. The name of the fulfillment. Format: `projects//agent/fulfillment`.",
32910	//       "location": "path",
32911	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/fulfillment$",
32912	//       "required": true,
32913	//       "type": "string"
32914	//     }
32915	//   },
32916	//   "path": "v2/{+name}",
32917	//   "response": {
32918	//     "$ref": "GoogleCloudDialogflowV2Fulfillment"
32919	//   },
32920	//   "scopes": [
32921	//     "https://www.googleapis.com/auth/cloud-platform",
32922	//     "https://www.googleapis.com/auth/dialogflow"
32923	//   ]
32924	// }
32925
32926}
32927
32928// method id "dialogflow.projects.locations.agent.getValidationResult":
32929
32930type ProjectsLocationsAgentGetValidationResultCall struct {
32931	s            *Service
32932	parent       string
32933	urlParams_   gensupport.URLParams
32934	ifNoneMatch_ string
32935	ctx_         context.Context
32936	header_      http.Header
32937}
32938
32939// GetValidationResult: Gets agent validation result. Agent validation
32940// is performed during training time and is updated automatically when
32941// training is completed.
32942//
32943// - parent: The project that the agent is associated with. Format:
32944//   `projects/`.
32945func (r *ProjectsLocationsAgentService) GetValidationResult(parent string) *ProjectsLocationsAgentGetValidationResultCall {
32946	c := &ProjectsLocationsAgentGetValidationResultCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32947	c.parent = parent
32948	return c
32949}
32950
32951// LanguageCode sets the optional parameter "languageCode": The language
32952// for which you want a validation result. If not specified, the agent's
32953// default language is used. Many languages
32954// (https://cloud.google.com/dialogflow/docs/reference/language) are
32955// supported. Note: languages must be enabled in the agent before they
32956// can be used.
32957func (c *ProjectsLocationsAgentGetValidationResultCall) LanguageCode(languageCode string) *ProjectsLocationsAgentGetValidationResultCall {
32958	c.urlParams_.Set("languageCode", languageCode)
32959	return c
32960}
32961
32962// Fields allows partial responses to be retrieved. See
32963// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32964// for more information.
32965func (c *ProjectsLocationsAgentGetValidationResultCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentGetValidationResultCall {
32966	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32967	return c
32968}
32969
32970// IfNoneMatch sets the optional parameter which makes the operation
32971// fail if the object's ETag matches the given value. This is useful for
32972// getting updates only after the object has changed since the last
32973// request. Use googleapi.IsNotModified to check whether the response
32974// error from Do is the result of In-None-Match.
32975func (c *ProjectsLocationsAgentGetValidationResultCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentGetValidationResultCall {
32976	c.ifNoneMatch_ = entityTag
32977	return c
32978}
32979
32980// Context sets the context to be used in this call's Do method. Any
32981// pending HTTP request will be aborted if the provided context is
32982// canceled.
32983func (c *ProjectsLocationsAgentGetValidationResultCall) Context(ctx context.Context) *ProjectsLocationsAgentGetValidationResultCall {
32984	c.ctx_ = ctx
32985	return c
32986}
32987
32988// Header returns an http.Header that can be modified by the caller to
32989// add HTTP headers to the request.
32990func (c *ProjectsLocationsAgentGetValidationResultCall) Header() http.Header {
32991	if c.header_ == nil {
32992		c.header_ = make(http.Header)
32993	}
32994	return c.header_
32995}
32996
32997func (c *ProjectsLocationsAgentGetValidationResultCall) doRequest(alt string) (*http.Response, error) {
32998	reqHeaders := make(http.Header)
32999	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
33000	for k, v := range c.header_ {
33001		reqHeaders[k] = v
33002	}
33003	reqHeaders.Set("User-Agent", c.s.userAgent())
33004	if c.ifNoneMatch_ != "" {
33005		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
33006	}
33007	var body io.Reader = nil
33008	c.urlParams_.Set("alt", alt)
33009	c.urlParams_.Set("prettyPrint", "false")
33010	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent/validationResult")
33011	urls += "?" + c.urlParams_.Encode()
33012	req, err := http.NewRequest("GET", urls, body)
33013	if err != nil {
33014		return nil, err
33015	}
33016	req.Header = reqHeaders
33017	googleapi.Expand(req.URL, map[string]string{
33018		"parent": c.parent,
33019	})
33020	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33021}
33022
33023// Do executes the "dialogflow.projects.locations.agent.getValidationResult" call.
33024// Exactly one of *GoogleCloudDialogflowV2ValidationResult or error will
33025// be non-nil. Any non-2xx status code is an error. Response headers are
33026// in either
33027// *GoogleCloudDialogflowV2ValidationResult.ServerResponse.Header or (if
33028// a response was returned at all) in error.(*googleapi.Error).Header.
33029// Use googleapi.IsNotModified to check whether the returned error was
33030// because http.StatusNotModified was returned.
33031func (c *ProjectsLocationsAgentGetValidationResultCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ValidationResult, error) {
33032	gensupport.SetOptions(c.urlParams_, opts...)
33033	res, err := c.doRequest("json")
33034	if res != nil && res.StatusCode == http.StatusNotModified {
33035		if res.Body != nil {
33036			res.Body.Close()
33037		}
33038		return nil, &googleapi.Error{
33039			Code:   res.StatusCode,
33040			Header: res.Header,
33041		}
33042	}
33043	if err != nil {
33044		return nil, err
33045	}
33046	defer googleapi.CloseBody(res)
33047	if err := googleapi.CheckResponse(res); err != nil {
33048		return nil, err
33049	}
33050	ret := &GoogleCloudDialogflowV2ValidationResult{
33051		ServerResponse: googleapi.ServerResponse{
33052			Header:         res.Header,
33053			HTTPStatusCode: res.StatusCode,
33054		},
33055	}
33056	target := &ret
33057	if err := gensupport.DecodeResponse(target, res); err != nil {
33058		return nil, err
33059	}
33060	return ret, nil
33061	// {
33062	//   "description": "Gets agent validation result. Agent validation is performed during training time and is updated automatically when training is completed.",
33063	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/validationResult",
33064	//   "httpMethod": "GET",
33065	//   "id": "dialogflow.projects.locations.agent.getValidationResult",
33066	//   "parameterOrder": [
33067	//     "parent"
33068	//   ],
33069	//   "parameters": {
33070	//     "languageCode": {
33071	//       "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.",
33072	//       "location": "query",
33073	//       "type": "string"
33074	//     },
33075	//     "parent": {
33076	//       "description": "Required. The project that the agent is associated with. Format: `projects/`.",
33077	//       "location": "path",
33078	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
33079	//       "required": true,
33080	//       "type": "string"
33081	//     }
33082	//   },
33083	//   "path": "v2/{+parent}/agent/validationResult",
33084	//   "response": {
33085	//     "$ref": "GoogleCloudDialogflowV2ValidationResult"
33086	//   },
33087	//   "scopes": [
33088	//     "https://www.googleapis.com/auth/cloud-platform",
33089	//     "https://www.googleapis.com/auth/dialogflow"
33090	//   ]
33091	// }
33092
33093}
33094
33095// method id "dialogflow.projects.locations.agent.import":
33096
33097type ProjectsLocationsAgentImportCall struct {
33098	s                                         *Service
33099	parent                                    string
33100	googleclouddialogflowv2importagentrequest *GoogleCloudDialogflowV2ImportAgentRequest
33101	urlParams_                                gensupport.URLParams
33102	ctx_                                      context.Context
33103	header_                                   http.Header
33104}
33105
33106// Import: Imports the specified agent from a ZIP file. Uploads new
33107// intents and entity types without deleting the existing ones. Intents
33108// and entity types with the same name are replaced with the new
33109// versions from ImportAgentRequest. After the import, the imported
33110// draft agent will be trained automatically (unless disabled in agent
33111// settings). However, once the import is done, training may not be
33112// completed yet. Please call TrainAgent and wait for the operation it
33113// returns in order to train explicitly. Operation An operation which
33114// tracks when importing is complete. It only tracks when the draft
33115// agent is updated not when it is done training.
33116//
33117// - parent: The project that the agent to import is associated with.
33118//   Format: `projects/`.
33119func (r *ProjectsLocationsAgentService) Import(parent string, googleclouddialogflowv2importagentrequest *GoogleCloudDialogflowV2ImportAgentRequest) *ProjectsLocationsAgentImportCall {
33120	c := &ProjectsLocationsAgentImportCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33121	c.parent = parent
33122	c.googleclouddialogflowv2importagentrequest = googleclouddialogflowv2importagentrequest
33123	return c
33124}
33125
33126// Fields allows partial responses to be retrieved. See
33127// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33128// for more information.
33129func (c *ProjectsLocationsAgentImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentImportCall {
33130	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33131	return c
33132}
33133
33134// Context sets the context to be used in this call's Do method. Any
33135// pending HTTP request will be aborted if the provided context is
33136// canceled.
33137func (c *ProjectsLocationsAgentImportCall) Context(ctx context.Context) *ProjectsLocationsAgentImportCall {
33138	c.ctx_ = ctx
33139	return c
33140}
33141
33142// Header returns an http.Header that can be modified by the caller to
33143// add HTTP headers to the request.
33144func (c *ProjectsLocationsAgentImportCall) Header() http.Header {
33145	if c.header_ == nil {
33146		c.header_ = make(http.Header)
33147	}
33148	return c.header_
33149}
33150
33151func (c *ProjectsLocationsAgentImportCall) doRequest(alt string) (*http.Response, error) {
33152	reqHeaders := make(http.Header)
33153	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
33154	for k, v := range c.header_ {
33155		reqHeaders[k] = v
33156	}
33157	reqHeaders.Set("User-Agent", c.s.userAgent())
33158	var body io.Reader = nil
33159	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2importagentrequest)
33160	if err != nil {
33161		return nil, err
33162	}
33163	reqHeaders.Set("Content-Type", "application/json")
33164	c.urlParams_.Set("alt", alt)
33165	c.urlParams_.Set("prettyPrint", "false")
33166	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:import")
33167	urls += "?" + c.urlParams_.Encode()
33168	req, err := http.NewRequest("POST", urls, body)
33169	if err != nil {
33170		return nil, err
33171	}
33172	req.Header = reqHeaders
33173	googleapi.Expand(req.URL, map[string]string{
33174		"parent": c.parent,
33175	})
33176	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33177}
33178
33179// Do executes the "dialogflow.projects.locations.agent.import" call.
33180// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
33181// Any non-2xx status code is an error. Response headers are in either
33182// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
33183// was returned at all) in error.(*googleapi.Error).Header. Use
33184// googleapi.IsNotModified to check whether the returned error was
33185// because http.StatusNotModified was returned.
33186func (c *ProjectsLocationsAgentImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
33187	gensupport.SetOptions(c.urlParams_, opts...)
33188	res, err := c.doRequest("json")
33189	if res != nil && res.StatusCode == http.StatusNotModified {
33190		if res.Body != nil {
33191			res.Body.Close()
33192		}
33193		return nil, &googleapi.Error{
33194			Code:   res.StatusCode,
33195			Header: res.Header,
33196		}
33197	}
33198	if err != nil {
33199		return nil, err
33200	}
33201	defer googleapi.CloseBody(res)
33202	if err := googleapi.CheckResponse(res); err != nil {
33203		return nil, err
33204	}
33205	ret := &GoogleLongrunningOperation{
33206		ServerResponse: googleapi.ServerResponse{
33207			Header:         res.Header,
33208			HTTPStatusCode: res.StatusCode,
33209		},
33210	}
33211	target := &ret
33212	if err := gensupport.DecodeResponse(target, res); err != nil {
33213		return nil, err
33214	}
33215	return ret, nil
33216	// {
33217	//   "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. Operation An operation which tracks when importing is complete. It only tracks when the draft agent is updated not when it is done training.",
33218	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent:import",
33219	//   "httpMethod": "POST",
33220	//   "id": "dialogflow.projects.locations.agent.import",
33221	//   "parameterOrder": [
33222	//     "parent"
33223	//   ],
33224	//   "parameters": {
33225	//     "parent": {
33226	//       "description": "Required. The project that the agent to import is associated with. Format: `projects/`.",
33227	//       "location": "path",
33228	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
33229	//       "required": true,
33230	//       "type": "string"
33231	//     }
33232	//   },
33233	//   "path": "v2/{+parent}/agent:import",
33234	//   "request": {
33235	//     "$ref": "GoogleCloudDialogflowV2ImportAgentRequest"
33236	//   },
33237	//   "response": {
33238	//     "$ref": "GoogleLongrunningOperation"
33239	//   },
33240	//   "scopes": [
33241	//     "https://www.googleapis.com/auth/cloud-platform",
33242	//     "https://www.googleapis.com/auth/dialogflow"
33243	//   ]
33244	// }
33245
33246}
33247
33248// method id "dialogflow.projects.locations.agent.restore":
33249
33250type ProjectsLocationsAgentRestoreCall struct {
33251	s                                          *Service
33252	parent                                     string
33253	googleclouddialogflowv2restoreagentrequest *GoogleCloudDialogflowV2RestoreAgentRequest
33254	urlParams_                                 gensupport.URLParams
33255	ctx_                                       context.Context
33256	header_                                    http.Header
33257}
33258
33259// Restore: Restores the specified agent from a ZIP file. Replaces the
33260// current agent version with a new one. All the intents and entity
33261// types in the older version are deleted. After the restore, the
33262// restored draft agent will be trained automatically (unless disabled
33263// in agent settings). However, once the restore is done, training may
33264// not be completed yet. Please call TrainAgent and wait for the
33265// operation it returns in order to train explicitly. Operation An
33266// operation which tracks when restoring is complete. It only tracks
33267// when the draft agent is updated not when it is done training.
33268//
33269// - parent: The project that the agent to restore is associated with.
33270//   Format: `projects/`.
33271func (r *ProjectsLocationsAgentService) Restore(parent string, googleclouddialogflowv2restoreagentrequest *GoogleCloudDialogflowV2RestoreAgentRequest) *ProjectsLocationsAgentRestoreCall {
33272	c := &ProjectsLocationsAgentRestoreCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33273	c.parent = parent
33274	c.googleclouddialogflowv2restoreagentrequest = googleclouddialogflowv2restoreagentrequest
33275	return c
33276}
33277
33278// Fields allows partial responses to be retrieved. See
33279// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33280// for more information.
33281func (c *ProjectsLocationsAgentRestoreCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentRestoreCall {
33282	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33283	return c
33284}
33285
33286// Context sets the context to be used in this call's Do method. Any
33287// pending HTTP request will be aborted if the provided context is
33288// canceled.
33289func (c *ProjectsLocationsAgentRestoreCall) Context(ctx context.Context) *ProjectsLocationsAgentRestoreCall {
33290	c.ctx_ = ctx
33291	return c
33292}
33293
33294// Header returns an http.Header that can be modified by the caller to
33295// add HTTP headers to the request.
33296func (c *ProjectsLocationsAgentRestoreCall) Header() http.Header {
33297	if c.header_ == nil {
33298		c.header_ = make(http.Header)
33299	}
33300	return c.header_
33301}
33302
33303func (c *ProjectsLocationsAgentRestoreCall) doRequest(alt string) (*http.Response, error) {
33304	reqHeaders := make(http.Header)
33305	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
33306	for k, v := range c.header_ {
33307		reqHeaders[k] = v
33308	}
33309	reqHeaders.Set("User-Agent", c.s.userAgent())
33310	var body io.Reader = nil
33311	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2restoreagentrequest)
33312	if err != nil {
33313		return nil, err
33314	}
33315	reqHeaders.Set("Content-Type", "application/json")
33316	c.urlParams_.Set("alt", alt)
33317	c.urlParams_.Set("prettyPrint", "false")
33318	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:restore")
33319	urls += "?" + c.urlParams_.Encode()
33320	req, err := http.NewRequest("POST", urls, body)
33321	if err != nil {
33322		return nil, err
33323	}
33324	req.Header = reqHeaders
33325	googleapi.Expand(req.URL, map[string]string{
33326		"parent": c.parent,
33327	})
33328	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33329}
33330
33331// Do executes the "dialogflow.projects.locations.agent.restore" call.
33332// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
33333// Any non-2xx status code is an error. Response headers are in either
33334// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
33335// was returned at all) in error.(*googleapi.Error).Header. Use
33336// googleapi.IsNotModified to check whether the returned error was
33337// because http.StatusNotModified was returned.
33338func (c *ProjectsLocationsAgentRestoreCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
33339	gensupport.SetOptions(c.urlParams_, opts...)
33340	res, err := c.doRequest("json")
33341	if res != nil && res.StatusCode == http.StatusNotModified {
33342		if res.Body != nil {
33343			res.Body.Close()
33344		}
33345		return nil, &googleapi.Error{
33346			Code:   res.StatusCode,
33347			Header: res.Header,
33348		}
33349	}
33350	if err != nil {
33351		return nil, err
33352	}
33353	defer googleapi.CloseBody(res)
33354	if err := googleapi.CheckResponse(res); err != nil {
33355		return nil, err
33356	}
33357	ret := &GoogleLongrunningOperation{
33358		ServerResponse: googleapi.ServerResponse{
33359			Header:         res.Header,
33360			HTTPStatusCode: res.StatusCode,
33361		},
33362	}
33363	target := &ret
33364	if err := gensupport.DecodeResponse(target, res); err != nil {
33365		return nil, err
33366	}
33367	return ret, nil
33368	// {
33369	//   "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. Operation An operation which tracks when restoring is complete. It only tracks when the draft agent is updated not when it is done training.",
33370	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent:restore",
33371	//   "httpMethod": "POST",
33372	//   "id": "dialogflow.projects.locations.agent.restore",
33373	//   "parameterOrder": [
33374	//     "parent"
33375	//   ],
33376	//   "parameters": {
33377	//     "parent": {
33378	//       "description": "Required. The project that the agent to restore is associated with. Format: `projects/`.",
33379	//       "location": "path",
33380	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
33381	//       "required": true,
33382	//       "type": "string"
33383	//     }
33384	//   },
33385	//   "path": "v2/{+parent}/agent:restore",
33386	//   "request": {
33387	//     "$ref": "GoogleCloudDialogflowV2RestoreAgentRequest"
33388	//   },
33389	//   "response": {
33390	//     "$ref": "GoogleLongrunningOperation"
33391	//   },
33392	//   "scopes": [
33393	//     "https://www.googleapis.com/auth/cloud-platform",
33394	//     "https://www.googleapis.com/auth/dialogflow"
33395	//   ]
33396	// }
33397
33398}
33399
33400// method id "dialogflow.projects.locations.agent.search":
33401
33402type ProjectsLocationsAgentSearchCall struct {
33403	s            *Service
33404	parent       string
33405	urlParams_   gensupport.URLParams
33406	ifNoneMatch_ string
33407	ctx_         context.Context
33408	header_      http.Header
33409}
33410
33411// Search: Returns the list of agents. Since there is at most one
33412// conversational agent per project, this method is useful primarily for
33413// listing all agents across projects the caller has access to. One can
33414// achieve that with a wildcard project collection id "-". Refer to List
33415// Sub-Collections
33416// (https://cloud.google.com/apis/design/design_patterns#list_sub-collections).
33417//
33418// - parent: The project to list agents from. Format: `projects/`.
33419func (r *ProjectsLocationsAgentService) Search(parent string) *ProjectsLocationsAgentSearchCall {
33420	c := &ProjectsLocationsAgentSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33421	c.parent = parent
33422	return c
33423}
33424
33425// PageSize sets the optional parameter "pageSize": The maximum number
33426// of items to return in a single page. By default 100 and at most 1000.
33427func (c *ProjectsLocationsAgentSearchCall) PageSize(pageSize int64) *ProjectsLocationsAgentSearchCall {
33428	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
33429	return c
33430}
33431
33432// PageToken sets the optional parameter "pageToken": The
33433// next_page_token value returned from a previous list request.
33434func (c *ProjectsLocationsAgentSearchCall) PageToken(pageToken string) *ProjectsLocationsAgentSearchCall {
33435	c.urlParams_.Set("pageToken", pageToken)
33436	return c
33437}
33438
33439// Fields allows partial responses to be retrieved. See
33440// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33441// for more information.
33442func (c *ProjectsLocationsAgentSearchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSearchCall {
33443	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33444	return c
33445}
33446
33447// IfNoneMatch sets the optional parameter which makes the operation
33448// fail if the object's ETag matches the given value. This is useful for
33449// getting updates only after the object has changed since the last
33450// request. Use googleapi.IsNotModified to check whether the response
33451// error from Do is the result of In-None-Match.
33452func (c *ProjectsLocationsAgentSearchCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentSearchCall {
33453	c.ifNoneMatch_ = entityTag
33454	return c
33455}
33456
33457// Context sets the context to be used in this call's Do method. Any
33458// pending HTTP request will be aborted if the provided context is
33459// canceled.
33460func (c *ProjectsLocationsAgentSearchCall) Context(ctx context.Context) *ProjectsLocationsAgentSearchCall {
33461	c.ctx_ = ctx
33462	return c
33463}
33464
33465// Header returns an http.Header that can be modified by the caller to
33466// add HTTP headers to the request.
33467func (c *ProjectsLocationsAgentSearchCall) Header() http.Header {
33468	if c.header_ == nil {
33469		c.header_ = make(http.Header)
33470	}
33471	return c.header_
33472}
33473
33474func (c *ProjectsLocationsAgentSearchCall) doRequest(alt string) (*http.Response, error) {
33475	reqHeaders := make(http.Header)
33476	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
33477	for k, v := range c.header_ {
33478		reqHeaders[k] = v
33479	}
33480	reqHeaders.Set("User-Agent", c.s.userAgent())
33481	if c.ifNoneMatch_ != "" {
33482		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
33483	}
33484	var body io.Reader = nil
33485	c.urlParams_.Set("alt", alt)
33486	c.urlParams_.Set("prettyPrint", "false")
33487	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:search")
33488	urls += "?" + c.urlParams_.Encode()
33489	req, err := http.NewRequest("GET", urls, body)
33490	if err != nil {
33491		return nil, err
33492	}
33493	req.Header = reqHeaders
33494	googleapi.Expand(req.URL, map[string]string{
33495		"parent": c.parent,
33496	})
33497	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33498}
33499
33500// Do executes the "dialogflow.projects.locations.agent.search" call.
33501// Exactly one of *GoogleCloudDialogflowV2SearchAgentsResponse or error
33502// will be non-nil. Any non-2xx status code is an error. Response
33503// headers are in either
33504// *GoogleCloudDialogflowV2SearchAgentsResponse.ServerResponse.Header or
33505// (if a response was returned at all) in
33506// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
33507// whether the returned error was because http.StatusNotModified was
33508// returned.
33509func (c *ProjectsLocationsAgentSearchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SearchAgentsResponse, error) {
33510	gensupport.SetOptions(c.urlParams_, opts...)
33511	res, err := c.doRequest("json")
33512	if res != nil && res.StatusCode == http.StatusNotModified {
33513		if res.Body != nil {
33514			res.Body.Close()
33515		}
33516		return nil, &googleapi.Error{
33517			Code:   res.StatusCode,
33518			Header: res.Header,
33519		}
33520	}
33521	if err != nil {
33522		return nil, err
33523	}
33524	defer googleapi.CloseBody(res)
33525	if err := googleapi.CheckResponse(res); err != nil {
33526		return nil, err
33527	}
33528	ret := &GoogleCloudDialogflowV2SearchAgentsResponse{
33529		ServerResponse: googleapi.ServerResponse{
33530			Header:         res.Header,
33531			HTTPStatusCode: res.StatusCode,
33532		},
33533	}
33534	target := &ret
33535	if err := gensupport.DecodeResponse(target, res); err != nil {
33536		return nil, err
33537	}
33538	return ret, nil
33539	// {
33540	//   "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).",
33541	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent:search",
33542	//   "httpMethod": "GET",
33543	//   "id": "dialogflow.projects.locations.agent.search",
33544	//   "parameterOrder": [
33545	//     "parent"
33546	//   ],
33547	//   "parameters": {
33548	//     "pageSize": {
33549	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
33550	//       "format": "int32",
33551	//       "location": "query",
33552	//       "type": "integer"
33553	//     },
33554	//     "pageToken": {
33555	//       "description": "The next_page_token value returned from a previous list request.",
33556	//       "location": "query",
33557	//       "type": "string"
33558	//     },
33559	//     "parent": {
33560	//       "description": "Required. The project to list agents from. Format: `projects/`.",
33561	//       "location": "path",
33562	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
33563	//       "required": true,
33564	//       "type": "string"
33565	//     }
33566	//   },
33567	//   "path": "v2/{+parent}/agent:search",
33568	//   "response": {
33569	//     "$ref": "GoogleCloudDialogflowV2SearchAgentsResponse"
33570	//   },
33571	//   "scopes": [
33572	//     "https://www.googleapis.com/auth/cloud-platform",
33573	//     "https://www.googleapis.com/auth/dialogflow"
33574	//   ]
33575	// }
33576
33577}
33578
33579// Pages invokes f for each page of results.
33580// A non-nil error returned from f will halt the iteration.
33581// The provided context supersedes any context provided to the Context method.
33582func (c *ProjectsLocationsAgentSearchCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2SearchAgentsResponse) error) error {
33583	c.ctx_ = ctx
33584	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
33585	for {
33586		x, err := c.Do()
33587		if err != nil {
33588			return err
33589		}
33590		if err := f(x); err != nil {
33591			return err
33592		}
33593		if x.NextPageToken == "" {
33594			return nil
33595		}
33596		c.PageToken(x.NextPageToken)
33597	}
33598}
33599
33600// method id "dialogflow.projects.locations.agent.train":
33601
33602type ProjectsLocationsAgentTrainCall struct {
33603	s                                        *Service
33604	parent                                   string
33605	googleclouddialogflowv2trainagentrequest *GoogleCloudDialogflowV2TrainAgentRequest
33606	urlParams_                               gensupport.URLParams
33607	ctx_                                     context.Context
33608	header_                                  http.Header
33609}
33610
33611// Train: Trains the specified agent. Operation
33612//
33613// - parent: The project that the agent to train is associated with.
33614//   Format: `projects/`.
33615func (r *ProjectsLocationsAgentService) Train(parent string, googleclouddialogflowv2trainagentrequest *GoogleCloudDialogflowV2TrainAgentRequest) *ProjectsLocationsAgentTrainCall {
33616	c := &ProjectsLocationsAgentTrainCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33617	c.parent = parent
33618	c.googleclouddialogflowv2trainagentrequest = googleclouddialogflowv2trainagentrequest
33619	return c
33620}
33621
33622// Fields allows partial responses to be retrieved. See
33623// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33624// for more information.
33625func (c *ProjectsLocationsAgentTrainCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentTrainCall {
33626	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33627	return c
33628}
33629
33630// Context sets the context to be used in this call's Do method. Any
33631// pending HTTP request will be aborted if the provided context is
33632// canceled.
33633func (c *ProjectsLocationsAgentTrainCall) Context(ctx context.Context) *ProjectsLocationsAgentTrainCall {
33634	c.ctx_ = ctx
33635	return c
33636}
33637
33638// Header returns an http.Header that can be modified by the caller to
33639// add HTTP headers to the request.
33640func (c *ProjectsLocationsAgentTrainCall) Header() http.Header {
33641	if c.header_ == nil {
33642		c.header_ = make(http.Header)
33643	}
33644	return c.header_
33645}
33646
33647func (c *ProjectsLocationsAgentTrainCall) doRequest(alt string) (*http.Response, error) {
33648	reqHeaders := make(http.Header)
33649	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
33650	for k, v := range c.header_ {
33651		reqHeaders[k] = v
33652	}
33653	reqHeaders.Set("User-Agent", c.s.userAgent())
33654	var body io.Reader = nil
33655	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2trainagentrequest)
33656	if err != nil {
33657		return nil, err
33658	}
33659	reqHeaders.Set("Content-Type", "application/json")
33660	c.urlParams_.Set("alt", alt)
33661	c.urlParams_.Set("prettyPrint", "false")
33662	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:train")
33663	urls += "?" + c.urlParams_.Encode()
33664	req, err := http.NewRequest("POST", urls, body)
33665	if err != nil {
33666		return nil, err
33667	}
33668	req.Header = reqHeaders
33669	googleapi.Expand(req.URL, map[string]string{
33670		"parent": c.parent,
33671	})
33672	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33673}
33674
33675// Do executes the "dialogflow.projects.locations.agent.train" call.
33676// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
33677// Any non-2xx status code is an error. Response headers are in either
33678// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
33679// was returned at all) in error.(*googleapi.Error).Header. Use
33680// googleapi.IsNotModified to check whether the returned error was
33681// because http.StatusNotModified was returned.
33682func (c *ProjectsLocationsAgentTrainCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
33683	gensupport.SetOptions(c.urlParams_, opts...)
33684	res, err := c.doRequest("json")
33685	if res != nil && res.StatusCode == http.StatusNotModified {
33686		if res.Body != nil {
33687			res.Body.Close()
33688		}
33689		return nil, &googleapi.Error{
33690			Code:   res.StatusCode,
33691			Header: res.Header,
33692		}
33693	}
33694	if err != nil {
33695		return nil, err
33696	}
33697	defer googleapi.CloseBody(res)
33698	if err := googleapi.CheckResponse(res); err != nil {
33699		return nil, err
33700	}
33701	ret := &GoogleLongrunningOperation{
33702		ServerResponse: googleapi.ServerResponse{
33703			Header:         res.Header,
33704			HTTPStatusCode: res.StatusCode,
33705		},
33706	}
33707	target := &ret
33708	if err := gensupport.DecodeResponse(target, res); err != nil {
33709		return nil, err
33710	}
33711	return ret, nil
33712	// {
33713	//   "description": "Trains the specified agent. Operation ",
33714	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent:train",
33715	//   "httpMethod": "POST",
33716	//   "id": "dialogflow.projects.locations.agent.train",
33717	//   "parameterOrder": [
33718	//     "parent"
33719	//   ],
33720	//   "parameters": {
33721	//     "parent": {
33722	//       "description": "Required. The project that the agent to train is associated with. Format: `projects/`.",
33723	//       "location": "path",
33724	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
33725	//       "required": true,
33726	//       "type": "string"
33727	//     }
33728	//   },
33729	//   "path": "v2/{+parent}/agent:train",
33730	//   "request": {
33731	//     "$ref": "GoogleCloudDialogflowV2TrainAgentRequest"
33732	//   },
33733	//   "response": {
33734	//     "$ref": "GoogleLongrunningOperation"
33735	//   },
33736	//   "scopes": [
33737	//     "https://www.googleapis.com/auth/cloud-platform",
33738	//     "https://www.googleapis.com/auth/dialogflow"
33739	//   ]
33740	// }
33741
33742}
33743
33744// method id "dialogflow.projects.locations.agent.updateFulfillment":
33745
33746type ProjectsLocationsAgentUpdateFulfillmentCall struct {
33747	s                                  *Service
33748	nameid                             string
33749	googleclouddialogflowv2fulfillment *GoogleCloudDialogflowV2Fulfillment
33750	urlParams_                         gensupport.URLParams
33751	ctx_                               context.Context
33752	header_                            http.Header
33753}
33754
33755// UpdateFulfillment: Updates the fulfillment.
33756//
33757// - name: The unique identifier of the fulfillment. Format:
33758//   `projects//agent/fulfillment`.
33759func (r *ProjectsLocationsAgentService) UpdateFulfillment(nameid string, googleclouddialogflowv2fulfillment *GoogleCloudDialogflowV2Fulfillment) *ProjectsLocationsAgentUpdateFulfillmentCall {
33760	c := &ProjectsLocationsAgentUpdateFulfillmentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33761	c.nameid = nameid
33762	c.googleclouddialogflowv2fulfillment = googleclouddialogflowv2fulfillment
33763	return c
33764}
33765
33766// UpdateMask sets the optional parameter "updateMask": Required. The
33767// mask to control which fields get updated. If the mask is not present,
33768// all fields will be updated.
33769func (c *ProjectsLocationsAgentUpdateFulfillmentCall) UpdateMask(updateMask string) *ProjectsLocationsAgentUpdateFulfillmentCall {
33770	c.urlParams_.Set("updateMask", updateMask)
33771	return c
33772}
33773
33774// Fields allows partial responses to be retrieved. See
33775// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33776// for more information.
33777func (c *ProjectsLocationsAgentUpdateFulfillmentCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentUpdateFulfillmentCall {
33778	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33779	return c
33780}
33781
33782// Context sets the context to be used in this call's Do method. Any
33783// pending HTTP request will be aborted if the provided context is
33784// canceled.
33785func (c *ProjectsLocationsAgentUpdateFulfillmentCall) Context(ctx context.Context) *ProjectsLocationsAgentUpdateFulfillmentCall {
33786	c.ctx_ = ctx
33787	return c
33788}
33789
33790// Header returns an http.Header that can be modified by the caller to
33791// add HTTP headers to the request.
33792func (c *ProjectsLocationsAgentUpdateFulfillmentCall) Header() http.Header {
33793	if c.header_ == nil {
33794		c.header_ = make(http.Header)
33795	}
33796	return c.header_
33797}
33798
33799func (c *ProjectsLocationsAgentUpdateFulfillmentCall) doRequest(alt string) (*http.Response, error) {
33800	reqHeaders := make(http.Header)
33801	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
33802	for k, v := range c.header_ {
33803		reqHeaders[k] = v
33804	}
33805	reqHeaders.Set("User-Agent", c.s.userAgent())
33806	var body io.Reader = nil
33807	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2fulfillment)
33808	if err != nil {
33809		return nil, err
33810	}
33811	reqHeaders.Set("Content-Type", "application/json")
33812	c.urlParams_.Set("alt", alt)
33813	c.urlParams_.Set("prettyPrint", "false")
33814	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
33815	urls += "?" + c.urlParams_.Encode()
33816	req, err := http.NewRequest("PATCH", urls, body)
33817	if err != nil {
33818		return nil, err
33819	}
33820	req.Header = reqHeaders
33821	googleapi.Expand(req.URL, map[string]string{
33822		"name": c.nameid,
33823	})
33824	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33825}
33826
33827// Do executes the "dialogflow.projects.locations.agent.updateFulfillment" call.
33828// Exactly one of *GoogleCloudDialogflowV2Fulfillment or error will be
33829// non-nil. Any non-2xx status code is an error. Response headers are in
33830// either *GoogleCloudDialogflowV2Fulfillment.ServerResponse.Header or
33831// (if a response was returned at all) in
33832// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
33833// whether the returned error was because http.StatusNotModified was
33834// returned.
33835func (c *ProjectsLocationsAgentUpdateFulfillmentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Fulfillment, error) {
33836	gensupport.SetOptions(c.urlParams_, opts...)
33837	res, err := c.doRequest("json")
33838	if res != nil && res.StatusCode == http.StatusNotModified {
33839		if res.Body != nil {
33840			res.Body.Close()
33841		}
33842		return nil, &googleapi.Error{
33843			Code:   res.StatusCode,
33844			Header: res.Header,
33845		}
33846	}
33847	if err != nil {
33848		return nil, err
33849	}
33850	defer googleapi.CloseBody(res)
33851	if err := googleapi.CheckResponse(res); err != nil {
33852		return nil, err
33853	}
33854	ret := &GoogleCloudDialogflowV2Fulfillment{
33855		ServerResponse: googleapi.ServerResponse{
33856			Header:         res.Header,
33857			HTTPStatusCode: res.StatusCode,
33858		},
33859	}
33860	target := &ret
33861	if err := gensupport.DecodeResponse(target, res); err != nil {
33862		return nil, err
33863	}
33864	return ret, nil
33865	// {
33866	//   "description": "Updates the fulfillment.",
33867	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/fulfillment",
33868	//   "httpMethod": "PATCH",
33869	//   "id": "dialogflow.projects.locations.agent.updateFulfillment",
33870	//   "parameterOrder": [
33871	//     "name"
33872	//   ],
33873	//   "parameters": {
33874	//     "name": {
33875	//       "description": "Required. The unique identifier of the fulfillment. Format: `projects//agent/fulfillment`.",
33876	//       "location": "path",
33877	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/fulfillment$",
33878	//       "required": true,
33879	//       "type": "string"
33880	//     },
33881	//     "updateMask": {
33882	//       "description": "Required. The mask to control which fields get updated. If the mask is not present, all fields will be updated.",
33883	//       "format": "google-fieldmask",
33884	//       "location": "query",
33885	//       "type": "string"
33886	//     }
33887	//   },
33888	//   "path": "v2/{+name}",
33889	//   "request": {
33890	//     "$ref": "GoogleCloudDialogflowV2Fulfillment"
33891	//   },
33892	//   "response": {
33893	//     "$ref": "GoogleCloudDialogflowV2Fulfillment"
33894	//   },
33895	//   "scopes": [
33896	//     "https://www.googleapis.com/auth/cloud-platform",
33897	//     "https://www.googleapis.com/auth/dialogflow"
33898	//   ]
33899	// }
33900
33901}
33902
33903// method id "dialogflow.projects.locations.agent.entityTypes.batchDelete":
33904
33905type ProjectsLocationsAgentEntityTypesBatchDeleteCall struct {
33906	s                                                    *Service
33907	parent                                               string
33908	googleclouddialogflowv2batchdeleteentitytypesrequest *GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest
33909	urlParams_                                           gensupport.URLParams
33910	ctx_                                                 context.Context
33911	header_                                              http.Header
33912}
33913
33914// BatchDelete: Deletes entity types in the specified agent. Operation
33915//
33916// - parent: The name of the agent to delete all entities types for.
33917//   Format: `projects//agent`.
33918func (r *ProjectsLocationsAgentEntityTypesService) BatchDelete(parent string, googleclouddialogflowv2batchdeleteentitytypesrequest *GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest) *ProjectsLocationsAgentEntityTypesBatchDeleteCall {
33919	c := &ProjectsLocationsAgentEntityTypesBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33920	c.parent = parent
33921	c.googleclouddialogflowv2batchdeleteentitytypesrequest = googleclouddialogflowv2batchdeleteentitytypesrequest
33922	return c
33923}
33924
33925// Fields allows partial responses to be retrieved. See
33926// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33927// for more information.
33928func (c *ProjectsLocationsAgentEntityTypesBatchDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesBatchDeleteCall {
33929	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33930	return c
33931}
33932
33933// Context sets the context to be used in this call's Do method. Any
33934// pending HTTP request will be aborted if the provided context is
33935// canceled.
33936func (c *ProjectsLocationsAgentEntityTypesBatchDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesBatchDeleteCall {
33937	c.ctx_ = ctx
33938	return c
33939}
33940
33941// Header returns an http.Header that can be modified by the caller to
33942// add HTTP headers to the request.
33943func (c *ProjectsLocationsAgentEntityTypesBatchDeleteCall) Header() http.Header {
33944	if c.header_ == nil {
33945		c.header_ = make(http.Header)
33946	}
33947	return c.header_
33948}
33949
33950func (c *ProjectsLocationsAgentEntityTypesBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
33951	reqHeaders := make(http.Header)
33952	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
33953	for k, v := range c.header_ {
33954		reqHeaders[k] = v
33955	}
33956	reqHeaders.Set("User-Agent", c.s.userAgent())
33957	var body io.Reader = nil
33958	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchdeleteentitytypesrequest)
33959	if err != nil {
33960		return nil, err
33961	}
33962	reqHeaders.Set("Content-Type", "application/json")
33963	c.urlParams_.Set("alt", alt)
33964	c.urlParams_.Set("prettyPrint", "false")
33965	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes:batchDelete")
33966	urls += "?" + c.urlParams_.Encode()
33967	req, err := http.NewRequest("POST", urls, body)
33968	if err != nil {
33969		return nil, err
33970	}
33971	req.Header = reqHeaders
33972	googleapi.Expand(req.URL, map[string]string{
33973		"parent": c.parent,
33974	})
33975	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33976}
33977
33978// Do executes the "dialogflow.projects.locations.agent.entityTypes.batchDelete" call.
33979// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
33980// Any non-2xx status code is an error. Response headers are in either
33981// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
33982// was returned at all) in error.(*googleapi.Error).Header. Use
33983// googleapi.IsNotModified to check whether the returned error was
33984// because http.StatusNotModified was returned.
33985func (c *ProjectsLocationsAgentEntityTypesBatchDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
33986	gensupport.SetOptions(c.urlParams_, opts...)
33987	res, err := c.doRequest("json")
33988	if res != nil && res.StatusCode == http.StatusNotModified {
33989		if res.Body != nil {
33990			res.Body.Close()
33991		}
33992		return nil, &googleapi.Error{
33993			Code:   res.StatusCode,
33994			Header: res.Header,
33995		}
33996	}
33997	if err != nil {
33998		return nil, err
33999	}
34000	defer googleapi.CloseBody(res)
34001	if err := googleapi.CheckResponse(res); err != nil {
34002		return nil, err
34003	}
34004	ret := &GoogleLongrunningOperation{
34005		ServerResponse: googleapi.ServerResponse{
34006			Header:         res.Header,
34007			HTTPStatusCode: res.StatusCode,
34008		},
34009	}
34010	target := &ret
34011	if err := gensupport.DecodeResponse(target, res); err != nil {
34012		return nil, err
34013	}
34014	return ret, nil
34015	// {
34016	//   "description": "Deletes entity types in the specified agent. Operation ",
34017	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes:batchDelete",
34018	//   "httpMethod": "POST",
34019	//   "id": "dialogflow.projects.locations.agent.entityTypes.batchDelete",
34020	//   "parameterOrder": [
34021	//     "parent"
34022	//   ],
34023	//   "parameters": {
34024	//     "parent": {
34025	//       "description": "Required. The name of the agent to delete all entities types for. Format: `projects//agent`.",
34026	//       "location": "path",
34027	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
34028	//       "required": true,
34029	//       "type": "string"
34030	//     }
34031	//   },
34032	//   "path": "v2/{+parent}/entityTypes:batchDelete",
34033	//   "request": {
34034	//     "$ref": "GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest"
34035	//   },
34036	//   "response": {
34037	//     "$ref": "GoogleLongrunningOperation"
34038	//   },
34039	//   "scopes": [
34040	//     "https://www.googleapis.com/auth/cloud-platform",
34041	//     "https://www.googleapis.com/auth/dialogflow"
34042	//   ]
34043	// }
34044
34045}
34046
34047// method id "dialogflow.projects.locations.agent.entityTypes.batchUpdate":
34048
34049type ProjectsLocationsAgentEntityTypesBatchUpdateCall struct {
34050	s                                                    *Service
34051	parent                                               string
34052	googleclouddialogflowv2batchupdateentitytypesrequest *GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest
34053	urlParams_                                           gensupport.URLParams
34054	ctx_                                                 context.Context
34055	header_                                              http.Header
34056}
34057
34058// BatchUpdate: Updates/Creates multiple entity types in the specified
34059// agent. Operation
34060//
34061// - parent: The name of the agent to update or create entity types in.
34062//   Format: `projects//agent`.
34063func (r *ProjectsLocationsAgentEntityTypesService) BatchUpdate(parent string, googleclouddialogflowv2batchupdateentitytypesrequest *GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest) *ProjectsLocationsAgentEntityTypesBatchUpdateCall {
34064	c := &ProjectsLocationsAgentEntityTypesBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34065	c.parent = parent
34066	c.googleclouddialogflowv2batchupdateentitytypesrequest = googleclouddialogflowv2batchupdateentitytypesrequest
34067	return c
34068}
34069
34070// Fields allows partial responses to be retrieved. See
34071// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34072// for more information.
34073func (c *ProjectsLocationsAgentEntityTypesBatchUpdateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesBatchUpdateCall {
34074	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34075	return c
34076}
34077
34078// Context sets the context to be used in this call's Do method. Any
34079// pending HTTP request will be aborted if the provided context is
34080// canceled.
34081func (c *ProjectsLocationsAgentEntityTypesBatchUpdateCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesBatchUpdateCall {
34082	c.ctx_ = ctx
34083	return c
34084}
34085
34086// Header returns an http.Header that can be modified by the caller to
34087// add HTTP headers to the request.
34088func (c *ProjectsLocationsAgentEntityTypesBatchUpdateCall) Header() http.Header {
34089	if c.header_ == nil {
34090		c.header_ = make(http.Header)
34091	}
34092	return c.header_
34093}
34094
34095func (c *ProjectsLocationsAgentEntityTypesBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
34096	reqHeaders := make(http.Header)
34097	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
34098	for k, v := range c.header_ {
34099		reqHeaders[k] = v
34100	}
34101	reqHeaders.Set("User-Agent", c.s.userAgent())
34102	var body io.Reader = nil
34103	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchupdateentitytypesrequest)
34104	if err != nil {
34105		return nil, err
34106	}
34107	reqHeaders.Set("Content-Type", "application/json")
34108	c.urlParams_.Set("alt", alt)
34109	c.urlParams_.Set("prettyPrint", "false")
34110	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes:batchUpdate")
34111	urls += "?" + c.urlParams_.Encode()
34112	req, err := http.NewRequest("POST", urls, body)
34113	if err != nil {
34114		return nil, err
34115	}
34116	req.Header = reqHeaders
34117	googleapi.Expand(req.URL, map[string]string{
34118		"parent": c.parent,
34119	})
34120	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34121}
34122
34123// Do executes the "dialogflow.projects.locations.agent.entityTypes.batchUpdate" call.
34124// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
34125// Any non-2xx status code is an error. Response headers are in either
34126// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
34127// was returned at all) in error.(*googleapi.Error).Header. Use
34128// googleapi.IsNotModified to check whether the returned error was
34129// because http.StatusNotModified was returned.
34130func (c *ProjectsLocationsAgentEntityTypesBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
34131	gensupport.SetOptions(c.urlParams_, opts...)
34132	res, err := c.doRequest("json")
34133	if res != nil && res.StatusCode == http.StatusNotModified {
34134		if res.Body != nil {
34135			res.Body.Close()
34136		}
34137		return nil, &googleapi.Error{
34138			Code:   res.StatusCode,
34139			Header: res.Header,
34140		}
34141	}
34142	if err != nil {
34143		return nil, err
34144	}
34145	defer googleapi.CloseBody(res)
34146	if err := googleapi.CheckResponse(res); err != nil {
34147		return nil, err
34148	}
34149	ret := &GoogleLongrunningOperation{
34150		ServerResponse: googleapi.ServerResponse{
34151			Header:         res.Header,
34152			HTTPStatusCode: res.StatusCode,
34153		},
34154	}
34155	target := &ret
34156	if err := gensupport.DecodeResponse(target, res); err != nil {
34157		return nil, err
34158	}
34159	return ret, nil
34160	// {
34161	//   "description": "Updates/Creates multiple entity types in the specified agent. Operation ",
34162	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes:batchUpdate",
34163	//   "httpMethod": "POST",
34164	//   "id": "dialogflow.projects.locations.agent.entityTypes.batchUpdate",
34165	//   "parameterOrder": [
34166	//     "parent"
34167	//   ],
34168	//   "parameters": {
34169	//     "parent": {
34170	//       "description": "Required. The name of the agent to update or create entity types in. Format: `projects//agent`.",
34171	//       "location": "path",
34172	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
34173	//       "required": true,
34174	//       "type": "string"
34175	//     }
34176	//   },
34177	//   "path": "v2/{+parent}/entityTypes:batchUpdate",
34178	//   "request": {
34179	//     "$ref": "GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest"
34180	//   },
34181	//   "response": {
34182	//     "$ref": "GoogleLongrunningOperation"
34183	//   },
34184	//   "scopes": [
34185	//     "https://www.googleapis.com/auth/cloud-platform",
34186	//     "https://www.googleapis.com/auth/dialogflow"
34187	//   ]
34188	// }
34189
34190}
34191
34192// method id "dialogflow.projects.locations.agent.entityTypes.create":
34193
34194type ProjectsLocationsAgentEntityTypesCreateCall struct {
34195	s                                 *Service
34196	parent                            string
34197	googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType
34198	urlParams_                        gensupport.URLParams
34199	ctx_                              context.Context
34200	header_                           http.Header
34201}
34202
34203// Create: Creates an entity type in the specified agent.
34204//
34205// - parent: The agent to create a entity type for. Format:
34206//   `projects//agent`.
34207func (r *ProjectsLocationsAgentEntityTypesService) Create(parent string, googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType) *ProjectsLocationsAgentEntityTypesCreateCall {
34208	c := &ProjectsLocationsAgentEntityTypesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34209	c.parent = parent
34210	c.googleclouddialogflowv2entitytype = googleclouddialogflowv2entitytype
34211	return c
34212}
34213
34214// LanguageCode sets the optional parameter "languageCode": The language
34215// used to access language-specific data. If not specified, the agent's
34216// default language is used. For more information, see Multilingual
34217// intent and entity data
34218// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
34219func (c *ProjectsLocationsAgentEntityTypesCreateCall) LanguageCode(languageCode string) *ProjectsLocationsAgentEntityTypesCreateCall {
34220	c.urlParams_.Set("languageCode", languageCode)
34221	return c
34222}
34223
34224// Fields allows partial responses to be retrieved. See
34225// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34226// for more information.
34227func (c *ProjectsLocationsAgentEntityTypesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesCreateCall {
34228	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34229	return c
34230}
34231
34232// Context sets the context to be used in this call's Do method. Any
34233// pending HTTP request will be aborted if the provided context is
34234// canceled.
34235func (c *ProjectsLocationsAgentEntityTypesCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesCreateCall {
34236	c.ctx_ = ctx
34237	return c
34238}
34239
34240// Header returns an http.Header that can be modified by the caller to
34241// add HTTP headers to the request.
34242func (c *ProjectsLocationsAgentEntityTypesCreateCall) Header() http.Header {
34243	if c.header_ == nil {
34244		c.header_ = make(http.Header)
34245	}
34246	return c.header_
34247}
34248
34249func (c *ProjectsLocationsAgentEntityTypesCreateCall) doRequest(alt string) (*http.Response, error) {
34250	reqHeaders := make(http.Header)
34251	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
34252	for k, v := range c.header_ {
34253		reqHeaders[k] = v
34254	}
34255	reqHeaders.Set("User-Agent", c.s.userAgent())
34256	var body io.Reader = nil
34257	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2entitytype)
34258	if err != nil {
34259		return nil, err
34260	}
34261	reqHeaders.Set("Content-Type", "application/json")
34262	c.urlParams_.Set("alt", alt)
34263	c.urlParams_.Set("prettyPrint", "false")
34264	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
34265	urls += "?" + c.urlParams_.Encode()
34266	req, err := http.NewRequest("POST", urls, body)
34267	if err != nil {
34268		return nil, err
34269	}
34270	req.Header = reqHeaders
34271	googleapi.Expand(req.URL, map[string]string{
34272		"parent": c.parent,
34273	})
34274	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34275}
34276
34277// Do executes the "dialogflow.projects.locations.agent.entityTypes.create" call.
34278// Exactly one of *GoogleCloudDialogflowV2EntityType or error will be
34279// non-nil. Any non-2xx status code is an error. Response headers are in
34280// either *GoogleCloudDialogflowV2EntityType.ServerResponse.Header or
34281// (if a response was returned at all) in
34282// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
34283// whether the returned error was because http.StatusNotModified was
34284// returned.
34285func (c *ProjectsLocationsAgentEntityTypesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EntityType, error) {
34286	gensupport.SetOptions(c.urlParams_, opts...)
34287	res, err := c.doRequest("json")
34288	if res != nil && res.StatusCode == http.StatusNotModified {
34289		if res.Body != nil {
34290			res.Body.Close()
34291		}
34292		return nil, &googleapi.Error{
34293			Code:   res.StatusCode,
34294			Header: res.Header,
34295		}
34296	}
34297	if err != nil {
34298		return nil, err
34299	}
34300	defer googleapi.CloseBody(res)
34301	if err := googleapi.CheckResponse(res); err != nil {
34302		return nil, err
34303	}
34304	ret := &GoogleCloudDialogflowV2EntityType{
34305		ServerResponse: googleapi.ServerResponse{
34306			Header:         res.Header,
34307			HTTPStatusCode: res.StatusCode,
34308		},
34309	}
34310	target := &ret
34311	if err := gensupport.DecodeResponse(target, res); err != nil {
34312		return nil, err
34313	}
34314	return ret, nil
34315	// {
34316	//   "description": "Creates an entity type in the specified agent.",
34317	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes",
34318	//   "httpMethod": "POST",
34319	//   "id": "dialogflow.projects.locations.agent.entityTypes.create",
34320	//   "parameterOrder": [
34321	//     "parent"
34322	//   ],
34323	//   "parameters": {
34324	//     "languageCode": {
34325	//       "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).",
34326	//       "location": "query",
34327	//       "type": "string"
34328	//     },
34329	//     "parent": {
34330	//       "description": "Required. The agent to create a entity type for. Format: `projects//agent`.",
34331	//       "location": "path",
34332	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
34333	//       "required": true,
34334	//       "type": "string"
34335	//     }
34336	//   },
34337	//   "path": "v2/{+parent}/entityTypes",
34338	//   "request": {
34339	//     "$ref": "GoogleCloudDialogflowV2EntityType"
34340	//   },
34341	//   "response": {
34342	//     "$ref": "GoogleCloudDialogflowV2EntityType"
34343	//   },
34344	//   "scopes": [
34345	//     "https://www.googleapis.com/auth/cloud-platform",
34346	//     "https://www.googleapis.com/auth/dialogflow"
34347	//   ]
34348	// }
34349
34350}
34351
34352// method id "dialogflow.projects.locations.agent.entityTypes.delete":
34353
34354type ProjectsLocationsAgentEntityTypesDeleteCall struct {
34355	s          *Service
34356	name       string
34357	urlParams_ gensupport.URLParams
34358	ctx_       context.Context
34359	header_    http.Header
34360}
34361
34362// Delete: Deletes the specified entity type.
34363//
34364// - name: The name of the entity type to delete. Format:
34365//   `projects//agent/entityTypes/`.
34366func (r *ProjectsLocationsAgentEntityTypesService) Delete(name string) *ProjectsLocationsAgentEntityTypesDeleteCall {
34367	c := &ProjectsLocationsAgentEntityTypesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34368	c.name = name
34369	return c
34370}
34371
34372// Fields allows partial responses to be retrieved. See
34373// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34374// for more information.
34375func (c *ProjectsLocationsAgentEntityTypesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesDeleteCall {
34376	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34377	return c
34378}
34379
34380// Context sets the context to be used in this call's Do method. Any
34381// pending HTTP request will be aborted if the provided context is
34382// canceled.
34383func (c *ProjectsLocationsAgentEntityTypesDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesDeleteCall {
34384	c.ctx_ = ctx
34385	return c
34386}
34387
34388// Header returns an http.Header that can be modified by the caller to
34389// add HTTP headers to the request.
34390func (c *ProjectsLocationsAgentEntityTypesDeleteCall) Header() http.Header {
34391	if c.header_ == nil {
34392		c.header_ = make(http.Header)
34393	}
34394	return c.header_
34395}
34396
34397func (c *ProjectsLocationsAgentEntityTypesDeleteCall) doRequest(alt string) (*http.Response, error) {
34398	reqHeaders := make(http.Header)
34399	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
34400	for k, v := range c.header_ {
34401		reqHeaders[k] = v
34402	}
34403	reqHeaders.Set("User-Agent", c.s.userAgent())
34404	var body io.Reader = nil
34405	c.urlParams_.Set("alt", alt)
34406	c.urlParams_.Set("prettyPrint", "false")
34407	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
34408	urls += "?" + c.urlParams_.Encode()
34409	req, err := http.NewRequest("DELETE", urls, body)
34410	if err != nil {
34411		return nil, err
34412	}
34413	req.Header = reqHeaders
34414	googleapi.Expand(req.URL, map[string]string{
34415		"name": c.name,
34416	})
34417	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34418}
34419
34420// Do executes the "dialogflow.projects.locations.agent.entityTypes.delete" call.
34421// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
34422// non-2xx status code is an error. Response headers are in either
34423// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
34424// returned at all) in error.(*googleapi.Error).Header. Use
34425// googleapi.IsNotModified to check whether the returned error was
34426// because http.StatusNotModified was returned.
34427func (c *ProjectsLocationsAgentEntityTypesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
34428	gensupport.SetOptions(c.urlParams_, opts...)
34429	res, err := c.doRequest("json")
34430	if res != nil && res.StatusCode == http.StatusNotModified {
34431		if res.Body != nil {
34432			res.Body.Close()
34433		}
34434		return nil, &googleapi.Error{
34435			Code:   res.StatusCode,
34436			Header: res.Header,
34437		}
34438	}
34439	if err != nil {
34440		return nil, err
34441	}
34442	defer googleapi.CloseBody(res)
34443	if err := googleapi.CheckResponse(res); err != nil {
34444		return nil, err
34445	}
34446	ret := &GoogleProtobufEmpty{
34447		ServerResponse: googleapi.ServerResponse{
34448			Header:         res.Header,
34449			HTTPStatusCode: res.StatusCode,
34450		},
34451	}
34452	target := &ret
34453	if err := gensupport.DecodeResponse(target, res); err != nil {
34454		return nil, err
34455	}
34456	return ret, nil
34457	// {
34458	//   "description": "Deletes the specified entity type.",
34459	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes/{entityTypesId}",
34460	//   "httpMethod": "DELETE",
34461	//   "id": "dialogflow.projects.locations.agent.entityTypes.delete",
34462	//   "parameterOrder": [
34463	//     "name"
34464	//   ],
34465	//   "parameters": {
34466	//     "name": {
34467	//       "description": "Required. The name of the entity type to delete. Format: `projects//agent/entityTypes/`.",
34468	//       "location": "path",
34469	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/entityTypes/[^/]+$",
34470	//       "required": true,
34471	//       "type": "string"
34472	//     }
34473	//   },
34474	//   "path": "v2/{+name}",
34475	//   "response": {
34476	//     "$ref": "GoogleProtobufEmpty"
34477	//   },
34478	//   "scopes": [
34479	//     "https://www.googleapis.com/auth/cloud-platform",
34480	//     "https://www.googleapis.com/auth/dialogflow"
34481	//   ]
34482	// }
34483
34484}
34485
34486// method id "dialogflow.projects.locations.agent.entityTypes.get":
34487
34488type ProjectsLocationsAgentEntityTypesGetCall struct {
34489	s            *Service
34490	name         string
34491	urlParams_   gensupport.URLParams
34492	ifNoneMatch_ string
34493	ctx_         context.Context
34494	header_      http.Header
34495}
34496
34497// Get: Retrieves the specified entity type.
34498//
34499// - name: The name of the entity type. Format:
34500//   `projects//agent/entityTypes/`.
34501func (r *ProjectsLocationsAgentEntityTypesService) Get(name string) *ProjectsLocationsAgentEntityTypesGetCall {
34502	c := &ProjectsLocationsAgentEntityTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34503	c.name = name
34504	return c
34505}
34506
34507// LanguageCode sets the optional parameter "languageCode": The language
34508// used to access language-specific data. If not specified, the agent's
34509// default language is used. For more information, see Multilingual
34510// intent and entity data
34511// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
34512func (c *ProjectsLocationsAgentEntityTypesGetCall) LanguageCode(languageCode string) *ProjectsLocationsAgentEntityTypesGetCall {
34513	c.urlParams_.Set("languageCode", languageCode)
34514	return c
34515}
34516
34517// Fields allows partial responses to be retrieved. See
34518// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34519// for more information.
34520func (c *ProjectsLocationsAgentEntityTypesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesGetCall {
34521	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34522	return c
34523}
34524
34525// IfNoneMatch sets the optional parameter which makes the operation
34526// fail if the object's ETag matches the given value. This is useful for
34527// getting updates only after the object has changed since the last
34528// request. Use googleapi.IsNotModified to check whether the response
34529// error from Do is the result of In-None-Match.
34530func (c *ProjectsLocationsAgentEntityTypesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEntityTypesGetCall {
34531	c.ifNoneMatch_ = entityTag
34532	return c
34533}
34534
34535// Context sets the context to be used in this call's Do method. Any
34536// pending HTTP request will be aborted if the provided context is
34537// canceled.
34538func (c *ProjectsLocationsAgentEntityTypesGetCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesGetCall {
34539	c.ctx_ = ctx
34540	return c
34541}
34542
34543// Header returns an http.Header that can be modified by the caller to
34544// add HTTP headers to the request.
34545func (c *ProjectsLocationsAgentEntityTypesGetCall) Header() http.Header {
34546	if c.header_ == nil {
34547		c.header_ = make(http.Header)
34548	}
34549	return c.header_
34550}
34551
34552func (c *ProjectsLocationsAgentEntityTypesGetCall) doRequest(alt string) (*http.Response, error) {
34553	reqHeaders := make(http.Header)
34554	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
34555	for k, v := range c.header_ {
34556		reqHeaders[k] = v
34557	}
34558	reqHeaders.Set("User-Agent", c.s.userAgent())
34559	if c.ifNoneMatch_ != "" {
34560		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34561	}
34562	var body io.Reader = nil
34563	c.urlParams_.Set("alt", alt)
34564	c.urlParams_.Set("prettyPrint", "false")
34565	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
34566	urls += "?" + c.urlParams_.Encode()
34567	req, err := http.NewRequest("GET", urls, body)
34568	if err != nil {
34569		return nil, err
34570	}
34571	req.Header = reqHeaders
34572	googleapi.Expand(req.URL, map[string]string{
34573		"name": c.name,
34574	})
34575	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34576}
34577
34578// Do executes the "dialogflow.projects.locations.agent.entityTypes.get" call.
34579// Exactly one of *GoogleCloudDialogflowV2EntityType or error will be
34580// non-nil. Any non-2xx status code is an error. Response headers are in
34581// either *GoogleCloudDialogflowV2EntityType.ServerResponse.Header or
34582// (if a response was returned at all) in
34583// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
34584// whether the returned error was because http.StatusNotModified was
34585// returned.
34586func (c *ProjectsLocationsAgentEntityTypesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EntityType, error) {
34587	gensupport.SetOptions(c.urlParams_, opts...)
34588	res, err := c.doRequest("json")
34589	if res != nil && res.StatusCode == http.StatusNotModified {
34590		if res.Body != nil {
34591			res.Body.Close()
34592		}
34593		return nil, &googleapi.Error{
34594			Code:   res.StatusCode,
34595			Header: res.Header,
34596		}
34597	}
34598	if err != nil {
34599		return nil, err
34600	}
34601	defer googleapi.CloseBody(res)
34602	if err := googleapi.CheckResponse(res); err != nil {
34603		return nil, err
34604	}
34605	ret := &GoogleCloudDialogflowV2EntityType{
34606		ServerResponse: googleapi.ServerResponse{
34607			Header:         res.Header,
34608			HTTPStatusCode: res.StatusCode,
34609		},
34610	}
34611	target := &ret
34612	if err := gensupport.DecodeResponse(target, res); err != nil {
34613		return nil, err
34614	}
34615	return ret, nil
34616	// {
34617	//   "description": "Retrieves the specified entity type.",
34618	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes/{entityTypesId}",
34619	//   "httpMethod": "GET",
34620	//   "id": "dialogflow.projects.locations.agent.entityTypes.get",
34621	//   "parameterOrder": [
34622	//     "name"
34623	//   ],
34624	//   "parameters": {
34625	//     "languageCode": {
34626	//       "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).",
34627	//       "location": "query",
34628	//       "type": "string"
34629	//     },
34630	//     "name": {
34631	//       "description": "Required. The name of the entity type. Format: `projects//agent/entityTypes/`.",
34632	//       "location": "path",
34633	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/entityTypes/[^/]+$",
34634	//       "required": true,
34635	//       "type": "string"
34636	//     }
34637	//   },
34638	//   "path": "v2/{+name}",
34639	//   "response": {
34640	//     "$ref": "GoogleCloudDialogflowV2EntityType"
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.locations.agent.entityTypes.list":
34651
34652type ProjectsLocationsAgentEntityTypesListCall 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 entity types in the specified agent.
34662//
34663// - parent: The agent to list all entity types from. Format:
34664//   `projects//agent`.
34665func (r *ProjectsLocationsAgentEntityTypesService) List(parent string) *ProjectsLocationsAgentEntityTypesListCall {
34666	c := &ProjectsLocationsAgentEntityTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34667	c.parent = parent
34668	return c
34669}
34670
34671// LanguageCode sets the optional parameter "languageCode": The language
34672// used to access language-specific data. If not specified, the agent's
34673// default language is used. For more information, see Multilingual
34674// intent and entity data
34675// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
34676func (c *ProjectsLocationsAgentEntityTypesListCall) LanguageCode(languageCode string) *ProjectsLocationsAgentEntityTypesListCall {
34677	c.urlParams_.Set("languageCode", languageCode)
34678	return c
34679}
34680
34681// PageSize sets the optional parameter "pageSize": The maximum number
34682// of items to return in a single page. By default 100 and at most 1000.
34683func (c *ProjectsLocationsAgentEntityTypesListCall) PageSize(pageSize int64) *ProjectsLocationsAgentEntityTypesListCall {
34684	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
34685	return c
34686}
34687
34688// PageToken sets the optional parameter "pageToken": The
34689// next_page_token value returned from a previous list request.
34690func (c *ProjectsLocationsAgentEntityTypesListCall) PageToken(pageToken string) *ProjectsLocationsAgentEntityTypesListCall {
34691	c.urlParams_.Set("pageToken", pageToken)
34692	return c
34693}
34694
34695// Fields allows partial responses to be retrieved. See
34696// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34697// for more information.
34698func (c *ProjectsLocationsAgentEntityTypesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesListCall {
34699	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34700	return c
34701}
34702
34703// IfNoneMatch sets the optional parameter which makes the operation
34704// fail if the object's ETag matches the given value. This is useful for
34705// getting updates only after the object has changed since the last
34706// request. Use googleapi.IsNotModified to check whether the response
34707// error from Do is the result of In-None-Match.
34708func (c *ProjectsLocationsAgentEntityTypesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEntityTypesListCall {
34709	c.ifNoneMatch_ = entityTag
34710	return c
34711}
34712
34713// Context sets the context to be used in this call's Do method. Any
34714// pending HTTP request will be aborted if the provided context is
34715// canceled.
34716func (c *ProjectsLocationsAgentEntityTypesListCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesListCall {
34717	c.ctx_ = ctx
34718	return c
34719}
34720
34721// Header returns an http.Header that can be modified by the caller to
34722// add HTTP headers to the request.
34723func (c *ProjectsLocationsAgentEntityTypesListCall) Header() http.Header {
34724	if c.header_ == nil {
34725		c.header_ = make(http.Header)
34726	}
34727	return c.header_
34728}
34729
34730func (c *ProjectsLocationsAgentEntityTypesListCall) doRequest(alt string) (*http.Response, error) {
34731	reqHeaders := make(http.Header)
34732	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
34733	for k, v := range c.header_ {
34734		reqHeaders[k] = v
34735	}
34736	reqHeaders.Set("User-Agent", c.s.userAgent())
34737	if c.ifNoneMatch_ != "" {
34738		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34739	}
34740	var body io.Reader = nil
34741	c.urlParams_.Set("alt", alt)
34742	c.urlParams_.Set("prettyPrint", "false")
34743	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
34744	urls += "?" + c.urlParams_.Encode()
34745	req, err := http.NewRequest("GET", urls, body)
34746	if err != nil {
34747		return nil, err
34748	}
34749	req.Header = reqHeaders
34750	googleapi.Expand(req.URL, map[string]string{
34751		"parent": c.parent,
34752	})
34753	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34754}
34755
34756// Do executes the "dialogflow.projects.locations.agent.entityTypes.list" call.
34757// Exactly one of *GoogleCloudDialogflowV2ListEntityTypesResponse or
34758// error will be non-nil. Any non-2xx status code is an error. Response
34759// headers are in either
34760// *GoogleCloudDialogflowV2ListEntityTypesResponse.ServerResponse.Header
34761// or (if a response was returned at all) in
34762// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
34763// whether the returned error was because http.StatusNotModified was
34764// returned.
34765func (c *ProjectsLocationsAgentEntityTypesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListEntityTypesResponse, error) {
34766	gensupport.SetOptions(c.urlParams_, opts...)
34767	res, err := c.doRequest("json")
34768	if res != nil && res.StatusCode == http.StatusNotModified {
34769		if res.Body != nil {
34770			res.Body.Close()
34771		}
34772		return nil, &googleapi.Error{
34773			Code:   res.StatusCode,
34774			Header: res.Header,
34775		}
34776	}
34777	if err != nil {
34778		return nil, err
34779	}
34780	defer googleapi.CloseBody(res)
34781	if err := googleapi.CheckResponse(res); err != nil {
34782		return nil, err
34783	}
34784	ret := &GoogleCloudDialogflowV2ListEntityTypesResponse{
34785		ServerResponse: googleapi.ServerResponse{
34786			Header:         res.Header,
34787			HTTPStatusCode: res.StatusCode,
34788		},
34789	}
34790	target := &ret
34791	if err := gensupport.DecodeResponse(target, res); err != nil {
34792		return nil, err
34793	}
34794	return ret, nil
34795	// {
34796	//   "description": "Returns the list of all entity types in the specified agent.",
34797	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes",
34798	//   "httpMethod": "GET",
34799	//   "id": "dialogflow.projects.locations.agent.entityTypes.list",
34800	//   "parameterOrder": [
34801	//     "parent"
34802	//   ],
34803	//   "parameters": {
34804	//     "languageCode": {
34805	//       "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).",
34806	//       "location": "query",
34807	//       "type": "string"
34808	//     },
34809	//     "pageSize": {
34810	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
34811	//       "format": "int32",
34812	//       "location": "query",
34813	//       "type": "integer"
34814	//     },
34815	//     "pageToken": {
34816	//       "description": "Optional. The next_page_token value returned from a previous list request.",
34817	//       "location": "query",
34818	//       "type": "string"
34819	//     },
34820	//     "parent": {
34821	//       "description": "Required. The agent to list all entity types from. Format: `projects//agent`.",
34822	//       "location": "path",
34823	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
34824	//       "required": true,
34825	//       "type": "string"
34826	//     }
34827	//   },
34828	//   "path": "v2/{+parent}/entityTypes",
34829	//   "response": {
34830	//     "$ref": "GoogleCloudDialogflowV2ListEntityTypesResponse"
34831	//   },
34832	//   "scopes": [
34833	//     "https://www.googleapis.com/auth/cloud-platform",
34834	//     "https://www.googleapis.com/auth/dialogflow"
34835	//   ]
34836	// }
34837
34838}
34839
34840// Pages invokes f for each page of results.
34841// A non-nil error returned from f will halt the iteration.
34842// The provided context supersedes any context provided to the Context method.
34843func (c *ProjectsLocationsAgentEntityTypesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListEntityTypesResponse) error) error {
34844	c.ctx_ = ctx
34845	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
34846	for {
34847		x, err := c.Do()
34848		if err != nil {
34849			return err
34850		}
34851		if err := f(x); err != nil {
34852			return err
34853		}
34854		if x.NextPageToken == "" {
34855			return nil
34856		}
34857		c.PageToken(x.NextPageToken)
34858	}
34859}
34860
34861// method id "dialogflow.projects.locations.agent.entityTypes.patch":
34862
34863type ProjectsLocationsAgentEntityTypesPatchCall struct {
34864	s                                 *Service
34865	nameid                            string
34866	googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType
34867	urlParams_                        gensupport.URLParams
34868	ctx_                              context.Context
34869	header_                           http.Header
34870}
34871
34872// Patch: Updates the specified entity type.
34873//
34874// - name: The unique identifier of the entity type. Required for
34875//   EntityTypes.UpdateEntityType and EntityTypes.BatchUpdateEntityTypes
34876//   methods. Format: `projects//agent/entityTypes/`.
34877func (r *ProjectsLocationsAgentEntityTypesService) Patch(nameid string, googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType) *ProjectsLocationsAgentEntityTypesPatchCall {
34878	c := &ProjectsLocationsAgentEntityTypesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34879	c.nameid = nameid
34880	c.googleclouddialogflowv2entitytype = googleclouddialogflowv2entitytype
34881	return c
34882}
34883
34884// LanguageCode sets the optional parameter "languageCode": The language
34885// used to access language-specific data. If not specified, the agent's
34886// default language is used. For more information, see Multilingual
34887// intent and entity data
34888// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
34889func (c *ProjectsLocationsAgentEntityTypesPatchCall) LanguageCode(languageCode string) *ProjectsLocationsAgentEntityTypesPatchCall {
34890	c.urlParams_.Set("languageCode", languageCode)
34891	return c
34892}
34893
34894// UpdateMask sets the optional parameter "updateMask": The mask to
34895// control which fields get updated.
34896func (c *ProjectsLocationsAgentEntityTypesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentEntityTypesPatchCall {
34897	c.urlParams_.Set("updateMask", updateMask)
34898	return c
34899}
34900
34901// Fields allows partial responses to be retrieved. See
34902// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34903// for more information.
34904func (c *ProjectsLocationsAgentEntityTypesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesPatchCall {
34905	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34906	return c
34907}
34908
34909// Context sets the context to be used in this call's Do method. Any
34910// pending HTTP request will be aborted if the provided context is
34911// canceled.
34912func (c *ProjectsLocationsAgentEntityTypesPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesPatchCall {
34913	c.ctx_ = ctx
34914	return c
34915}
34916
34917// Header returns an http.Header that can be modified by the caller to
34918// add HTTP headers to the request.
34919func (c *ProjectsLocationsAgentEntityTypesPatchCall) Header() http.Header {
34920	if c.header_ == nil {
34921		c.header_ = make(http.Header)
34922	}
34923	return c.header_
34924}
34925
34926func (c *ProjectsLocationsAgentEntityTypesPatchCall) doRequest(alt string) (*http.Response, error) {
34927	reqHeaders := make(http.Header)
34928	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
34929	for k, v := range c.header_ {
34930		reqHeaders[k] = v
34931	}
34932	reqHeaders.Set("User-Agent", c.s.userAgent())
34933	var body io.Reader = nil
34934	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2entitytype)
34935	if err != nil {
34936		return nil, err
34937	}
34938	reqHeaders.Set("Content-Type", "application/json")
34939	c.urlParams_.Set("alt", alt)
34940	c.urlParams_.Set("prettyPrint", "false")
34941	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
34942	urls += "?" + c.urlParams_.Encode()
34943	req, err := http.NewRequest("PATCH", urls, body)
34944	if err != nil {
34945		return nil, err
34946	}
34947	req.Header = reqHeaders
34948	googleapi.Expand(req.URL, map[string]string{
34949		"name": c.nameid,
34950	})
34951	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34952}
34953
34954// Do executes the "dialogflow.projects.locations.agent.entityTypes.patch" call.
34955// Exactly one of *GoogleCloudDialogflowV2EntityType or error will be
34956// non-nil. Any non-2xx status code is an error. Response headers are in
34957// either *GoogleCloudDialogflowV2EntityType.ServerResponse.Header or
34958// (if a response was returned at all) in
34959// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
34960// whether the returned error was because http.StatusNotModified was
34961// returned.
34962func (c *ProjectsLocationsAgentEntityTypesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EntityType, error) {
34963	gensupport.SetOptions(c.urlParams_, opts...)
34964	res, err := c.doRequest("json")
34965	if res != nil && res.StatusCode == http.StatusNotModified {
34966		if res.Body != nil {
34967			res.Body.Close()
34968		}
34969		return nil, &googleapi.Error{
34970			Code:   res.StatusCode,
34971			Header: res.Header,
34972		}
34973	}
34974	if err != nil {
34975		return nil, err
34976	}
34977	defer googleapi.CloseBody(res)
34978	if err := googleapi.CheckResponse(res); err != nil {
34979		return nil, err
34980	}
34981	ret := &GoogleCloudDialogflowV2EntityType{
34982		ServerResponse: googleapi.ServerResponse{
34983			Header:         res.Header,
34984			HTTPStatusCode: res.StatusCode,
34985		},
34986	}
34987	target := &ret
34988	if err := gensupport.DecodeResponse(target, res); err != nil {
34989		return nil, err
34990	}
34991	return ret, nil
34992	// {
34993	//   "description": "Updates the specified entity type.",
34994	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes/{entityTypesId}",
34995	//   "httpMethod": "PATCH",
34996	//   "id": "dialogflow.projects.locations.agent.entityTypes.patch",
34997	//   "parameterOrder": [
34998	//     "name"
34999	//   ],
35000	//   "parameters": {
35001	//     "languageCode": {
35002	//       "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).",
35003	//       "location": "query",
35004	//       "type": "string"
35005	//     },
35006	//     "name": {
35007	//       "description": "The unique identifier of the entity type. Required for EntityTypes.UpdateEntityType and EntityTypes.BatchUpdateEntityTypes methods. Format: `projects//agent/entityTypes/`.",
35008	//       "location": "path",
35009	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/entityTypes/[^/]+$",
35010	//       "required": true,
35011	//       "type": "string"
35012	//     },
35013	//     "updateMask": {
35014	//       "description": "Optional. The mask to control which fields get updated.",
35015	//       "format": "google-fieldmask",
35016	//       "location": "query",
35017	//       "type": "string"
35018	//     }
35019	//   },
35020	//   "path": "v2/{+name}",
35021	//   "request": {
35022	//     "$ref": "GoogleCloudDialogflowV2EntityType"
35023	//   },
35024	//   "response": {
35025	//     "$ref": "GoogleCloudDialogflowV2EntityType"
35026	//   },
35027	//   "scopes": [
35028	//     "https://www.googleapis.com/auth/cloud-platform",
35029	//     "https://www.googleapis.com/auth/dialogflow"
35030	//   ]
35031	// }
35032
35033}
35034
35035// method id "dialogflow.projects.locations.agent.entityTypes.entities.batchCreate":
35036
35037type ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall struct {
35038	s                                                 *Service
35039	parent                                            string
35040	googleclouddialogflowv2batchcreateentitiesrequest *GoogleCloudDialogflowV2BatchCreateEntitiesRequest
35041	urlParams_                                        gensupport.URLParams
35042	ctx_                                              context.Context
35043	header_                                           http.Header
35044}
35045
35046// BatchCreate: Creates multiple new entities in the specified entity
35047// type. Operation
35048//
35049// - parent: The name of the entity type to create entities in. Format:
35050//   `projects//agent/entityTypes/`.
35051func (r *ProjectsLocationsAgentEntityTypesEntitiesService) BatchCreate(parent string, googleclouddialogflowv2batchcreateentitiesrequest *GoogleCloudDialogflowV2BatchCreateEntitiesRequest) *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall {
35052	c := &ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35053	c.parent = parent
35054	c.googleclouddialogflowv2batchcreateentitiesrequest = googleclouddialogflowv2batchcreateentitiesrequest
35055	return c
35056}
35057
35058// Fields allows partial responses to be retrieved. See
35059// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35060// for more information.
35061func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall {
35062	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35063	return c
35064}
35065
35066// Context sets the context to be used in this call's Do method. Any
35067// pending HTTP request will be aborted if the provided context is
35068// canceled.
35069func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall {
35070	c.ctx_ = ctx
35071	return c
35072}
35073
35074// Header returns an http.Header that can be modified by the caller to
35075// add HTTP headers to the request.
35076func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall) Header() http.Header {
35077	if c.header_ == nil {
35078		c.header_ = make(http.Header)
35079	}
35080	return c.header_
35081}
35082
35083func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall) doRequest(alt string) (*http.Response, error) {
35084	reqHeaders := make(http.Header)
35085	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
35086	for k, v := range c.header_ {
35087		reqHeaders[k] = v
35088	}
35089	reqHeaders.Set("User-Agent", c.s.userAgent())
35090	var body io.Reader = nil
35091	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchcreateentitiesrequest)
35092	if err != nil {
35093		return nil, err
35094	}
35095	reqHeaders.Set("Content-Type", "application/json")
35096	c.urlParams_.Set("alt", alt)
35097	c.urlParams_.Set("prettyPrint", "false")
35098	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entities:batchCreate")
35099	urls += "?" + c.urlParams_.Encode()
35100	req, err := http.NewRequest("POST", urls, body)
35101	if err != nil {
35102		return nil, err
35103	}
35104	req.Header = reqHeaders
35105	googleapi.Expand(req.URL, map[string]string{
35106		"parent": c.parent,
35107	})
35108	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35109}
35110
35111// Do executes the "dialogflow.projects.locations.agent.entityTypes.entities.batchCreate" call.
35112// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
35113// Any non-2xx status code is an error. Response headers are in either
35114// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
35115// was returned at all) in error.(*googleapi.Error).Header. Use
35116// googleapi.IsNotModified to check whether the returned error was
35117// because http.StatusNotModified was returned.
35118func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
35119	gensupport.SetOptions(c.urlParams_, opts...)
35120	res, err := c.doRequest("json")
35121	if res != nil && res.StatusCode == http.StatusNotModified {
35122		if res.Body != nil {
35123			res.Body.Close()
35124		}
35125		return nil, &googleapi.Error{
35126			Code:   res.StatusCode,
35127			Header: res.Header,
35128		}
35129	}
35130	if err != nil {
35131		return nil, err
35132	}
35133	defer googleapi.CloseBody(res)
35134	if err := googleapi.CheckResponse(res); err != nil {
35135		return nil, err
35136	}
35137	ret := &GoogleLongrunningOperation{
35138		ServerResponse: googleapi.ServerResponse{
35139			Header:         res.Header,
35140			HTTPStatusCode: res.StatusCode,
35141		},
35142	}
35143	target := &ret
35144	if err := gensupport.DecodeResponse(target, res); err != nil {
35145		return nil, err
35146	}
35147	return ret, nil
35148	// {
35149	//   "description": "Creates multiple new entities in the specified entity type. Operation ",
35150	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes/{entityTypesId}/entities:batchCreate",
35151	//   "httpMethod": "POST",
35152	//   "id": "dialogflow.projects.locations.agent.entityTypes.entities.batchCreate",
35153	//   "parameterOrder": [
35154	//     "parent"
35155	//   ],
35156	//   "parameters": {
35157	//     "parent": {
35158	//       "description": "Required. The name of the entity type to create entities in. Format: `projects//agent/entityTypes/`.",
35159	//       "location": "path",
35160	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/entityTypes/[^/]+$",
35161	//       "required": true,
35162	//       "type": "string"
35163	//     }
35164	//   },
35165	//   "path": "v2/{+parent}/entities:batchCreate",
35166	//   "request": {
35167	//     "$ref": "GoogleCloudDialogflowV2BatchCreateEntitiesRequest"
35168	//   },
35169	//   "response": {
35170	//     "$ref": "GoogleLongrunningOperation"
35171	//   },
35172	//   "scopes": [
35173	//     "https://www.googleapis.com/auth/cloud-platform",
35174	//     "https://www.googleapis.com/auth/dialogflow"
35175	//   ]
35176	// }
35177
35178}
35179
35180// method id "dialogflow.projects.locations.agent.entityTypes.entities.batchDelete":
35181
35182type ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall struct {
35183	s                                                 *Service
35184	parent                                            string
35185	googleclouddialogflowv2batchdeleteentitiesrequest *GoogleCloudDialogflowV2BatchDeleteEntitiesRequest
35186	urlParams_                                        gensupport.URLParams
35187	ctx_                                              context.Context
35188	header_                                           http.Header
35189}
35190
35191// BatchDelete: Deletes entities in the specified entity type. Operation
35192//
35193// - parent: The name of the entity type to delete entries for. Format:
35194//   `projects//agent/entityTypes/`.
35195func (r *ProjectsLocationsAgentEntityTypesEntitiesService) BatchDelete(parent string, googleclouddialogflowv2batchdeleteentitiesrequest *GoogleCloudDialogflowV2BatchDeleteEntitiesRequest) *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall {
35196	c := &ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35197	c.parent = parent
35198	c.googleclouddialogflowv2batchdeleteentitiesrequest = googleclouddialogflowv2batchdeleteentitiesrequest
35199	return c
35200}
35201
35202// Fields allows partial responses to be retrieved. See
35203// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35204// for more information.
35205func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall {
35206	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35207	return c
35208}
35209
35210// Context sets the context to be used in this call's Do method. Any
35211// pending HTTP request will be aborted if the provided context is
35212// canceled.
35213func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall {
35214	c.ctx_ = ctx
35215	return c
35216}
35217
35218// Header returns an http.Header that can be modified by the caller to
35219// add HTTP headers to the request.
35220func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall) Header() http.Header {
35221	if c.header_ == nil {
35222		c.header_ = make(http.Header)
35223	}
35224	return c.header_
35225}
35226
35227func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
35228	reqHeaders := make(http.Header)
35229	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
35230	for k, v := range c.header_ {
35231		reqHeaders[k] = v
35232	}
35233	reqHeaders.Set("User-Agent", c.s.userAgent())
35234	var body io.Reader = nil
35235	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchdeleteentitiesrequest)
35236	if err != nil {
35237		return nil, err
35238	}
35239	reqHeaders.Set("Content-Type", "application/json")
35240	c.urlParams_.Set("alt", alt)
35241	c.urlParams_.Set("prettyPrint", "false")
35242	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entities:batchDelete")
35243	urls += "?" + c.urlParams_.Encode()
35244	req, err := http.NewRequest("POST", urls, body)
35245	if err != nil {
35246		return nil, err
35247	}
35248	req.Header = reqHeaders
35249	googleapi.Expand(req.URL, map[string]string{
35250		"parent": c.parent,
35251	})
35252	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35253}
35254
35255// Do executes the "dialogflow.projects.locations.agent.entityTypes.entities.batchDelete" call.
35256// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
35257// Any non-2xx status code is an error. Response headers are in either
35258// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
35259// was returned at all) in error.(*googleapi.Error).Header. Use
35260// googleapi.IsNotModified to check whether the returned error was
35261// because http.StatusNotModified was returned.
35262func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
35263	gensupport.SetOptions(c.urlParams_, opts...)
35264	res, err := c.doRequest("json")
35265	if res != nil && res.StatusCode == http.StatusNotModified {
35266		if res.Body != nil {
35267			res.Body.Close()
35268		}
35269		return nil, &googleapi.Error{
35270			Code:   res.StatusCode,
35271			Header: res.Header,
35272		}
35273	}
35274	if err != nil {
35275		return nil, err
35276	}
35277	defer googleapi.CloseBody(res)
35278	if err := googleapi.CheckResponse(res); err != nil {
35279		return nil, err
35280	}
35281	ret := &GoogleLongrunningOperation{
35282		ServerResponse: googleapi.ServerResponse{
35283			Header:         res.Header,
35284			HTTPStatusCode: res.StatusCode,
35285		},
35286	}
35287	target := &ret
35288	if err := gensupport.DecodeResponse(target, res); err != nil {
35289		return nil, err
35290	}
35291	return ret, nil
35292	// {
35293	//   "description": "Deletes entities in the specified entity type. Operation ",
35294	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes/{entityTypesId}/entities:batchDelete",
35295	//   "httpMethod": "POST",
35296	//   "id": "dialogflow.projects.locations.agent.entityTypes.entities.batchDelete",
35297	//   "parameterOrder": [
35298	//     "parent"
35299	//   ],
35300	//   "parameters": {
35301	//     "parent": {
35302	//       "description": "Required. The name of the entity type to delete entries for. Format: `projects//agent/entityTypes/`.",
35303	//       "location": "path",
35304	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/entityTypes/[^/]+$",
35305	//       "required": true,
35306	//       "type": "string"
35307	//     }
35308	//   },
35309	//   "path": "v2/{+parent}/entities:batchDelete",
35310	//   "request": {
35311	//     "$ref": "GoogleCloudDialogflowV2BatchDeleteEntitiesRequest"
35312	//   },
35313	//   "response": {
35314	//     "$ref": "GoogleLongrunningOperation"
35315	//   },
35316	//   "scopes": [
35317	//     "https://www.googleapis.com/auth/cloud-platform",
35318	//     "https://www.googleapis.com/auth/dialogflow"
35319	//   ]
35320	// }
35321
35322}
35323
35324// method id "dialogflow.projects.locations.agent.entityTypes.entities.batchUpdate":
35325
35326type ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall struct {
35327	s                                                 *Service
35328	parent                                            string
35329	googleclouddialogflowv2batchupdateentitiesrequest *GoogleCloudDialogflowV2BatchUpdateEntitiesRequest
35330	urlParams_                                        gensupport.URLParams
35331	ctx_                                              context.Context
35332	header_                                           http.Header
35333}
35334
35335// BatchUpdate: Updates or creates multiple entities in the specified
35336// entity type. This method does not affect entities in the entity type
35337// that aren't explicitly specified in the request. Operation
35338//
35339// - parent: The name of the entity type to update or create entities
35340//   in. Format: `projects//agent/entityTypes/`.
35341func (r *ProjectsLocationsAgentEntityTypesEntitiesService) BatchUpdate(parent string, googleclouddialogflowv2batchupdateentitiesrequest *GoogleCloudDialogflowV2BatchUpdateEntitiesRequest) *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall {
35342	c := &ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35343	c.parent = parent
35344	c.googleclouddialogflowv2batchupdateentitiesrequest = googleclouddialogflowv2batchupdateentitiesrequest
35345	return c
35346}
35347
35348// Fields allows partial responses to be retrieved. See
35349// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35350// for more information.
35351func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall {
35352	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35353	return c
35354}
35355
35356// Context sets the context to be used in this call's Do method. Any
35357// pending HTTP request will be aborted if the provided context is
35358// canceled.
35359func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall {
35360	c.ctx_ = ctx
35361	return c
35362}
35363
35364// Header returns an http.Header that can be modified by the caller to
35365// add HTTP headers to the request.
35366func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall) Header() http.Header {
35367	if c.header_ == nil {
35368		c.header_ = make(http.Header)
35369	}
35370	return c.header_
35371}
35372
35373func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
35374	reqHeaders := make(http.Header)
35375	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
35376	for k, v := range c.header_ {
35377		reqHeaders[k] = v
35378	}
35379	reqHeaders.Set("User-Agent", c.s.userAgent())
35380	var body io.Reader = nil
35381	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchupdateentitiesrequest)
35382	if err != nil {
35383		return nil, err
35384	}
35385	reqHeaders.Set("Content-Type", "application/json")
35386	c.urlParams_.Set("alt", alt)
35387	c.urlParams_.Set("prettyPrint", "false")
35388	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entities:batchUpdate")
35389	urls += "?" + c.urlParams_.Encode()
35390	req, err := http.NewRequest("POST", urls, body)
35391	if err != nil {
35392		return nil, err
35393	}
35394	req.Header = reqHeaders
35395	googleapi.Expand(req.URL, map[string]string{
35396		"parent": c.parent,
35397	})
35398	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35399}
35400
35401// Do executes the "dialogflow.projects.locations.agent.entityTypes.entities.batchUpdate" call.
35402// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
35403// Any non-2xx status code is an error. Response headers are in either
35404// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
35405// was returned at all) in error.(*googleapi.Error).Header. Use
35406// googleapi.IsNotModified to check whether the returned error was
35407// because http.StatusNotModified was returned.
35408func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
35409	gensupport.SetOptions(c.urlParams_, opts...)
35410	res, err := c.doRequest("json")
35411	if res != nil && res.StatusCode == http.StatusNotModified {
35412		if res.Body != nil {
35413			res.Body.Close()
35414		}
35415		return nil, &googleapi.Error{
35416			Code:   res.StatusCode,
35417			Header: res.Header,
35418		}
35419	}
35420	if err != nil {
35421		return nil, err
35422	}
35423	defer googleapi.CloseBody(res)
35424	if err := googleapi.CheckResponse(res); err != nil {
35425		return nil, err
35426	}
35427	ret := &GoogleLongrunningOperation{
35428		ServerResponse: googleapi.ServerResponse{
35429			Header:         res.Header,
35430			HTTPStatusCode: res.StatusCode,
35431		},
35432	}
35433	target := &ret
35434	if err := gensupport.DecodeResponse(target, res); err != nil {
35435		return nil, err
35436	}
35437	return ret, nil
35438	// {
35439	//   "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. Operation ",
35440	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes/{entityTypesId}/entities:batchUpdate",
35441	//   "httpMethod": "POST",
35442	//   "id": "dialogflow.projects.locations.agent.entityTypes.entities.batchUpdate",
35443	//   "parameterOrder": [
35444	//     "parent"
35445	//   ],
35446	//   "parameters": {
35447	//     "parent": {
35448	//       "description": "Required. The name of the entity type to update or create entities in. Format: `projects//agent/entityTypes/`.",
35449	//       "location": "path",
35450	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/entityTypes/[^/]+$",
35451	//       "required": true,
35452	//       "type": "string"
35453	//     }
35454	//   },
35455	//   "path": "v2/{+parent}/entities:batchUpdate",
35456	//   "request": {
35457	//     "$ref": "GoogleCloudDialogflowV2BatchUpdateEntitiesRequest"
35458	//   },
35459	//   "response": {
35460	//     "$ref": "GoogleLongrunningOperation"
35461	//   },
35462	//   "scopes": [
35463	//     "https://www.googleapis.com/auth/cloud-platform",
35464	//     "https://www.googleapis.com/auth/dialogflow"
35465	//   ]
35466	// }
35467
35468}
35469
35470// method id "dialogflow.projects.locations.agent.environments.list":
35471
35472type ProjectsLocationsAgentEnvironmentsListCall struct {
35473	s            *Service
35474	parent       string
35475	urlParams_   gensupport.URLParams
35476	ifNoneMatch_ string
35477	ctx_         context.Context
35478	header_      http.Header
35479}
35480
35481// List: Returns the list of all non-draft environments of the specified
35482// agent.
35483//
35484// - parent: The agent to list all environments from. Format:
35485//   `projects//agent`.
35486func (r *ProjectsLocationsAgentEnvironmentsService) List(parent string) *ProjectsLocationsAgentEnvironmentsListCall {
35487	c := &ProjectsLocationsAgentEnvironmentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35488	c.parent = parent
35489	return c
35490}
35491
35492// PageSize sets the optional parameter "pageSize": The maximum number
35493// of items to return in a single page. By default 100 and at most 1000.
35494func (c *ProjectsLocationsAgentEnvironmentsListCall) PageSize(pageSize int64) *ProjectsLocationsAgentEnvironmentsListCall {
35495	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
35496	return c
35497}
35498
35499// PageToken sets the optional parameter "pageToken": The
35500// next_page_token value returned from a previous list request.
35501func (c *ProjectsLocationsAgentEnvironmentsListCall) PageToken(pageToken string) *ProjectsLocationsAgentEnvironmentsListCall {
35502	c.urlParams_.Set("pageToken", pageToken)
35503	return c
35504}
35505
35506// Fields allows partial responses to be retrieved. See
35507// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35508// for more information.
35509func (c *ProjectsLocationsAgentEnvironmentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsListCall {
35510	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35511	return c
35512}
35513
35514// IfNoneMatch sets the optional parameter which makes the operation
35515// fail if the object's ETag matches the given value. This is useful for
35516// getting updates only after the object has changed since the last
35517// request. Use googleapi.IsNotModified to check whether the response
35518// error from Do is the result of In-None-Match.
35519func (c *ProjectsLocationsAgentEnvironmentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsListCall {
35520	c.ifNoneMatch_ = entityTag
35521	return c
35522}
35523
35524// Context sets the context to be used in this call's Do method. Any
35525// pending HTTP request will be aborted if the provided context is
35526// canceled.
35527func (c *ProjectsLocationsAgentEnvironmentsListCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsListCall {
35528	c.ctx_ = ctx
35529	return c
35530}
35531
35532// Header returns an http.Header that can be modified by the caller to
35533// add HTTP headers to the request.
35534func (c *ProjectsLocationsAgentEnvironmentsListCall) Header() http.Header {
35535	if c.header_ == nil {
35536		c.header_ = make(http.Header)
35537	}
35538	return c.header_
35539}
35540
35541func (c *ProjectsLocationsAgentEnvironmentsListCall) doRequest(alt string) (*http.Response, error) {
35542	reqHeaders := make(http.Header)
35543	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
35544	for k, v := range c.header_ {
35545		reqHeaders[k] = v
35546	}
35547	reqHeaders.Set("User-Agent", c.s.userAgent())
35548	if c.ifNoneMatch_ != "" {
35549		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35550	}
35551	var body io.Reader = nil
35552	c.urlParams_.Set("alt", alt)
35553	c.urlParams_.Set("prettyPrint", "false")
35554	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/environments")
35555	urls += "?" + c.urlParams_.Encode()
35556	req, err := http.NewRequest("GET", urls, body)
35557	if err != nil {
35558		return nil, err
35559	}
35560	req.Header = reqHeaders
35561	googleapi.Expand(req.URL, map[string]string{
35562		"parent": c.parent,
35563	})
35564	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35565}
35566
35567// Do executes the "dialogflow.projects.locations.agent.environments.list" call.
35568// Exactly one of *GoogleCloudDialogflowV2ListEnvironmentsResponse or
35569// error will be non-nil. Any non-2xx status code is an error. Response
35570// headers are in either
35571// *GoogleCloudDialogflowV2ListEnvironmentsResponse.ServerResponse.Header
35572//  or (if a response was returned at all) in
35573// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
35574// whether the returned error was because http.StatusNotModified was
35575// returned.
35576func (c *ProjectsLocationsAgentEnvironmentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListEnvironmentsResponse, error) {
35577	gensupport.SetOptions(c.urlParams_, opts...)
35578	res, err := c.doRequest("json")
35579	if res != nil && res.StatusCode == http.StatusNotModified {
35580		if res.Body != nil {
35581			res.Body.Close()
35582		}
35583		return nil, &googleapi.Error{
35584			Code:   res.StatusCode,
35585			Header: res.Header,
35586		}
35587	}
35588	if err != nil {
35589		return nil, err
35590	}
35591	defer googleapi.CloseBody(res)
35592	if err := googleapi.CheckResponse(res); err != nil {
35593		return nil, err
35594	}
35595	ret := &GoogleCloudDialogflowV2ListEnvironmentsResponse{
35596		ServerResponse: googleapi.ServerResponse{
35597			Header:         res.Header,
35598			HTTPStatusCode: res.StatusCode,
35599		},
35600	}
35601	target := &ret
35602	if err := gensupport.DecodeResponse(target, res); err != nil {
35603		return nil, err
35604	}
35605	return ret, nil
35606	// {
35607	//   "description": "Returns the list of all non-draft environments of the specified agent.",
35608	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments",
35609	//   "httpMethod": "GET",
35610	//   "id": "dialogflow.projects.locations.agent.environments.list",
35611	//   "parameterOrder": [
35612	//     "parent"
35613	//   ],
35614	//   "parameters": {
35615	//     "pageSize": {
35616	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
35617	//       "format": "int32",
35618	//       "location": "query",
35619	//       "type": "integer"
35620	//     },
35621	//     "pageToken": {
35622	//       "description": "Optional. The next_page_token value returned from a previous list request.",
35623	//       "location": "query",
35624	//       "type": "string"
35625	//     },
35626	//     "parent": {
35627	//       "description": "Required. The agent to list all environments from. Format: `projects//agent`.",
35628	//       "location": "path",
35629	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
35630	//       "required": true,
35631	//       "type": "string"
35632	//     }
35633	//   },
35634	//   "path": "v2/{+parent}/environments",
35635	//   "response": {
35636	//     "$ref": "GoogleCloudDialogflowV2ListEnvironmentsResponse"
35637	//   },
35638	//   "scopes": [
35639	//     "https://www.googleapis.com/auth/cloud-platform",
35640	//     "https://www.googleapis.com/auth/dialogflow"
35641	//   ]
35642	// }
35643
35644}
35645
35646// Pages invokes f for each page of results.
35647// A non-nil error returned from f will halt the iteration.
35648// The provided context supersedes any context provided to the Context method.
35649func (c *ProjectsLocationsAgentEnvironmentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListEnvironmentsResponse) error) error {
35650	c.ctx_ = ctx
35651	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
35652	for {
35653		x, err := c.Do()
35654		if err != nil {
35655			return err
35656		}
35657		if err := f(x); err != nil {
35658			return err
35659		}
35660		if x.NextPageToken == "" {
35661			return nil
35662		}
35663		c.PageToken(x.NextPageToken)
35664	}
35665}
35666
35667// method id "dialogflow.projects.locations.agent.environments.users.sessions.deleteContexts":
35668
35669type ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall struct {
35670	s          *Service
35671	parent     string
35672	urlParams_ gensupport.URLParams
35673	ctx_       context.Context
35674	header_    http.Header
35675}
35676
35677// DeleteContexts: Deletes all active contexts in the specified session.
35678//
35679// - parent: The name of the session to delete all contexts from.
35680//   Format: `projects//agent/sessions/` or
35681//   `projects//agent/environments//users//sessions/`. If `Environment
35682//   ID` is not specified we assume default 'draft' environment. If
35683//   `User ID` is not specified, we assume default '-' user.
35684func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsService) DeleteContexts(parent string) *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall {
35685	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35686	c.parent = parent
35687	return c
35688}
35689
35690// Fields allows partial responses to be retrieved. See
35691// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35692// for more information.
35693func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall {
35694	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35695	return c
35696}
35697
35698// Context sets the context to be used in this call's Do method. Any
35699// pending HTTP request will be aborted if the provided context is
35700// canceled.
35701func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall {
35702	c.ctx_ = ctx
35703	return c
35704}
35705
35706// Header returns an http.Header that can be modified by the caller to
35707// add HTTP headers to the request.
35708func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall) Header() http.Header {
35709	if c.header_ == nil {
35710		c.header_ = make(http.Header)
35711	}
35712	return c.header_
35713}
35714
35715func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall) doRequest(alt string) (*http.Response, error) {
35716	reqHeaders := make(http.Header)
35717	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
35718	for k, v := range c.header_ {
35719		reqHeaders[k] = v
35720	}
35721	reqHeaders.Set("User-Agent", c.s.userAgent())
35722	var body io.Reader = nil
35723	c.urlParams_.Set("alt", alt)
35724	c.urlParams_.Set("prettyPrint", "false")
35725	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
35726	urls += "?" + c.urlParams_.Encode()
35727	req, err := http.NewRequest("DELETE", urls, body)
35728	if err != nil {
35729		return nil, err
35730	}
35731	req.Header = reqHeaders
35732	googleapi.Expand(req.URL, map[string]string{
35733		"parent": c.parent,
35734	})
35735	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35736}
35737
35738// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.deleteContexts" call.
35739// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
35740// non-2xx status code is an error. Response headers are in either
35741// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
35742// returned at all) in error.(*googleapi.Error).Header. Use
35743// googleapi.IsNotModified to check whether the returned error was
35744// because http.StatusNotModified was returned.
35745func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
35746	gensupport.SetOptions(c.urlParams_, opts...)
35747	res, err := c.doRequest("json")
35748	if res != nil && res.StatusCode == http.StatusNotModified {
35749		if res.Body != nil {
35750			res.Body.Close()
35751		}
35752		return nil, &googleapi.Error{
35753			Code:   res.StatusCode,
35754			Header: res.Header,
35755		}
35756	}
35757	if err != nil {
35758		return nil, err
35759	}
35760	defer googleapi.CloseBody(res)
35761	if err := googleapi.CheckResponse(res); err != nil {
35762		return nil, err
35763	}
35764	ret := &GoogleProtobufEmpty{
35765		ServerResponse: googleapi.ServerResponse{
35766			Header:         res.Header,
35767			HTTPStatusCode: res.StatusCode,
35768		},
35769	}
35770	target := &ret
35771	if err := gensupport.DecodeResponse(target, res); err != nil {
35772		return nil, err
35773	}
35774	return ret, nil
35775	// {
35776	//   "description": "Deletes all active contexts in the specified session.",
35777	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts",
35778	//   "httpMethod": "DELETE",
35779	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.deleteContexts",
35780	//   "parameterOrder": [
35781	//     "parent"
35782	//   ],
35783	//   "parameters": {
35784	//     "parent": {
35785	//       "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.",
35786	//       "location": "path",
35787	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
35788	//       "required": true,
35789	//       "type": "string"
35790	//     }
35791	//   },
35792	//   "path": "v2/{+parent}/contexts",
35793	//   "response": {
35794	//     "$ref": "GoogleProtobufEmpty"
35795	//   },
35796	//   "scopes": [
35797	//     "https://www.googleapis.com/auth/cloud-platform",
35798	//     "https://www.googleapis.com/auth/dialogflow"
35799	//   ]
35800	// }
35801
35802}
35803
35804// method id "dialogflow.projects.locations.agent.environments.users.sessions.detectIntent":
35805
35806type ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall struct {
35807	s                                          *Service
35808	sessionid                                  string
35809	googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest
35810	urlParams_                                 gensupport.URLParams
35811	ctx_                                       context.Context
35812	header_                                    http.Header
35813}
35814
35815// DetectIntent: Processes a natural language query and returns
35816// structured, actionable data as a result. This method is not
35817// idempotent, because it may cause contexts and session entity types to
35818// be updated, which in turn might affect results of future queries.
35819// Note: Always use agent versions for production traffic. See Versions
35820// and environments
35821// (https://cloud.google.com/dialogflow/es/docs/agents-versions).
35822//
35823// - session: The name of the session this query is sent to. Format:
35824//   `projects//agent/sessions/`, or
35825//   `projects//agent/environments//users//sessions/`. If `Environment
35826//   ID` is not specified, we assume default 'draft' environment
35827//   (`Environment ID` might be referred to as environment name at some
35828//   places). If `User ID` is not specified, we are using "-". It's up
35829//   to the API caller to choose an appropriate `Session ID` and `User
35830//   Id`. They can be a random number or some type of user and session
35831//   identifiers (preferably hashed). The length of the `Session ID` and
35832//   `User ID` must not exceed 36 characters. For more information, see
35833//   the API interactions guide
35834//   (https://cloud.google.com/dialogflow/docs/api-overview). Note:
35835//   Always use agent versions for production traffic. See Versions and
35836//   environments
35837//   (https://cloud.google.com/dialogflow/es/docs/agents-versions).
35838func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsService) DetectIntent(sessionid string, googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest) *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall {
35839	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35840	c.sessionid = sessionid
35841	c.googleclouddialogflowv2detectintentrequest = googleclouddialogflowv2detectintentrequest
35842	return c
35843}
35844
35845// Fields allows partial responses to be retrieved. See
35846// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35847// for more information.
35848func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall {
35849	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35850	return c
35851}
35852
35853// Context sets the context to be used in this call's Do method. Any
35854// pending HTTP request will be aborted if the provided context is
35855// canceled.
35856func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall {
35857	c.ctx_ = ctx
35858	return c
35859}
35860
35861// Header returns an http.Header that can be modified by the caller to
35862// add HTTP headers to the request.
35863func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall) Header() http.Header {
35864	if c.header_ == nil {
35865		c.header_ = make(http.Header)
35866	}
35867	return c.header_
35868}
35869
35870func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall) doRequest(alt string) (*http.Response, error) {
35871	reqHeaders := make(http.Header)
35872	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
35873	for k, v := range c.header_ {
35874		reqHeaders[k] = v
35875	}
35876	reqHeaders.Set("User-Agent", c.s.userAgent())
35877	var body io.Reader = nil
35878	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2detectintentrequest)
35879	if err != nil {
35880		return nil, err
35881	}
35882	reqHeaders.Set("Content-Type", "application/json")
35883	c.urlParams_.Set("alt", alt)
35884	c.urlParams_.Set("prettyPrint", "false")
35885	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+session}:detectIntent")
35886	urls += "?" + c.urlParams_.Encode()
35887	req, err := http.NewRequest("POST", urls, body)
35888	if err != nil {
35889		return nil, err
35890	}
35891	req.Header = reqHeaders
35892	googleapi.Expand(req.URL, map[string]string{
35893		"session": c.sessionid,
35894	})
35895	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35896}
35897
35898// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.detectIntent" call.
35899// Exactly one of *GoogleCloudDialogflowV2DetectIntentResponse or error
35900// will be non-nil. Any non-2xx status code is an error. Response
35901// headers are in either
35902// *GoogleCloudDialogflowV2DetectIntentResponse.ServerResponse.Header or
35903// (if a response was returned at all) in
35904// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
35905// whether the returned error was because http.StatusNotModified was
35906// returned.
35907func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2DetectIntentResponse, error) {
35908	gensupport.SetOptions(c.urlParams_, opts...)
35909	res, err := c.doRequest("json")
35910	if res != nil && res.StatusCode == http.StatusNotModified {
35911		if res.Body != nil {
35912			res.Body.Close()
35913		}
35914		return nil, &googleapi.Error{
35915			Code:   res.StatusCode,
35916			Header: res.Header,
35917		}
35918	}
35919	if err != nil {
35920		return nil, err
35921	}
35922	defer googleapi.CloseBody(res)
35923	if err := googleapi.CheckResponse(res); err != nil {
35924		return nil, err
35925	}
35926	ret := &GoogleCloudDialogflowV2DetectIntentResponse{
35927		ServerResponse: googleapi.ServerResponse{
35928			Header:         res.Header,
35929			HTTPStatusCode: res.StatusCode,
35930		},
35931	}
35932	target := &ret
35933	if err := gensupport.DecodeResponse(target, res); err != nil {
35934		return nil, err
35935	}
35936	return ret, nil
35937	// {
35938	//   "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. Note: Always use agent versions for production traffic. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
35939	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}:detectIntent",
35940	//   "httpMethod": "POST",
35941	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.detectIntent",
35942	//   "parameterOrder": [
35943	//     "session"
35944	//   ],
35945	//   "parameters": {
35946	//     "session": {
35947	//       "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).",
35948	//       "location": "path",
35949	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
35950	//       "required": true,
35951	//       "type": "string"
35952	//     }
35953	//   },
35954	//   "path": "v2/{+session}:detectIntent",
35955	//   "request": {
35956	//     "$ref": "GoogleCloudDialogflowV2DetectIntentRequest"
35957	//   },
35958	//   "response": {
35959	//     "$ref": "GoogleCloudDialogflowV2DetectIntentResponse"
35960	//   },
35961	//   "scopes": [
35962	//     "https://www.googleapis.com/auth/cloud-platform",
35963	//     "https://www.googleapis.com/auth/dialogflow"
35964	//   ]
35965	// }
35966
35967}
35968
35969// method id "dialogflow.projects.locations.agent.environments.users.sessions.contexts.create":
35970
35971type ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall struct {
35972	s                              *Service
35973	parent                         string
35974	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
35975	urlParams_                     gensupport.URLParams
35976	ctx_                           context.Context
35977	header_                        http.Header
35978}
35979
35980// Create: Creates a context. If the specified context already exists,
35981// overrides the context.
35982//
35983// - parent: The session to create a context for. Format:
35984//   `projects//agent/sessions/` or
35985//   `projects//agent/environments//users//sessions/`. If `Environment
35986//   ID` is not specified, we assume default 'draft' environment. If
35987//   `User ID` is not specified, we assume default '-' user.
35988func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService) Create(parent string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall {
35989	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35990	c.parent = parent
35991	c.googleclouddialogflowv2context = googleclouddialogflowv2context
35992	return c
35993}
35994
35995// Fields allows partial responses to be retrieved. See
35996// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35997// for more information.
35998func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall {
35999	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36000	return c
36001}
36002
36003// Context sets the context to be used in this call's Do method. Any
36004// pending HTTP request will be aborted if the provided context is
36005// canceled.
36006func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall {
36007	c.ctx_ = ctx
36008	return c
36009}
36010
36011// Header returns an http.Header that can be modified by the caller to
36012// add HTTP headers to the request.
36013func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall) Header() http.Header {
36014	if c.header_ == nil {
36015		c.header_ = make(http.Header)
36016	}
36017	return c.header_
36018}
36019
36020func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall) doRequest(alt string) (*http.Response, error) {
36021	reqHeaders := make(http.Header)
36022	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
36023	for k, v := range c.header_ {
36024		reqHeaders[k] = v
36025	}
36026	reqHeaders.Set("User-Agent", c.s.userAgent())
36027	var body io.Reader = nil
36028	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
36029	if err != nil {
36030		return nil, err
36031	}
36032	reqHeaders.Set("Content-Type", "application/json")
36033	c.urlParams_.Set("alt", alt)
36034	c.urlParams_.Set("prettyPrint", "false")
36035	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
36036	urls += "?" + c.urlParams_.Encode()
36037	req, err := http.NewRequest("POST", urls, body)
36038	if err != nil {
36039		return nil, err
36040	}
36041	req.Header = reqHeaders
36042	googleapi.Expand(req.URL, map[string]string{
36043		"parent": c.parent,
36044	})
36045	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36046}
36047
36048// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.contexts.create" call.
36049// Exactly one of *GoogleCloudDialogflowV2Context or error will be
36050// non-nil. Any non-2xx status code is an error. Response headers are in
36051// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
36052// response was returned at all) in error.(*googleapi.Error).Header. Use
36053// googleapi.IsNotModified to check whether the returned error was
36054// because http.StatusNotModified was returned.
36055func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
36056	gensupport.SetOptions(c.urlParams_, opts...)
36057	res, err := c.doRequest("json")
36058	if res != nil && res.StatusCode == http.StatusNotModified {
36059		if res.Body != nil {
36060			res.Body.Close()
36061		}
36062		return nil, &googleapi.Error{
36063			Code:   res.StatusCode,
36064			Header: res.Header,
36065		}
36066	}
36067	if err != nil {
36068		return nil, err
36069	}
36070	defer googleapi.CloseBody(res)
36071	if err := googleapi.CheckResponse(res); err != nil {
36072		return nil, err
36073	}
36074	ret := &GoogleCloudDialogflowV2Context{
36075		ServerResponse: googleapi.ServerResponse{
36076			Header:         res.Header,
36077			HTTPStatusCode: res.StatusCode,
36078		},
36079	}
36080	target := &ret
36081	if err := gensupport.DecodeResponse(target, res); err != nil {
36082		return nil, err
36083	}
36084	return ret, nil
36085	// {
36086	//   "description": "Creates a context. If the specified context already exists, overrides the context.",
36087	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts",
36088	//   "httpMethod": "POST",
36089	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.contexts.create",
36090	//   "parameterOrder": [
36091	//     "parent"
36092	//   ],
36093	//   "parameters": {
36094	//     "parent": {
36095	//       "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.",
36096	//       "location": "path",
36097	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
36098	//       "required": true,
36099	//       "type": "string"
36100	//     }
36101	//   },
36102	//   "path": "v2/{+parent}/contexts",
36103	//   "request": {
36104	//     "$ref": "GoogleCloudDialogflowV2Context"
36105	//   },
36106	//   "response": {
36107	//     "$ref": "GoogleCloudDialogflowV2Context"
36108	//   },
36109	//   "scopes": [
36110	//     "https://www.googleapis.com/auth/cloud-platform",
36111	//     "https://www.googleapis.com/auth/dialogflow"
36112	//   ]
36113	// }
36114
36115}
36116
36117// method id "dialogflow.projects.locations.agent.environments.users.sessions.contexts.delete":
36118
36119type ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall struct {
36120	s          *Service
36121	name       string
36122	urlParams_ gensupport.URLParams
36123	ctx_       context.Context
36124	header_    http.Header
36125}
36126
36127// Delete: Deletes the specified context.
36128//
36129// - name: The name of the context to delete. Format:
36130//   `projects//agent/sessions//contexts/` or
36131//   `projects//agent/environments//users//sessions//contexts/`. If
36132//   `Environment ID` is not specified, we assume default 'draft'
36133//   environment. If `User ID` is not specified, we assume default '-'
36134//   user.
36135func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService) Delete(name string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall {
36136	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36137	c.name = name
36138	return c
36139}
36140
36141// Fields allows partial responses to be retrieved. See
36142// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36143// for more information.
36144func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall {
36145	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36146	return c
36147}
36148
36149// Context sets the context to be used in this call's Do method. Any
36150// pending HTTP request will be aborted if the provided context is
36151// canceled.
36152func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall {
36153	c.ctx_ = ctx
36154	return c
36155}
36156
36157// Header returns an http.Header that can be modified by the caller to
36158// add HTTP headers to the request.
36159func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall) Header() http.Header {
36160	if c.header_ == nil {
36161		c.header_ = make(http.Header)
36162	}
36163	return c.header_
36164}
36165
36166func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall) doRequest(alt string) (*http.Response, error) {
36167	reqHeaders := make(http.Header)
36168	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
36169	for k, v := range c.header_ {
36170		reqHeaders[k] = v
36171	}
36172	reqHeaders.Set("User-Agent", c.s.userAgent())
36173	var body io.Reader = nil
36174	c.urlParams_.Set("alt", alt)
36175	c.urlParams_.Set("prettyPrint", "false")
36176	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
36177	urls += "?" + c.urlParams_.Encode()
36178	req, err := http.NewRequest("DELETE", urls, body)
36179	if err != nil {
36180		return nil, err
36181	}
36182	req.Header = reqHeaders
36183	googleapi.Expand(req.URL, map[string]string{
36184		"name": c.name,
36185	})
36186	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36187}
36188
36189// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.contexts.delete" call.
36190// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
36191// non-2xx status code is an error. Response headers are in either
36192// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
36193// returned at all) in error.(*googleapi.Error).Header. Use
36194// googleapi.IsNotModified to check whether the returned error was
36195// because http.StatusNotModified was returned.
36196func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
36197	gensupport.SetOptions(c.urlParams_, opts...)
36198	res, err := c.doRequest("json")
36199	if res != nil && res.StatusCode == http.StatusNotModified {
36200		if res.Body != nil {
36201			res.Body.Close()
36202		}
36203		return nil, &googleapi.Error{
36204			Code:   res.StatusCode,
36205			Header: res.Header,
36206		}
36207	}
36208	if err != nil {
36209		return nil, err
36210	}
36211	defer googleapi.CloseBody(res)
36212	if err := googleapi.CheckResponse(res); err != nil {
36213		return nil, err
36214	}
36215	ret := &GoogleProtobufEmpty{
36216		ServerResponse: googleapi.ServerResponse{
36217			Header:         res.Header,
36218			HTTPStatusCode: res.StatusCode,
36219		},
36220	}
36221	target := &ret
36222	if err := gensupport.DecodeResponse(target, res); err != nil {
36223		return nil, err
36224	}
36225	return ret, nil
36226	// {
36227	//   "description": "Deletes the specified context.",
36228	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts/{contextsId}",
36229	//   "httpMethod": "DELETE",
36230	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.contexts.delete",
36231	//   "parameterOrder": [
36232	//     "name"
36233	//   ],
36234	//   "parameters": {
36235	//     "name": {
36236	//       "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.",
36237	//       "location": "path",
36238	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/contexts/[^/]+$",
36239	//       "required": true,
36240	//       "type": "string"
36241	//     }
36242	//   },
36243	//   "path": "v2/{+name}",
36244	//   "response": {
36245	//     "$ref": "GoogleProtobufEmpty"
36246	//   },
36247	//   "scopes": [
36248	//     "https://www.googleapis.com/auth/cloud-platform",
36249	//     "https://www.googleapis.com/auth/dialogflow"
36250	//   ]
36251	// }
36252
36253}
36254
36255// method id "dialogflow.projects.locations.agent.environments.users.sessions.contexts.get":
36256
36257type ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall struct {
36258	s            *Service
36259	name         string
36260	urlParams_   gensupport.URLParams
36261	ifNoneMatch_ string
36262	ctx_         context.Context
36263	header_      http.Header
36264}
36265
36266// Get: Retrieves the specified context.
36267//
36268// - name: The name of the context. Format:
36269//   `projects//agent/sessions//contexts/` or
36270//   `projects//agent/environments//users//sessions//contexts/`. If
36271//   `Environment ID` is not specified, we assume default 'draft'
36272//   environment. If `User ID` is not specified, we assume default '-'
36273//   user.
36274func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService) Get(name string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall {
36275	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36276	c.name = name
36277	return c
36278}
36279
36280// Fields allows partial responses to be retrieved. See
36281// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36282// for more information.
36283func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall {
36284	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36285	return c
36286}
36287
36288// IfNoneMatch sets the optional parameter which makes the operation
36289// fail if the object's ETag matches the given value. This is useful for
36290// getting updates only after the object has changed since the last
36291// request. Use googleapi.IsNotModified to check whether the response
36292// error from Do is the result of In-None-Match.
36293func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall {
36294	c.ifNoneMatch_ = entityTag
36295	return c
36296}
36297
36298// Context sets the context to be used in this call's Do method. Any
36299// pending HTTP request will be aborted if the provided context is
36300// canceled.
36301func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall {
36302	c.ctx_ = ctx
36303	return c
36304}
36305
36306// Header returns an http.Header that can be modified by the caller to
36307// add HTTP headers to the request.
36308func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall) Header() http.Header {
36309	if c.header_ == nil {
36310		c.header_ = make(http.Header)
36311	}
36312	return c.header_
36313}
36314
36315func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall) doRequest(alt string) (*http.Response, error) {
36316	reqHeaders := make(http.Header)
36317	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
36318	for k, v := range c.header_ {
36319		reqHeaders[k] = v
36320	}
36321	reqHeaders.Set("User-Agent", c.s.userAgent())
36322	if c.ifNoneMatch_ != "" {
36323		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36324	}
36325	var body io.Reader = nil
36326	c.urlParams_.Set("alt", alt)
36327	c.urlParams_.Set("prettyPrint", "false")
36328	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
36329	urls += "?" + c.urlParams_.Encode()
36330	req, err := http.NewRequest("GET", urls, body)
36331	if err != nil {
36332		return nil, err
36333	}
36334	req.Header = reqHeaders
36335	googleapi.Expand(req.URL, map[string]string{
36336		"name": c.name,
36337	})
36338	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36339}
36340
36341// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.contexts.get" call.
36342// Exactly one of *GoogleCloudDialogflowV2Context or error will be
36343// non-nil. Any non-2xx status code is an error. Response headers are in
36344// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
36345// response was returned at all) in error.(*googleapi.Error).Header. Use
36346// googleapi.IsNotModified to check whether the returned error was
36347// because http.StatusNotModified was returned.
36348func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
36349	gensupport.SetOptions(c.urlParams_, opts...)
36350	res, err := c.doRequest("json")
36351	if res != nil && res.StatusCode == http.StatusNotModified {
36352		if res.Body != nil {
36353			res.Body.Close()
36354		}
36355		return nil, &googleapi.Error{
36356			Code:   res.StatusCode,
36357			Header: res.Header,
36358		}
36359	}
36360	if err != nil {
36361		return nil, err
36362	}
36363	defer googleapi.CloseBody(res)
36364	if err := googleapi.CheckResponse(res); err != nil {
36365		return nil, err
36366	}
36367	ret := &GoogleCloudDialogflowV2Context{
36368		ServerResponse: googleapi.ServerResponse{
36369			Header:         res.Header,
36370			HTTPStatusCode: res.StatusCode,
36371		},
36372	}
36373	target := &ret
36374	if err := gensupport.DecodeResponse(target, res); err != nil {
36375		return nil, err
36376	}
36377	return ret, nil
36378	// {
36379	//   "description": "Retrieves the specified context.",
36380	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts/{contextsId}",
36381	//   "httpMethod": "GET",
36382	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.contexts.get",
36383	//   "parameterOrder": [
36384	//     "name"
36385	//   ],
36386	//   "parameters": {
36387	//     "name": {
36388	//       "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.",
36389	//       "location": "path",
36390	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/contexts/[^/]+$",
36391	//       "required": true,
36392	//       "type": "string"
36393	//     }
36394	//   },
36395	//   "path": "v2/{+name}",
36396	//   "response": {
36397	//     "$ref": "GoogleCloudDialogflowV2Context"
36398	//   },
36399	//   "scopes": [
36400	//     "https://www.googleapis.com/auth/cloud-platform",
36401	//     "https://www.googleapis.com/auth/dialogflow"
36402	//   ]
36403	// }
36404
36405}
36406
36407// method id "dialogflow.projects.locations.agent.environments.users.sessions.contexts.list":
36408
36409type ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall struct {
36410	s            *Service
36411	parent       string
36412	urlParams_   gensupport.URLParams
36413	ifNoneMatch_ string
36414	ctx_         context.Context
36415	header_      http.Header
36416}
36417
36418// List: Returns the list of all contexts in the specified session.
36419//
36420// - parent: The session to list all contexts from. Format:
36421//   `projects//agent/sessions/` or
36422//   `projects//agent/environments//users//sessions/`. If `Environment
36423//   ID` is not specified, we assume default 'draft' environment. If
36424//   `User ID` is not specified, we assume default '-' user.
36425func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService) List(parent string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall {
36426	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36427	c.parent = parent
36428	return c
36429}
36430
36431// PageSize sets the optional parameter "pageSize": The maximum number
36432// of items to return in a single page. By default 100 and at most 1000.
36433func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) PageSize(pageSize int64) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall {
36434	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
36435	return c
36436}
36437
36438// PageToken sets the optional parameter "pageToken": The
36439// next_page_token value returned from a previous list request.
36440func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) PageToken(pageToken string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall {
36441	c.urlParams_.Set("pageToken", pageToken)
36442	return c
36443}
36444
36445// Fields allows partial responses to be retrieved. See
36446// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36447// for more information.
36448func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall {
36449	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36450	return c
36451}
36452
36453// IfNoneMatch sets the optional parameter which makes the operation
36454// fail if the object's ETag matches the given value. This is useful for
36455// getting updates only after the object has changed since the last
36456// request. Use googleapi.IsNotModified to check whether the response
36457// error from Do is the result of In-None-Match.
36458func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall {
36459	c.ifNoneMatch_ = entityTag
36460	return c
36461}
36462
36463// Context sets the context to be used in this call's Do method. Any
36464// pending HTTP request will be aborted if the provided context is
36465// canceled.
36466func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall {
36467	c.ctx_ = ctx
36468	return c
36469}
36470
36471// Header returns an http.Header that can be modified by the caller to
36472// add HTTP headers to the request.
36473func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) Header() http.Header {
36474	if c.header_ == nil {
36475		c.header_ = make(http.Header)
36476	}
36477	return c.header_
36478}
36479
36480func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) doRequest(alt string) (*http.Response, error) {
36481	reqHeaders := make(http.Header)
36482	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
36483	for k, v := range c.header_ {
36484		reqHeaders[k] = v
36485	}
36486	reqHeaders.Set("User-Agent", c.s.userAgent())
36487	if c.ifNoneMatch_ != "" {
36488		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36489	}
36490	var body io.Reader = nil
36491	c.urlParams_.Set("alt", alt)
36492	c.urlParams_.Set("prettyPrint", "false")
36493	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
36494	urls += "?" + c.urlParams_.Encode()
36495	req, err := http.NewRequest("GET", urls, body)
36496	if err != nil {
36497		return nil, err
36498	}
36499	req.Header = reqHeaders
36500	googleapi.Expand(req.URL, map[string]string{
36501		"parent": c.parent,
36502	})
36503	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36504}
36505
36506// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.contexts.list" call.
36507// Exactly one of *GoogleCloudDialogflowV2ListContextsResponse or error
36508// will be non-nil. Any non-2xx status code is an error. Response
36509// headers are in either
36510// *GoogleCloudDialogflowV2ListContextsResponse.ServerResponse.Header or
36511// (if a response was returned at all) in
36512// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
36513// whether the returned error was because http.StatusNotModified was
36514// returned.
36515func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListContextsResponse, error) {
36516	gensupport.SetOptions(c.urlParams_, opts...)
36517	res, err := c.doRequest("json")
36518	if res != nil && res.StatusCode == http.StatusNotModified {
36519		if res.Body != nil {
36520			res.Body.Close()
36521		}
36522		return nil, &googleapi.Error{
36523			Code:   res.StatusCode,
36524			Header: res.Header,
36525		}
36526	}
36527	if err != nil {
36528		return nil, err
36529	}
36530	defer googleapi.CloseBody(res)
36531	if err := googleapi.CheckResponse(res); err != nil {
36532		return nil, err
36533	}
36534	ret := &GoogleCloudDialogflowV2ListContextsResponse{
36535		ServerResponse: googleapi.ServerResponse{
36536			Header:         res.Header,
36537			HTTPStatusCode: res.StatusCode,
36538		},
36539	}
36540	target := &ret
36541	if err := gensupport.DecodeResponse(target, res); err != nil {
36542		return nil, err
36543	}
36544	return ret, nil
36545	// {
36546	//   "description": "Returns the list of all contexts in the specified session.",
36547	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts",
36548	//   "httpMethod": "GET",
36549	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.contexts.list",
36550	//   "parameterOrder": [
36551	//     "parent"
36552	//   ],
36553	//   "parameters": {
36554	//     "pageSize": {
36555	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
36556	//       "format": "int32",
36557	//       "location": "query",
36558	//       "type": "integer"
36559	//     },
36560	//     "pageToken": {
36561	//       "description": "Optional. The next_page_token value returned from a previous list request.",
36562	//       "location": "query",
36563	//       "type": "string"
36564	//     },
36565	//     "parent": {
36566	//       "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.",
36567	//       "location": "path",
36568	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
36569	//       "required": true,
36570	//       "type": "string"
36571	//     }
36572	//   },
36573	//   "path": "v2/{+parent}/contexts",
36574	//   "response": {
36575	//     "$ref": "GoogleCloudDialogflowV2ListContextsResponse"
36576	//   },
36577	//   "scopes": [
36578	//     "https://www.googleapis.com/auth/cloud-platform",
36579	//     "https://www.googleapis.com/auth/dialogflow"
36580	//   ]
36581	// }
36582
36583}
36584
36585// Pages invokes f for each page of results.
36586// A non-nil error returned from f will halt the iteration.
36587// The provided context supersedes any context provided to the Context method.
36588func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListContextsResponse) error) error {
36589	c.ctx_ = ctx
36590	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
36591	for {
36592		x, err := c.Do()
36593		if err != nil {
36594			return err
36595		}
36596		if err := f(x); err != nil {
36597			return err
36598		}
36599		if x.NextPageToken == "" {
36600			return nil
36601		}
36602		c.PageToken(x.NextPageToken)
36603	}
36604}
36605
36606// method id "dialogflow.projects.locations.agent.environments.users.sessions.contexts.patch":
36607
36608type ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall struct {
36609	s                              *Service
36610	nameid                         string
36611	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
36612	urlParams_                     gensupport.URLParams
36613	ctx_                           context.Context
36614	header_                        http.Header
36615}
36616
36617// Patch: Updates the specified context.
36618//
36619// - name: The unique identifier of the context. Format:
36620//   `projects//agent/sessions//contexts/`, or
36621//   `projects//agent/environments//users//sessions//contexts/`. The
36622//   `Context ID` is always converted to lowercase, may only contain
36623//   characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If
36624//   `Environment ID` is not specified, we assume default 'draft'
36625//   environment. If `User ID` is not specified, we assume default '-'
36626//   user. The following context names are reserved for internal use by
36627//   Dialogflow. You should not use these contexts or create contexts
36628//   with these names: * `__system_counters__` * `*_id_dialog_context` *
36629//   `*_dialog_params_size`.
36630func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService) Patch(nameid string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall {
36631	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36632	c.nameid = nameid
36633	c.googleclouddialogflowv2context = googleclouddialogflowv2context
36634	return c
36635}
36636
36637// UpdateMask sets the optional parameter "updateMask": The mask to
36638// control which fields get updated.
36639func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall {
36640	c.urlParams_.Set("updateMask", updateMask)
36641	return c
36642}
36643
36644// Fields allows partial responses to be retrieved. See
36645// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36646// for more information.
36647func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall {
36648	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36649	return c
36650}
36651
36652// Context sets the context to be used in this call's Do method. Any
36653// pending HTTP request will be aborted if the provided context is
36654// canceled.
36655func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall {
36656	c.ctx_ = ctx
36657	return c
36658}
36659
36660// Header returns an http.Header that can be modified by the caller to
36661// add HTTP headers to the request.
36662func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall) Header() http.Header {
36663	if c.header_ == nil {
36664		c.header_ = make(http.Header)
36665	}
36666	return c.header_
36667}
36668
36669func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall) doRequest(alt string) (*http.Response, error) {
36670	reqHeaders := make(http.Header)
36671	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
36672	for k, v := range c.header_ {
36673		reqHeaders[k] = v
36674	}
36675	reqHeaders.Set("User-Agent", c.s.userAgent())
36676	var body io.Reader = nil
36677	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
36678	if err != nil {
36679		return nil, err
36680	}
36681	reqHeaders.Set("Content-Type", "application/json")
36682	c.urlParams_.Set("alt", alt)
36683	c.urlParams_.Set("prettyPrint", "false")
36684	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
36685	urls += "?" + c.urlParams_.Encode()
36686	req, err := http.NewRequest("PATCH", urls, body)
36687	if err != nil {
36688		return nil, err
36689	}
36690	req.Header = reqHeaders
36691	googleapi.Expand(req.URL, map[string]string{
36692		"name": c.nameid,
36693	})
36694	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36695}
36696
36697// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.contexts.patch" call.
36698// Exactly one of *GoogleCloudDialogflowV2Context or error will be
36699// non-nil. Any non-2xx status code is an error. Response headers are in
36700// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
36701// response was returned at all) in error.(*googleapi.Error).Header. Use
36702// googleapi.IsNotModified to check whether the returned error was
36703// because http.StatusNotModified was returned.
36704func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
36705	gensupport.SetOptions(c.urlParams_, opts...)
36706	res, err := c.doRequest("json")
36707	if res != nil && res.StatusCode == http.StatusNotModified {
36708		if res.Body != nil {
36709			res.Body.Close()
36710		}
36711		return nil, &googleapi.Error{
36712			Code:   res.StatusCode,
36713			Header: res.Header,
36714		}
36715	}
36716	if err != nil {
36717		return nil, err
36718	}
36719	defer googleapi.CloseBody(res)
36720	if err := googleapi.CheckResponse(res); err != nil {
36721		return nil, err
36722	}
36723	ret := &GoogleCloudDialogflowV2Context{
36724		ServerResponse: googleapi.ServerResponse{
36725			Header:         res.Header,
36726			HTTPStatusCode: res.StatusCode,
36727		},
36728	}
36729	target := &ret
36730	if err := gensupport.DecodeResponse(target, res); err != nil {
36731		return nil, err
36732	}
36733	return ret, nil
36734	// {
36735	//   "description": "Updates the specified context.",
36736	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts/{contextsId}",
36737	//   "httpMethod": "PATCH",
36738	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.contexts.patch",
36739	//   "parameterOrder": [
36740	//     "name"
36741	//   ],
36742	//   "parameters": {
36743	//     "name": {
36744	//       "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`",
36745	//       "location": "path",
36746	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/contexts/[^/]+$",
36747	//       "required": true,
36748	//       "type": "string"
36749	//     },
36750	//     "updateMask": {
36751	//       "description": "Optional. The mask to control which fields get updated.",
36752	//       "format": "google-fieldmask",
36753	//       "location": "query",
36754	//       "type": "string"
36755	//     }
36756	//   },
36757	//   "path": "v2/{+name}",
36758	//   "request": {
36759	//     "$ref": "GoogleCloudDialogflowV2Context"
36760	//   },
36761	//   "response": {
36762	//     "$ref": "GoogleCloudDialogflowV2Context"
36763	//   },
36764	//   "scopes": [
36765	//     "https://www.googleapis.com/auth/cloud-platform",
36766	//     "https://www.googleapis.com/auth/dialogflow"
36767	//   ]
36768	// }
36769
36770}
36771
36772// method id "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.create":
36773
36774type ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall struct {
36775	s                                        *Service
36776	parent                                   string
36777	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
36778	urlParams_                               gensupport.URLParams
36779	ctx_                                     context.Context
36780	header_                                  http.Header
36781}
36782
36783// Create: Creates a session entity type. If the specified session
36784// entity type already exists, overrides the session entity type. This
36785// method doesn't work with Google Assistant integration. Contact
36786// Dialogflow support if you need to use session entities with Google
36787// Assistant integration.
36788//
36789// - parent: The session to create a session entity type for. Format:
36790//   `projects//agent/sessions/` or
36791//   `projects//agent/environments//users// sessions/`. If `Environment
36792//   ID` is not specified, we assume default 'draft' environment. If
36793//   `User ID` is not specified, we assume default '-' user.
36794func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService) Create(parent string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall {
36795	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36796	c.parent = parent
36797	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
36798	return c
36799}
36800
36801// Fields allows partial responses to be retrieved. See
36802// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36803// for more information.
36804func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall {
36805	c.urlParams_.Set("fields", googleapi.CombineFields(s))
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 *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall {
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 *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Header() http.Header {
36820	if c.header_ == nil {
36821		c.header_ = make(http.Header)
36822	}
36823	return c.header_
36824}
36825
36826func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) doRequest(alt string) (*http.Response, error) {
36827	reqHeaders := make(http.Header)
36828	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
36829	for k, v := range c.header_ {
36830		reqHeaders[k] = v
36831	}
36832	reqHeaders.Set("User-Agent", c.s.userAgent())
36833	var body io.Reader = nil
36834	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
36835	if err != nil {
36836		return nil, err
36837	}
36838	reqHeaders.Set("Content-Type", "application/json")
36839	c.urlParams_.Set("alt", alt)
36840	c.urlParams_.Set("prettyPrint", "false")
36841	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
36842	urls += "?" + c.urlParams_.Encode()
36843	req, err := http.NewRequest("POST", urls, body)
36844	if err != nil {
36845		return nil, err
36846	}
36847	req.Header = reqHeaders
36848	googleapi.Expand(req.URL, map[string]string{
36849		"parent": c.parent,
36850	})
36851	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36852}
36853
36854// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.create" call.
36855// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
36856// will be non-nil. Any non-2xx status code is an error. Response
36857// headers are in either
36858// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
36859// (if a response was returned at all) in
36860// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
36861// whether the returned error was because http.StatusNotModified was
36862// returned.
36863func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
36864	gensupport.SetOptions(c.urlParams_, opts...)
36865	res, err := c.doRequest("json")
36866	if res != nil && res.StatusCode == http.StatusNotModified {
36867		if res.Body != nil {
36868			res.Body.Close()
36869		}
36870		return nil, &googleapi.Error{
36871			Code:   res.StatusCode,
36872			Header: res.Header,
36873		}
36874	}
36875	if err != nil {
36876		return nil, err
36877	}
36878	defer googleapi.CloseBody(res)
36879	if err := googleapi.CheckResponse(res); err != nil {
36880		return nil, err
36881	}
36882	ret := &GoogleCloudDialogflowV2SessionEntityType{
36883		ServerResponse: googleapi.ServerResponse{
36884			Header:         res.Header,
36885			HTTPStatusCode: res.StatusCode,
36886		},
36887	}
36888	target := &ret
36889	if err := gensupport.DecodeResponse(target, res); err != nil {
36890		return nil, err
36891	}
36892	return ret, nil
36893	// {
36894	//   "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.",
36895	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes",
36896	//   "httpMethod": "POST",
36897	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.create",
36898	//   "parameterOrder": [
36899	//     "parent"
36900	//   ],
36901	//   "parameters": {
36902	//     "parent": {
36903	//       "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.",
36904	//       "location": "path",
36905	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
36906	//       "required": true,
36907	//       "type": "string"
36908	//     }
36909	//   },
36910	//   "path": "v2/{+parent}/entityTypes",
36911	//   "request": {
36912	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
36913	//   },
36914	//   "response": {
36915	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
36916	//   },
36917	//   "scopes": [
36918	//     "https://www.googleapis.com/auth/cloud-platform",
36919	//     "https://www.googleapis.com/auth/dialogflow"
36920	//   ]
36921	// }
36922
36923}
36924
36925// method id "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.delete":
36926
36927type ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall struct {
36928	s          *Service
36929	name       string
36930	urlParams_ gensupport.URLParams
36931	ctx_       context.Context
36932	header_    http.Header
36933}
36934
36935// Delete: Deletes the specified session entity type. This method
36936// doesn't work with Google Assistant integration. Contact Dialogflow
36937// support if you need to use session entities with Google Assistant
36938// integration.
36939//
36940// - name: The name of the entity type to delete. Format:
36941//   `projects//agent/sessions//entityTypes/` or
36942//   `projects//agent/environments//users//sessions//entityTypes/`. If
36943//   `Environment ID` is not specified, we assume default 'draft'
36944//   environment. If `User ID` is not specified, we assume default '-'
36945//   user.
36946func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService) Delete(name string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall {
36947	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36948	c.name = name
36949	return c
36950}
36951
36952// Fields allows partial responses to be retrieved. See
36953// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36954// for more information.
36955func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall {
36956	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36957	return c
36958}
36959
36960// Context sets the context to be used in this call's Do method. Any
36961// pending HTTP request will be aborted if the provided context is
36962// canceled.
36963func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall {
36964	c.ctx_ = ctx
36965	return c
36966}
36967
36968// Header returns an http.Header that can be modified by the caller to
36969// add HTTP headers to the request.
36970func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Header() http.Header {
36971	if c.header_ == nil {
36972		c.header_ = make(http.Header)
36973	}
36974	return c.header_
36975}
36976
36977func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) doRequest(alt string) (*http.Response, error) {
36978	reqHeaders := make(http.Header)
36979	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
36980	for k, v := range c.header_ {
36981		reqHeaders[k] = v
36982	}
36983	reqHeaders.Set("User-Agent", c.s.userAgent())
36984	var body io.Reader = nil
36985	c.urlParams_.Set("alt", alt)
36986	c.urlParams_.Set("prettyPrint", "false")
36987	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
36988	urls += "?" + c.urlParams_.Encode()
36989	req, err := http.NewRequest("DELETE", urls, body)
36990	if err != nil {
36991		return nil, err
36992	}
36993	req.Header = reqHeaders
36994	googleapi.Expand(req.URL, map[string]string{
36995		"name": c.name,
36996	})
36997	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36998}
36999
37000// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.delete" call.
37001// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
37002// non-2xx status code is an error. Response headers are in either
37003// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
37004// returned at all) in error.(*googleapi.Error).Header. Use
37005// googleapi.IsNotModified to check whether the returned error was
37006// because http.StatusNotModified was returned.
37007func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
37008	gensupport.SetOptions(c.urlParams_, opts...)
37009	res, err := c.doRequest("json")
37010	if res != nil && res.StatusCode == http.StatusNotModified {
37011		if res.Body != nil {
37012			res.Body.Close()
37013		}
37014		return nil, &googleapi.Error{
37015			Code:   res.StatusCode,
37016			Header: res.Header,
37017		}
37018	}
37019	if err != nil {
37020		return nil, err
37021	}
37022	defer googleapi.CloseBody(res)
37023	if err := googleapi.CheckResponse(res); err != nil {
37024		return nil, err
37025	}
37026	ret := &GoogleProtobufEmpty{
37027		ServerResponse: googleapi.ServerResponse{
37028			Header:         res.Header,
37029			HTTPStatusCode: res.StatusCode,
37030		},
37031	}
37032	target := &ret
37033	if err := gensupport.DecodeResponse(target, res); err != nil {
37034		return nil, err
37035	}
37036	return ret, nil
37037	// {
37038	//   "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.",
37039	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes/{entityTypesId}",
37040	//   "httpMethod": "DELETE",
37041	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.delete",
37042	//   "parameterOrder": [
37043	//     "name"
37044	//   ],
37045	//   "parameters": {
37046	//     "name": {
37047	//       "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.",
37048	//       "location": "path",
37049	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/entityTypes/[^/]+$",
37050	//       "required": true,
37051	//       "type": "string"
37052	//     }
37053	//   },
37054	//   "path": "v2/{+name}",
37055	//   "response": {
37056	//     "$ref": "GoogleProtobufEmpty"
37057	//   },
37058	//   "scopes": [
37059	//     "https://www.googleapis.com/auth/cloud-platform",
37060	//     "https://www.googleapis.com/auth/dialogflow"
37061	//   ]
37062	// }
37063
37064}
37065
37066// method id "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.get":
37067
37068type ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall struct {
37069	s            *Service
37070	name         string
37071	urlParams_   gensupport.URLParams
37072	ifNoneMatch_ string
37073	ctx_         context.Context
37074	header_      http.Header
37075}
37076
37077// Get: Retrieves the specified session entity type. This method doesn't
37078// work with Google Assistant integration. Contact Dialogflow support if
37079// you need to use session entities with Google Assistant integration.
37080//
37081// - name: The name of the session entity type. Format:
37082//   `projects//agent/sessions//entityTypes/` or
37083//   `projects//agent/environments//users//sessions//entityTypes/`. If
37084//   `Environment ID` is not specified, we assume default 'draft'
37085//   environment. If `User ID` is not specified, we assume default '-'
37086//   user.
37087func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService) Get(name string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
37088	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37089	c.name = name
37090	return c
37091}
37092
37093// Fields allows partial responses to be retrieved. See
37094// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37095// for more information.
37096func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
37097	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37098	return c
37099}
37100
37101// IfNoneMatch sets the optional parameter which makes the operation
37102// fail if the object's ETag matches the given value. This is useful for
37103// getting updates only after the object has changed since the last
37104// request. Use googleapi.IsNotModified to check whether the response
37105// error from Do is the result of In-None-Match.
37106func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
37107	c.ifNoneMatch_ = entityTag
37108	return c
37109}
37110
37111// Context sets the context to be used in this call's Do method. Any
37112// pending HTTP request will be aborted if the provided context is
37113// canceled.
37114func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
37115	c.ctx_ = ctx
37116	return c
37117}
37118
37119// Header returns an http.Header that can be modified by the caller to
37120// add HTTP headers to the request.
37121func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Header() http.Header {
37122	if c.header_ == nil {
37123		c.header_ = make(http.Header)
37124	}
37125	return c.header_
37126}
37127
37128func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall) doRequest(alt string) (*http.Response, error) {
37129	reqHeaders := make(http.Header)
37130	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
37131	for k, v := range c.header_ {
37132		reqHeaders[k] = v
37133	}
37134	reqHeaders.Set("User-Agent", c.s.userAgent())
37135	if c.ifNoneMatch_ != "" {
37136		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37137	}
37138	var body io.Reader = nil
37139	c.urlParams_.Set("alt", alt)
37140	c.urlParams_.Set("prettyPrint", "false")
37141	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
37142	urls += "?" + c.urlParams_.Encode()
37143	req, err := http.NewRequest("GET", urls, body)
37144	if err != nil {
37145		return nil, err
37146	}
37147	req.Header = reqHeaders
37148	googleapi.Expand(req.URL, map[string]string{
37149		"name": c.name,
37150	})
37151	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37152}
37153
37154// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.get" call.
37155// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
37156// will be non-nil. Any non-2xx status code is an error. Response
37157// headers are in either
37158// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
37159// (if a response was returned at all) in
37160// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
37161// whether the returned error was because http.StatusNotModified was
37162// returned.
37163func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
37164	gensupport.SetOptions(c.urlParams_, opts...)
37165	res, err := c.doRequest("json")
37166	if res != nil && res.StatusCode == http.StatusNotModified {
37167		if res.Body != nil {
37168			res.Body.Close()
37169		}
37170		return nil, &googleapi.Error{
37171			Code:   res.StatusCode,
37172			Header: res.Header,
37173		}
37174	}
37175	if err != nil {
37176		return nil, err
37177	}
37178	defer googleapi.CloseBody(res)
37179	if err := googleapi.CheckResponse(res); err != nil {
37180		return nil, err
37181	}
37182	ret := &GoogleCloudDialogflowV2SessionEntityType{
37183		ServerResponse: googleapi.ServerResponse{
37184			Header:         res.Header,
37185			HTTPStatusCode: res.StatusCode,
37186		},
37187	}
37188	target := &ret
37189	if err := gensupport.DecodeResponse(target, res); err != nil {
37190		return nil, err
37191	}
37192	return ret, nil
37193	// {
37194	//   "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.",
37195	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes/{entityTypesId}",
37196	//   "httpMethod": "GET",
37197	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.get",
37198	//   "parameterOrder": [
37199	//     "name"
37200	//   ],
37201	//   "parameters": {
37202	//     "name": {
37203	//       "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.",
37204	//       "location": "path",
37205	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/entityTypes/[^/]+$",
37206	//       "required": true,
37207	//       "type": "string"
37208	//     }
37209	//   },
37210	//   "path": "v2/{+name}",
37211	//   "response": {
37212	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
37213	//   },
37214	//   "scopes": [
37215	//     "https://www.googleapis.com/auth/cloud-platform",
37216	//     "https://www.googleapis.com/auth/dialogflow"
37217	//   ]
37218	// }
37219
37220}
37221
37222// method id "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.list":
37223
37224type ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall struct {
37225	s            *Service
37226	parent       string
37227	urlParams_   gensupport.URLParams
37228	ifNoneMatch_ string
37229	ctx_         context.Context
37230	header_      http.Header
37231}
37232
37233// List: Returns the list of all session entity types in the specified
37234// session. This method doesn't work with Google Assistant integration.
37235// Contact Dialogflow support if you need to use session entities with
37236// Google Assistant integration.
37237//
37238// - parent: The session to list all session entity types from. Format:
37239//   `projects//agent/sessions/` or
37240//   `projects//agent/environments//users// sessions/`. If `Environment
37241//   ID` is not specified, we assume default 'draft' environment. If
37242//   `User ID` is not specified, we assume default '-' user.
37243func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService) List(parent string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall {
37244	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37245	c.parent = parent
37246	return c
37247}
37248
37249// PageSize sets the optional parameter "pageSize": The maximum number
37250// of items to return in a single page. By default 100 and at most 1000.
37251func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) PageSize(pageSize int64) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall {
37252	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
37253	return c
37254}
37255
37256// PageToken sets the optional parameter "pageToken": The
37257// next_page_token value returned from a previous list request.
37258func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) PageToken(pageToken string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall {
37259	c.urlParams_.Set("pageToken", pageToken)
37260	return c
37261}
37262
37263// Fields allows partial responses to be retrieved. See
37264// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37265// for more information.
37266func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall {
37267	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37268	return c
37269}
37270
37271// IfNoneMatch sets the optional parameter which makes the operation
37272// fail if the object's ETag matches the given value. This is useful for
37273// getting updates only after the object has changed since the last
37274// request. Use googleapi.IsNotModified to check whether the response
37275// error from Do is the result of In-None-Match.
37276func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall {
37277	c.ifNoneMatch_ = entityTag
37278	return c
37279}
37280
37281// Context sets the context to be used in this call's Do method. Any
37282// pending HTTP request will be aborted if the provided context is
37283// canceled.
37284func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall {
37285	c.ctx_ = ctx
37286	return c
37287}
37288
37289// Header returns an http.Header that can be modified by the caller to
37290// add HTTP headers to the request.
37291func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) Header() http.Header {
37292	if c.header_ == nil {
37293		c.header_ = make(http.Header)
37294	}
37295	return c.header_
37296}
37297
37298func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) doRequest(alt string) (*http.Response, error) {
37299	reqHeaders := make(http.Header)
37300	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
37301	for k, v := range c.header_ {
37302		reqHeaders[k] = v
37303	}
37304	reqHeaders.Set("User-Agent", c.s.userAgent())
37305	if c.ifNoneMatch_ != "" {
37306		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37307	}
37308	var body io.Reader = nil
37309	c.urlParams_.Set("alt", alt)
37310	c.urlParams_.Set("prettyPrint", "false")
37311	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
37312	urls += "?" + c.urlParams_.Encode()
37313	req, err := http.NewRequest("GET", urls, body)
37314	if err != nil {
37315		return nil, err
37316	}
37317	req.Header = reqHeaders
37318	googleapi.Expand(req.URL, map[string]string{
37319		"parent": c.parent,
37320	})
37321	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37322}
37323
37324// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.list" call.
37325// Exactly one of *GoogleCloudDialogflowV2ListSessionEntityTypesResponse
37326// or error will be non-nil. Any non-2xx status code is an error.
37327// Response headers are in either
37328// *GoogleCloudDialogflowV2ListSessionEntityTypesResponse.ServerResponse.
37329// Header or (if a response was returned at all) in
37330// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
37331// whether the returned error was because http.StatusNotModified was
37332// returned.
37333func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListSessionEntityTypesResponse, error) {
37334	gensupport.SetOptions(c.urlParams_, opts...)
37335	res, err := c.doRequest("json")
37336	if res != nil && res.StatusCode == http.StatusNotModified {
37337		if res.Body != nil {
37338			res.Body.Close()
37339		}
37340		return nil, &googleapi.Error{
37341			Code:   res.StatusCode,
37342			Header: res.Header,
37343		}
37344	}
37345	if err != nil {
37346		return nil, err
37347	}
37348	defer googleapi.CloseBody(res)
37349	if err := googleapi.CheckResponse(res); err != nil {
37350		return nil, err
37351	}
37352	ret := &GoogleCloudDialogflowV2ListSessionEntityTypesResponse{
37353		ServerResponse: googleapi.ServerResponse{
37354			Header:         res.Header,
37355			HTTPStatusCode: res.StatusCode,
37356		},
37357	}
37358	target := &ret
37359	if err := gensupport.DecodeResponse(target, res); err != nil {
37360		return nil, err
37361	}
37362	return ret, nil
37363	// {
37364	//   "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.",
37365	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes",
37366	//   "httpMethod": "GET",
37367	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.list",
37368	//   "parameterOrder": [
37369	//     "parent"
37370	//   ],
37371	//   "parameters": {
37372	//     "pageSize": {
37373	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
37374	//       "format": "int32",
37375	//       "location": "query",
37376	//       "type": "integer"
37377	//     },
37378	//     "pageToken": {
37379	//       "description": "Optional. The next_page_token value returned from a previous list request.",
37380	//       "location": "query",
37381	//       "type": "string"
37382	//     },
37383	//     "parent": {
37384	//       "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.",
37385	//       "location": "path",
37386	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
37387	//       "required": true,
37388	//       "type": "string"
37389	//     }
37390	//   },
37391	//   "path": "v2/{+parent}/entityTypes",
37392	//   "response": {
37393	//     "$ref": "GoogleCloudDialogflowV2ListSessionEntityTypesResponse"
37394	//   },
37395	//   "scopes": [
37396	//     "https://www.googleapis.com/auth/cloud-platform",
37397	//     "https://www.googleapis.com/auth/dialogflow"
37398	//   ]
37399	// }
37400
37401}
37402
37403// Pages invokes f for each page of results.
37404// A non-nil error returned from f will halt the iteration.
37405// The provided context supersedes any context provided to the Context method.
37406func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListSessionEntityTypesResponse) error) error {
37407	c.ctx_ = ctx
37408	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
37409	for {
37410		x, err := c.Do()
37411		if err != nil {
37412			return err
37413		}
37414		if err := f(x); err != nil {
37415			return err
37416		}
37417		if x.NextPageToken == "" {
37418			return nil
37419		}
37420		c.PageToken(x.NextPageToken)
37421	}
37422}
37423
37424// method id "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.patch":
37425
37426type ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall struct {
37427	s                                        *Service
37428	nameid                                   string
37429	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
37430	urlParams_                               gensupport.URLParams
37431	ctx_                                     context.Context
37432	header_                                  http.Header
37433}
37434
37435// Patch: Updates the specified session entity type. This method doesn't
37436// work with Google Assistant integration. Contact Dialogflow support if
37437// you need to use session entities with Google Assistant integration.
37438//
37439// - name: The unique identifier of this session entity type. Format:
37440//   `projects//agent/sessions//entityTypes/`, or
37441//   `projects//agent/environments//users//sessions//entityTypes/`. If
37442//   `Environment ID` is not specified, we assume default 'draft'
37443//   environment. If `User ID` is not specified, we assume default '-'
37444//   user. `` must be the display name of an existing entity type in the
37445//   same agent that will be overridden or supplemented.
37446func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService) Patch(nameid string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
37447	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37448	c.nameid = nameid
37449	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
37450	return c
37451}
37452
37453// UpdateMask sets the optional parameter "updateMask": The mask to
37454// control which fields get updated.
37455func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
37456	c.urlParams_.Set("updateMask", updateMask)
37457	return c
37458}
37459
37460// Fields allows partial responses to be retrieved. See
37461// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37462// for more information.
37463func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
37464	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37465	return c
37466}
37467
37468// Context sets the context to be used in this call's Do method. Any
37469// pending HTTP request will be aborted if the provided context is
37470// canceled.
37471func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
37472	c.ctx_ = ctx
37473	return c
37474}
37475
37476// Header returns an http.Header that can be modified by the caller to
37477// add HTTP headers to the request.
37478func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Header() http.Header {
37479	if c.header_ == nil {
37480		c.header_ = make(http.Header)
37481	}
37482	return c.header_
37483}
37484
37485func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) doRequest(alt string) (*http.Response, error) {
37486	reqHeaders := make(http.Header)
37487	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
37488	for k, v := range c.header_ {
37489		reqHeaders[k] = v
37490	}
37491	reqHeaders.Set("User-Agent", c.s.userAgent())
37492	var body io.Reader = nil
37493	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
37494	if err != nil {
37495		return nil, err
37496	}
37497	reqHeaders.Set("Content-Type", "application/json")
37498	c.urlParams_.Set("alt", alt)
37499	c.urlParams_.Set("prettyPrint", "false")
37500	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
37501	urls += "?" + c.urlParams_.Encode()
37502	req, err := http.NewRequest("PATCH", urls, body)
37503	if err != nil {
37504		return nil, err
37505	}
37506	req.Header = reqHeaders
37507	googleapi.Expand(req.URL, map[string]string{
37508		"name": c.nameid,
37509	})
37510	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37511}
37512
37513// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.patch" call.
37514// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
37515// will be non-nil. Any non-2xx status code is an error. Response
37516// headers are in either
37517// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
37518// (if a response was returned at all) in
37519// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
37520// whether the returned error was because http.StatusNotModified was
37521// returned.
37522func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
37523	gensupport.SetOptions(c.urlParams_, opts...)
37524	res, err := c.doRequest("json")
37525	if res != nil && res.StatusCode == http.StatusNotModified {
37526		if res.Body != nil {
37527			res.Body.Close()
37528		}
37529		return nil, &googleapi.Error{
37530			Code:   res.StatusCode,
37531			Header: res.Header,
37532		}
37533	}
37534	if err != nil {
37535		return nil, err
37536	}
37537	defer googleapi.CloseBody(res)
37538	if err := googleapi.CheckResponse(res); err != nil {
37539		return nil, err
37540	}
37541	ret := &GoogleCloudDialogflowV2SessionEntityType{
37542		ServerResponse: googleapi.ServerResponse{
37543			Header:         res.Header,
37544			HTTPStatusCode: res.StatusCode,
37545		},
37546	}
37547	target := &ret
37548	if err := gensupport.DecodeResponse(target, res); err != nil {
37549		return nil, err
37550	}
37551	return ret, nil
37552	// {
37553	//   "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.",
37554	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes/{entityTypesId}",
37555	//   "httpMethod": "PATCH",
37556	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.patch",
37557	//   "parameterOrder": [
37558	//     "name"
37559	//   ],
37560	//   "parameters": {
37561	//     "name": {
37562	//       "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.",
37563	//       "location": "path",
37564	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/entityTypes/[^/]+$",
37565	//       "required": true,
37566	//       "type": "string"
37567	//     },
37568	//     "updateMask": {
37569	//       "description": "Optional. The mask to control which fields get updated.",
37570	//       "format": "google-fieldmask",
37571	//       "location": "query",
37572	//       "type": "string"
37573	//     }
37574	//   },
37575	//   "path": "v2/{+name}",
37576	//   "request": {
37577	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
37578	//   },
37579	//   "response": {
37580	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
37581	//   },
37582	//   "scopes": [
37583	//     "https://www.googleapis.com/auth/cloud-platform",
37584	//     "https://www.googleapis.com/auth/dialogflow"
37585	//   ]
37586	// }
37587
37588}
37589
37590// method id "dialogflow.projects.locations.agent.intents.batchDelete":
37591
37592type ProjectsLocationsAgentIntentsBatchDeleteCall struct {
37593	s                                                *Service
37594	parent                                           string
37595	googleclouddialogflowv2batchdeleteintentsrequest *GoogleCloudDialogflowV2BatchDeleteIntentsRequest
37596	urlParams_                                       gensupport.URLParams
37597	ctx_                                             context.Context
37598	header_                                          http.Header
37599}
37600
37601// BatchDelete: Deletes intents in the specified agent. Operation
37602//
37603// - parent: The name of the agent to delete all entities types for.
37604//   Format: `projects//agent`.
37605func (r *ProjectsLocationsAgentIntentsService) BatchDelete(parent string, googleclouddialogflowv2batchdeleteintentsrequest *GoogleCloudDialogflowV2BatchDeleteIntentsRequest) *ProjectsLocationsAgentIntentsBatchDeleteCall {
37606	c := &ProjectsLocationsAgentIntentsBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37607	c.parent = parent
37608	c.googleclouddialogflowv2batchdeleteintentsrequest = googleclouddialogflowv2batchdeleteintentsrequest
37609	return c
37610}
37611
37612// Fields allows partial responses to be retrieved. See
37613// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37614// for more information.
37615func (c *ProjectsLocationsAgentIntentsBatchDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsBatchDeleteCall {
37616	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37617	return c
37618}
37619
37620// Context sets the context to be used in this call's Do method. Any
37621// pending HTTP request will be aborted if the provided context is
37622// canceled.
37623func (c *ProjectsLocationsAgentIntentsBatchDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsBatchDeleteCall {
37624	c.ctx_ = ctx
37625	return c
37626}
37627
37628// Header returns an http.Header that can be modified by the caller to
37629// add HTTP headers to the request.
37630func (c *ProjectsLocationsAgentIntentsBatchDeleteCall) Header() http.Header {
37631	if c.header_ == nil {
37632		c.header_ = make(http.Header)
37633	}
37634	return c.header_
37635}
37636
37637func (c *ProjectsLocationsAgentIntentsBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
37638	reqHeaders := make(http.Header)
37639	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
37640	for k, v := range c.header_ {
37641		reqHeaders[k] = v
37642	}
37643	reqHeaders.Set("User-Agent", c.s.userAgent())
37644	var body io.Reader = nil
37645	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchdeleteintentsrequest)
37646	if err != nil {
37647		return nil, err
37648	}
37649	reqHeaders.Set("Content-Type", "application/json")
37650	c.urlParams_.Set("alt", alt)
37651	c.urlParams_.Set("prettyPrint", "false")
37652	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents:batchDelete")
37653	urls += "?" + c.urlParams_.Encode()
37654	req, err := http.NewRequest("POST", urls, body)
37655	if err != nil {
37656		return nil, err
37657	}
37658	req.Header = reqHeaders
37659	googleapi.Expand(req.URL, map[string]string{
37660		"parent": c.parent,
37661	})
37662	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37663}
37664
37665// Do executes the "dialogflow.projects.locations.agent.intents.batchDelete" call.
37666// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
37667// Any non-2xx status code is an error. Response headers are in either
37668// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
37669// was returned at all) in error.(*googleapi.Error).Header. Use
37670// googleapi.IsNotModified to check whether the returned error was
37671// because http.StatusNotModified was returned.
37672func (c *ProjectsLocationsAgentIntentsBatchDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
37673	gensupport.SetOptions(c.urlParams_, opts...)
37674	res, err := c.doRequest("json")
37675	if res != nil && res.StatusCode == http.StatusNotModified {
37676		if res.Body != nil {
37677			res.Body.Close()
37678		}
37679		return nil, &googleapi.Error{
37680			Code:   res.StatusCode,
37681			Header: res.Header,
37682		}
37683	}
37684	if err != nil {
37685		return nil, err
37686	}
37687	defer googleapi.CloseBody(res)
37688	if err := googleapi.CheckResponse(res); err != nil {
37689		return nil, err
37690	}
37691	ret := &GoogleLongrunningOperation{
37692		ServerResponse: googleapi.ServerResponse{
37693			Header:         res.Header,
37694			HTTPStatusCode: res.StatusCode,
37695		},
37696	}
37697	target := &ret
37698	if err := gensupport.DecodeResponse(target, res); err != nil {
37699		return nil, err
37700	}
37701	return ret, nil
37702	// {
37703	//   "description": "Deletes intents in the specified agent. Operation ",
37704	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents:batchDelete",
37705	//   "httpMethod": "POST",
37706	//   "id": "dialogflow.projects.locations.agent.intents.batchDelete",
37707	//   "parameterOrder": [
37708	//     "parent"
37709	//   ],
37710	//   "parameters": {
37711	//     "parent": {
37712	//       "description": "Required. The name of the agent to delete all entities types for. Format: `projects//agent`.",
37713	//       "location": "path",
37714	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
37715	//       "required": true,
37716	//       "type": "string"
37717	//     }
37718	//   },
37719	//   "path": "v2/{+parent}/intents:batchDelete",
37720	//   "request": {
37721	//     "$ref": "GoogleCloudDialogflowV2BatchDeleteIntentsRequest"
37722	//   },
37723	//   "response": {
37724	//     "$ref": "GoogleLongrunningOperation"
37725	//   },
37726	//   "scopes": [
37727	//     "https://www.googleapis.com/auth/cloud-platform",
37728	//     "https://www.googleapis.com/auth/dialogflow"
37729	//   ]
37730	// }
37731
37732}
37733
37734// method id "dialogflow.projects.locations.agent.intents.batchUpdate":
37735
37736type ProjectsLocationsAgentIntentsBatchUpdateCall struct {
37737	s                                                *Service
37738	parent                                           string
37739	googleclouddialogflowv2batchupdateintentsrequest *GoogleCloudDialogflowV2BatchUpdateIntentsRequest
37740	urlParams_                                       gensupport.URLParams
37741	ctx_                                             context.Context
37742	header_                                          http.Header
37743}
37744
37745// BatchUpdate: Updates/Creates multiple intents in the specified agent.
37746// Operation
37747//
37748// - parent: The name of the agent to update or create intents in.
37749//   Format: `projects//agent`.
37750func (r *ProjectsLocationsAgentIntentsService) BatchUpdate(parent string, googleclouddialogflowv2batchupdateintentsrequest *GoogleCloudDialogflowV2BatchUpdateIntentsRequest) *ProjectsLocationsAgentIntentsBatchUpdateCall {
37751	c := &ProjectsLocationsAgentIntentsBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37752	c.parent = parent
37753	c.googleclouddialogflowv2batchupdateintentsrequest = googleclouddialogflowv2batchupdateintentsrequest
37754	return c
37755}
37756
37757// Fields allows partial responses to be retrieved. See
37758// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37759// for more information.
37760func (c *ProjectsLocationsAgentIntentsBatchUpdateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsBatchUpdateCall {
37761	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37762	return c
37763}
37764
37765// Context sets the context to be used in this call's Do method. Any
37766// pending HTTP request will be aborted if the provided context is
37767// canceled.
37768func (c *ProjectsLocationsAgentIntentsBatchUpdateCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsBatchUpdateCall {
37769	c.ctx_ = ctx
37770	return c
37771}
37772
37773// Header returns an http.Header that can be modified by the caller to
37774// add HTTP headers to the request.
37775func (c *ProjectsLocationsAgentIntentsBatchUpdateCall) Header() http.Header {
37776	if c.header_ == nil {
37777		c.header_ = make(http.Header)
37778	}
37779	return c.header_
37780}
37781
37782func (c *ProjectsLocationsAgentIntentsBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
37783	reqHeaders := make(http.Header)
37784	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
37785	for k, v := range c.header_ {
37786		reqHeaders[k] = v
37787	}
37788	reqHeaders.Set("User-Agent", c.s.userAgent())
37789	var body io.Reader = nil
37790	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchupdateintentsrequest)
37791	if err != nil {
37792		return nil, err
37793	}
37794	reqHeaders.Set("Content-Type", "application/json")
37795	c.urlParams_.Set("alt", alt)
37796	c.urlParams_.Set("prettyPrint", "false")
37797	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents:batchUpdate")
37798	urls += "?" + c.urlParams_.Encode()
37799	req, err := http.NewRequest("POST", urls, body)
37800	if err != nil {
37801		return nil, err
37802	}
37803	req.Header = reqHeaders
37804	googleapi.Expand(req.URL, map[string]string{
37805		"parent": c.parent,
37806	})
37807	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37808}
37809
37810// Do executes the "dialogflow.projects.locations.agent.intents.batchUpdate" call.
37811// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
37812// Any non-2xx status code is an error. Response headers are in either
37813// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
37814// was returned at all) in error.(*googleapi.Error).Header. Use
37815// googleapi.IsNotModified to check whether the returned error was
37816// because http.StatusNotModified was returned.
37817func (c *ProjectsLocationsAgentIntentsBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
37818	gensupport.SetOptions(c.urlParams_, opts...)
37819	res, err := c.doRequest("json")
37820	if res != nil && res.StatusCode == http.StatusNotModified {
37821		if res.Body != nil {
37822			res.Body.Close()
37823		}
37824		return nil, &googleapi.Error{
37825			Code:   res.StatusCode,
37826			Header: res.Header,
37827		}
37828	}
37829	if err != nil {
37830		return nil, err
37831	}
37832	defer googleapi.CloseBody(res)
37833	if err := googleapi.CheckResponse(res); err != nil {
37834		return nil, err
37835	}
37836	ret := &GoogleLongrunningOperation{
37837		ServerResponse: googleapi.ServerResponse{
37838			Header:         res.Header,
37839			HTTPStatusCode: res.StatusCode,
37840		},
37841	}
37842	target := &ret
37843	if err := gensupport.DecodeResponse(target, res); err != nil {
37844		return nil, err
37845	}
37846	return ret, nil
37847	// {
37848	//   "description": "Updates/Creates multiple intents in the specified agent. Operation ",
37849	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents:batchUpdate",
37850	//   "httpMethod": "POST",
37851	//   "id": "dialogflow.projects.locations.agent.intents.batchUpdate",
37852	//   "parameterOrder": [
37853	//     "parent"
37854	//   ],
37855	//   "parameters": {
37856	//     "parent": {
37857	//       "description": "Required. The name of the agent to update or create intents in. Format: `projects//agent`.",
37858	//       "location": "path",
37859	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
37860	//       "required": true,
37861	//       "type": "string"
37862	//     }
37863	//   },
37864	//   "path": "v2/{+parent}/intents:batchUpdate",
37865	//   "request": {
37866	//     "$ref": "GoogleCloudDialogflowV2BatchUpdateIntentsRequest"
37867	//   },
37868	//   "response": {
37869	//     "$ref": "GoogleLongrunningOperation"
37870	//   },
37871	//   "scopes": [
37872	//     "https://www.googleapis.com/auth/cloud-platform",
37873	//     "https://www.googleapis.com/auth/dialogflow"
37874	//   ]
37875	// }
37876
37877}
37878
37879// method id "dialogflow.projects.locations.agent.intents.create":
37880
37881type ProjectsLocationsAgentIntentsCreateCall struct {
37882	s                             *Service
37883	parent                        string
37884	googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent
37885	urlParams_                    gensupport.URLParams
37886	ctx_                          context.Context
37887	header_                       http.Header
37888}
37889
37890// Create: Creates an intent in the specified agent.
37891//
37892// - parent: The agent to create a intent for. Format:
37893//   `projects//agent`.
37894func (r *ProjectsLocationsAgentIntentsService) Create(parent string, googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent) *ProjectsLocationsAgentIntentsCreateCall {
37895	c := &ProjectsLocationsAgentIntentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37896	c.parent = parent
37897	c.googleclouddialogflowv2intent = googleclouddialogflowv2intent
37898	return c
37899}
37900
37901// IntentView sets the optional parameter "intentView": The resource
37902// view to apply to the returned intent.
37903//
37904// Possible values:
37905//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
37906// in the response.
37907//   "INTENT_VIEW_FULL" - All fields are populated.
37908func (c *ProjectsLocationsAgentIntentsCreateCall) IntentView(intentView string) *ProjectsLocationsAgentIntentsCreateCall {
37909	c.urlParams_.Set("intentView", intentView)
37910	return c
37911}
37912
37913// LanguageCode sets the optional parameter "languageCode": The language
37914// used to access language-specific data. If not specified, the agent's
37915// default language is used. For more information, see Multilingual
37916// intent and entity data
37917// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
37918func (c *ProjectsLocationsAgentIntentsCreateCall) LanguageCode(languageCode string) *ProjectsLocationsAgentIntentsCreateCall {
37919	c.urlParams_.Set("languageCode", languageCode)
37920	return c
37921}
37922
37923// Fields allows partial responses to be retrieved. See
37924// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37925// for more information.
37926func (c *ProjectsLocationsAgentIntentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsCreateCall {
37927	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37928	return c
37929}
37930
37931// Context sets the context to be used in this call's Do method. Any
37932// pending HTTP request will be aborted if the provided context is
37933// canceled.
37934func (c *ProjectsLocationsAgentIntentsCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsCreateCall {
37935	c.ctx_ = ctx
37936	return c
37937}
37938
37939// Header returns an http.Header that can be modified by the caller to
37940// add HTTP headers to the request.
37941func (c *ProjectsLocationsAgentIntentsCreateCall) Header() http.Header {
37942	if c.header_ == nil {
37943		c.header_ = make(http.Header)
37944	}
37945	return c.header_
37946}
37947
37948func (c *ProjectsLocationsAgentIntentsCreateCall) doRequest(alt string) (*http.Response, error) {
37949	reqHeaders := make(http.Header)
37950	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
37951	for k, v := range c.header_ {
37952		reqHeaders[k] = v
37953	}
37954	reqHeaders.Set("User-Agent", c.s.userAgent())
37955	var body io.Reader = nil
37956	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2intent)
37957	if err != nil {
37958		return nil, err
37959	}
37960	reqHeaders.Set("Content-Type", "application/json")
37961	c.urlParams_.Set("alt", alt)
37962	c.urlParams_.Set("prettyPrint", "false")
37963	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents")
37964	urls += "?" + c.urlParams_.Encode()
37965	req, err := http.NewRequest("POST", urls, body)
37966	if err != nil {
37967		return nil, err
37968	}
37969	req.Header = reqHeaders
37970	googleapi.Expand(req.URL, map[string]string{
37971		"parent": c.parent,
37972	})
37973	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37974}
37975
37976// Do executes the "dialogflow.projects.locations.agent.intents.create" call.
37977// Exactly one of *GoogleCloudDialogflowV2Intent or error will be
37978// non-nil. Any non-2xx status code is an error. Response headers are in
37979// either *GoogleCloudDialogflowV2Intent.ServerResponse.Header or (if a
37980// response was returned at all) in error.(*googleapi.Error).Header. Use
37981// googleapi.IsNotModified to check whether the returned error was
37982// because http.StatusNotModified was returned.
37983func (c *ProjectsLocationsAgentIntentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Intent, error) {
37984	gensupport.SetOptions(c.urlParams_, opts...)
37985	res, err := c.doRequest("json")
37986	if res != nil && res.StatusCode == http.StatusNotModified {
37987		if res.Body != nil {
37988			res.Body.Close()
37989		}
37990		return nil, &googleapi.Error{
37991			Code:   res.StatusCode,
37992			Header: res.Header,
37993		}
37994	}
37995	if err != nil {
37996		return nil, err
37997	}
37998	defer googleapi.CloseBody(res)
37999	if err := googleapi.CheckResponse(res); err != nil {
38000		return nil, err
38001	}
38002	ret := &GoogleCloudDialogflowV2Intent{
38003		ServerResponse: googleapi.ServerResponse{
38004			Header:         res.Header,
38005			HTTPStatusCode: res.StatusCode,
38006		},
38007	}
38008	target := &ret
38009	if err := gensupport.DecodeResponse(target, res); err != nil {
38010		return nil, err
38011	}
38012	return ret, nil
38013	// {
38014	//   "description": "Creates an intent in the specified agent.",
38015	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents",
38016	//   "httpMethod": "POST",
38017	//   "id": "dialogflow.projects.locations.agent.intents.create",
38018	//   "parameterOrder": [
38019	//     "parent"
38020	//   ],
38021	//   "parameters": {
38022	//     "intentView": {
38023	//       "description": "Optional. The resource view to apply to the returned intent.",
38024	//       "enum": [
38025	//         "INTENT_VIEW_UNSPECIFIED",
38026	//         "INTENT_VIEW_FULL"
38027	//       ],
38028	//       "enumDescriptions": [
38029	//         "Training phrases field is not populated in the response.",
38030	//         "All fields are populated."
38031	//       ],
38032	//       "location": "query",
38033	//       "type": "string"
38034	//     },
38035	//     "languageCode": {
38036	//       "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).",
38037	//       "location": "query",
38038	//       "type": "string"
38039	//     },
38040	//     "parent": {
38041	//       "description": "Required. The agent to create a intent for. Format: `projects//agent`.",
38042	//       "location": "path",
38043	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
38044	//       "required": true,
38045	//       "type": "string"
38046	//     }
38047	//   },
38048	//   "path": "v2/{+parent}/intents",
38049	//   "request": {
38050	//     "$ref": "GoogleCloudDialogflowV2Intent"
38051	//   },
38052	//   "response": {
38053	//     "$ref": "GoogleCloudDialogflowV2Intent"
38054	//   },
38055	//   "scopes": [
38056	//     "https://www.googleapis.com/auth/cloud-platform",
38057	//     "https://www.googleapis.com/auth/dialogflow"
38058	//   ]
38059	// }
38060
38061}
38062
38063// method id "dialogflow.projects.locations.agent.intents.delete":
38064
38065type ProjectsLocationsAgentIntentsDeleteCall struct {
38066	s          *Service
38067	name       string
38068	urlParams_ gensupport.URLParams
38069	ctx_       context.Context
38070	header_    http.Header
38071}
38072
38073// Delete: Deletes the specified intent and its direct or indirect
38074// followup intents.
38075//
38076// - name: The name of the intent to delete. If this intent has direct
38077//   or indirect followup intents, we also delete them. Format:
38078//   `projects//agent/intents/`.
38079func (r *ProjectsLocationsAgentIntentsService) Delete(name string) *ProjectsLocationsAgentIntentsDeleteCall {
38080	c := &ProjectsLocationsAgentIntentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38081	c.name = name
38082	return c
38083}
38084
38085// Fields allows partial responses to be retrieved. See
38086// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38087// for more information.
38088func (c *ProjectsLocationsAgentIntentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsDeleteCall {
38089	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38090	return c
38091}
38092
38093// Context sets the context to be used in this call's Do method. Any
38094// pending HTTP request will be aborted if the provided context is
38095// canceled.
38096func (c *ProjectsLocationsAgentIntentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsDeleteCall {
38097	c.ctx_ = ctx
38098	return c
38099}
38100
38101// Header returns an http.Header that can be modified by the caller to
38102// add HTTP headers to the request.
38103func (c *ProjectsLocationsAgentIntentsDeleteCall) Header() http.Header {
38104	if c.header_ == nil {
38105		c.header_ = make(http.Header)
38106	}
38107	return c.header_
38108}
38109
38110func (c *ProjectsLocationsAgentIntentsDeleteCall) doRequest(alt string) (*http.Response, error) {
38111	reqHeaders := make(http.Header)
38112	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
38113	for k, v := range c.header_ {
38114		reqHeaders[k] = v
38115	}
38116	reqHeaders.Set("User-Agent", c.s.userAgent())
38117	var body io.Reader = nil
38118	c.urlParams_.Set("alt", alt)
38119	c.urlParams_.Set("prettyPrint", "false")
38120	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
38121	urls += "?" + c.urlParams_.Encode()
38122	req, err := http.NewRequest("DELETE", urls, body)
38123	if err != nil {
38124		return nil, err
38125	}
38126	req.Header = reqHeaders
38127	googleapi.Expand(req.URL, map[string]string{
38128		"name": c.name,
38129	})
38130	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38131}
38132
38133// Do executes the "dialogflow.projects.locations.agent.intents.delete" call.
38134// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
38135// non-2xx status code is an error. Response headers are in either
38136// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
38137// returned at all) in error.(*googleapi.Error).Header. Use
38138// googleapi.IsNotModified to check whether the returned error was
38139// because http.StatusNotModified was returned.
38140func (c *ProjectsLocationsAgentIntentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
38141	gensupport.SetOptions(c.urlParams_, opts...)
38142	res, err := c.doRequest("json")
38143	if res != nil && res.StatusCode == http.StatusNotModified {
38144		if res.Body != nil {
38145			res.Body.Close()
38146		}
38147		return nil, &googleapi.Error{
38148			Code:   res.StatusCode,
38149			Header: res.Header,
38150		}
38151	}
38152	if err != nil {
38153		return nil, err
38154	}
38155	defer googleapi.CloseBody(res)
38156	if err := googleapi.CheckResponse(res); err != nil {
38157		return nil, err
38158	}
38159	ret := &GoogleProtobufEmpty{
38160		ServerResponse: googleapi.ServerResponse{
38161			Header:         res.Header,
38162			HTTPStatusCode: res.StatusCode,
38163		},
38164	}
38165	target := &ret
38166	if err := gensupport.DecodeResponse(target, res); err != nil {
38167		return nil, err
38168	}
38169	return ret, nil
38170	// {
38171	//   "description": "Deletes the specified intent and its direct or indirect followup intents.",
38172	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents/{intentsId}",
38173	//   "httpMethod": "DELETE",
38174	//   "id": "dialogflow.projects.locations.agent.intents.delete",
38175	//   "parameterOrder": [
38176	//     "name"
38177	//   ],
38178	//   "parameters": {
38179	//     "name": {
38180	//       "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/`.",
38181	//       "location": "path",
38182	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/intents/[^/]+$",
38183	//       "required": true,
38184	//       "type": "string"
38185	//     }
38186	//   },
38187	//   "path": "v2/{+name}",
38188	//   "response": {
38189	//     "$ref": "GoogleProtobufEmpty"
38190	//   },
38191	//   "scopes": [
38192	//     "https://www.googleapis.com/auth/cloud-platform",
38193	//     "https://www.googleapis.com/auth/dialogflow"
38194	//   ]
38195	// }
38196
38197}
38198
38199// method id "dialogflow.projects.locations.agent.intents.get":
38200
38201type ProjectsLocationsAgentIntentsGetCall struct {
38202	s            *Service
38203	name         string
38204	urlParams_   gensupport.URLParams
38205	ifNoneMatch_ string
38206	ctx_         context.Context
38207	header_      http.Header
38208}
38209
38210// Get: Retrieves the specified intent.
38211//
38212// - name: The name of the intent. Format: `projects//agent/intents/`.
38213func (r *ProjectsLocationsAgentIntentsService) Get(name string) *ProjectsLocationsAgentIntentsGetCall {
38214	c := &ProjectsLocationsAgentIntentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38215	c.name = name
38216	return c
38217}
38218
38219// IntentView sets the optional parameter "intentView": The resource
38220// view to apply to the returned intent.
38221//
38222// Possible values:
38223//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
38224// in the response.
38225//   "INTENT_VIEW_FULL" - All fields are populated.
38226func (c *ProjectsLocationsAgentIntentsGetCall) IntentView(intentView string) *ProjectsLocationsAgentIntentsGetCall {
38227	c.urlParams_.Set("intentView", intentView)
38228	return c
38229}
38230
38231// LanguageCode sets the optional parameter "languageCode": The language
38232// used to access language-specific data. If not specified, the agent's
38233// default language is used. For more information, see Multilingual
38234// intent and entity data
38235// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
38236func (c *ProjectsLocationsAgentIntentsGetCall) LanguageCode(languageCode string) *ProjectsLocationsAgentIntentsGetCall {
38237	c.urlParams_.Set("languageCode", languageCode)
38238	return c
38239}
38240
38241// Fields allows partial responses to be retrieved. See
38242// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38243// for more information.
38244func (c *ProjectsLocationsAgentIntentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsGetCall {
38245	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38246	return c
38247}
38248
38249// IfNoneMatch sets the optional parameter which makes the operation
38250// fail if the object's ETag matches the given value. This is useful for
38251// getting updates only after the object has changed since the last
38252// request. Use googleapi.IsNotModified to check whether the response
38253// error from Do is the result of In-None-Match.
38254func (c *ProjectsLocationsAgentIntentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentIntentsGetCall {
38255	c.ifNoneMatch_ = entityTag
38256	return c
38257}
38258
38259// Context sets the context to be used in this call's Do method. Any
38260// pending HTTP request will be aborted if the provided context is
38261// canceled.
38262func (c *ProjectsLocationsAgentIntentsGetCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsGetCall {
38263	c.ctx_ = ctx
38264	return c
38265}
38266
38267// Header returns an http.Header that can be modified by the caller to
38268// add HTTP headers to the request.
38269func (c *ProjectsLocationsAgentIntentsGetCall) Header() http.Header {
38270	if c.header_ == nil {
38271		c.header_ = make(http.Header)
38272	}
38273	return c.header_
38274}
38275
38276func (c *ProjectsLocationsAgentIntentsGetCall) doRequest(alt string) (*http.Response, error) {
38277	reqHeaders := make(http.Header)
38278	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
38279	for k, v := range c.header_ {
38280		reqHeaders[k] = v
38281	}
38282	reqHeaders.Set("User-Agent", c.s.userAgent())
38283	if c.ifNoneMatch_ != "" {
38284		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38285	}
38286	var body io.Reader = nil
38287	c.urlParams_.Set("alt", alt)
38288	c.urlParams_.Set("prettyPrint", "false")
38289	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
38290	urls += "?" + c.urlParams_.Encode()
38291	req, err := http.NewRequest("GET", urls, body)
38292	if err != nil {
38293		return nil, err
38294	}
38295	req.Header = reqHeaders
38296	googleapi.Expand(req.URL, map[string]string{
38297		"name": c.name,
38298	})
38299	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38300}
38301
38302// Do executes the "dialogflow.projects.locations.agent.intents.get" call.
38303// Exactly one of *GoogleCloudDialogflowV2Intent or error will be
38304// non-nil. Any non-2xx status code is an error. Response headers are in
38305// either *GoogleCloudDialogflowV2Intent.ServerResponse.Header or (if a
38306// response was returned at all) in error.(*googleapi.Error).Header. Use
38307// googleapi.IsNotModified to check whether the returned error was
38308// because http.StatusNotModified was returned.
38309func (c *ProjectsLocationsAgentIntentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Intent, error) {
38310	gensupport.SetOptions(c.urlParams_, opts...)
38311	res, err := c.doRequest("json")
38312	if res != nil && res.StatusCode == http.StatusNotModified {
38313		if res.Body != nil {
38314			res.Body.Close()
38315		}
38316		return nil, &googleapi.Error{
38317			Code:   res.StatusCode,
38318			Header: res.Header,
38319		}
38320	}
38321	if err != nil {
38322		return nil, err
38323	}
38324	defer googleapi.CloseBody(res)
38325	if err := googleapi.CheckResponse(res); err != nil {
38326		return nil, err
38327	}
38328	ret := &GoogleCloudDialogflowV2Intent{
38329		ServerResponse: googleapi.ServerResponse{
38330			Header:         res.Header,
38331			HTTPStatusCode: res.StatusCode,
38332		},
38333	}
38334	target := &ret
38335	if err := gensupport.DecodeResponse(target, res); err != nil {
38336		return nil, err
38337	}
38338	return ret, nil
38339	// {
38340	//   "description": "Retrieves the specified intent.",
38341	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents/{intentsId}",
38342	//   "httpMethod": "GET",
38343	//   "id": "dialogflow.projects.locations.agent.intents.get",
38344	//   "parameterOrder": [
38345	//     "name"
38346	//   ],
38347	//   "parameters": {
38348	//     "intentView": {
38349	//       "description": "Optional. The resource view to apply to the returned intent.",
38350	//       "enum": [
38351	//         "INTENT_VIEW_UNSPECIFIED",
38352	//         "INTENT_VIEW_FULL"
38353	//       ],
38354	//       "enumDescriptions": [
38355	//         "Training phrases field is not populated in the response.",
38356	//         "All fields are populated."
38357	//       ],
38358	//       "location": "query",
38359	//       "type": "string"
38360	//     },
38361	//     "languageCode": {
38362	//       "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).",
38363	//       "location": "query",
38364	//       "type": "string"
38365	//     },
38366	//     "name": {
38367	//       "description": "Required. The name of the intent. Format: `projects//agent/intents/`.",
38368	//       "location": "path",
38369	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/intents/[^/]+$",
38370	//       "required": true,
38371	//       "type": "string"
38372	//     }
38373	//   },
38374	//   "path": "v2/{+name}",
38375	//   "response": {
38376	//     "$ref": "GoogleCloudDialogflowV2Intent"
38377	//   },
38378	//   "scopes": [
38379	//     "https://www.googleapis.com/auth/cloud-platform",
38380	//     "https://www.googleapis.com/auth/dialogflow"
38381	//   ]
38382	// }
38383
38384}
38385
38386// method id "dialogflow.projects.locations.agent.intents.list":
38387
38388type ProjectsLocationsAgentIntentsListCall struct {
38389	s            *Service
38390	parent       string
38391	urlParams_   gensupport.URLParams
38392	ifNoneMatch_ string
38393	ctx_         context.Context
38394	header_      http.Header
38395}
38396
38397// List: Returns the list of all intents in the specified agent.
38398//
38399// - parent: The agent to list all intents from. Format:
38400//   `projects//agent`.
38401func (r *ProjectsLocationsAgentIntentsService) List(parent string) *ProjectsLocationsAgentIntentsListCall {
38402	c := &ProjectsLocationsAgentIntentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38403	c.parent = parent
38404	return c
38405}
38406
38407// IntentView sets the optional parameter "intentView": The resource
38408// view to apply to the returned intent.
38409//
38410// Possible values:
38411//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
38412// in the response.
38413//   "INTENT_VIEW_FULL" - All fields are populated.
38414func (c *ProjectsLocationsAgentIntentsListCall) IntentView(intentView string) *ProjectsLocationsAgentIntentsListCall {
38415	c.urlParams_.Set("intentView", intentView)
38416	return c
38417}
38418
38419// LanguageCode sets the optional parameter "languageCode": The language
38420// used to access language-specific data. If not specified, the agent's
38421// default language is used. For more information, see Multilingual
38422// intent and entity data
38423// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
38424func (c *ProjectsLocationsAgentIntentsListCall) LanguageCode(languageCode string) *ProjectsLocationsAgentIntentsListCall {
38425	c.urlParams_.Set("languageCode", languageCode)
38426	return c
38427}
38428
38429// PageSize sets the optional parameter "pageSize": The maximum number
38430// of items to return in a single page. By default 100 and at most 1000.
38431func (c *ProjectsLocationsAgentIntentsListCall) PageSize(pageSize int64) *ProjectsLocationsAgentIntentsListCall {
38432	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
38433	return c
38434}
38435
38436// PageToken sets the optional parameter "pageToken": The
38437// next_page_token value returned from a previous list request.
38438func (c *ProjectsLocationsAgentIntentsListCall) PageToken(pageToken string) *ProjectsLocationsAgentIntentsListCall {
38439	c.urlParams_.Set("pageToken", pageToken)
38440	return c
38441}
38442
38443// Fields allows partial responses to be retrieved. See
38444// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38445// for more information.
38446func (c *ProjectsLocationsAgentIntentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsListCall {
38447	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38448	return c
38449}
38450
38451// IfNoneMatch sets the optional parameter which makes the operation
38452// fail if the object's ETag matches the given value. This is useful for
38453// getting updates only after the object has changed since the last
38454// request. Use googleapi.IsNotModified to check whether the response
38455// error from Do is the result of In-None-Match.
38456func (c *ProjectsLocationsAgentIntentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentIntentsListCall {
38457	c.ifNoneMatch_ = entityTag
38458	return c
38459}
38460
38461// Context sets the context to be used in this call's Do method. Any
38462// pending HTTP request will be aborted if the provided context is
38463// canceled.
38464func (c *ProjectsLocationsAgentIntentsListCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsListCall {
38465	c.ctx_ = ctx
38466	return c
38467}
38468
38469// Header returns an http.Header that can be modified by the caller to
38470// add HTTP headers to the request.
38471func (c *ProjectsLocationsAgentIntentsListCall) Header() http.Header {
38472	if c.header_ == nil {
38473		c.header_ = make(http.Header)
38474	}
38475	return c.header_
38476}
38477
38478func (c *ProjectsLocationsAgentIntentsListCall) doRequest(alt string) (*http.Response, error) {
38479	reqHeaders := make(http.Header)
38480	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
38481	for k, v := range c.header_ {
38482		reqHeaders[k] = v
38483	}
38484	reqHeaders.Set("User-Agent", c.s.userAgent())
38485	if c.ifNoneMatch_ != "" {
38486		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38487	}
38488	var body io.Reader = nil
38489	c.urlParams_.Set("alt", alt)
38490	c.urlParams_.Set("prettyPrint", "false")
38491	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents")
38492	urls += "?" + c.urlParams_.Encode()
38493	req, err := http.NewRequest("GET", urls, body)
38494	if err != nil {
38495		return nil, err
38496	}
38497	req.Header = reqHeaders
38498	googleapi.Expand(req.URL, map[string]string{
38499		"parent": c.parent,
38500	})
38501	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38502}
38503
38504// Do executes the "dialogflow.projects.locations.agent.intents.list" call.
38505// Exactly one of *GoogleCloudDialogflowV2ListIntentsResponse or error
38506// will be non-nil. Any non-2xx status code is an error. Response
38507// headers are in either
38508// *GoogleCloudDialogflowV2ListIntentsResponse.ServerResponse.Header or
38509// (if a response was returned at all) in
38510// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
38511// whether the returned error was because http.StatusNotModified was
38512// returned.
38513func (c *ProjectsLocationsAgentIntentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListIntentsResponse, error) {
38514	gensupport.SetOptions(c.urlParams_, opts...)
38515	res, err := c.doRequest("json")
38516	if res != nil && res.StatusCode == http.StatusNotModified {
38517		if res.Body != nil {
38518			res.Body.Close()
38519		}
38520		return nil, &googleapi.Error{
38521			Code:   res.StatusCode,
38522			Header: res.Header,
38523		}
38524	}
38525	if err != nil {
38526		return nil, err
38527	}
38528	defer googleapi.CloseBody(res)
38529	if err := googleapi.CheckResponse(res); err != nil {
38530		return nil, err
38531	}
38532	ret := &GoogleCloudDialogflowV2ListIntentsResponse{
38533		ServerResponse: googleapi.ServerResponse{
38534			Header:         res.Header,
38535			HTTPStatusCode: res.StatusCode,
38536		},
38537	}
38538	target := &ret
38539	if err := gensupport.DecodeResponse(target, res); err != nil {
38540		return nil, err
38541	}
38542	return ret, nil
38543	// {
38544	//   "description": "Returns the list of all intents in the specified agent.",
38545	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents",
38546	//   "httpMethod": "GET",
38547	//   "id": "dialogflow.projects.locations.agent.intents.list",
38548	//   "parameterOrder": [
38549	//     "parent"
38550	//   ],
38551	//   "parameters": {
38552	//     "intentView": {
38553	//       "description": "Optional. The resource view to apply to the returned intent.",
38554	//       "enum": [
38555	//         "INTENT_VIEW_UNSPECIFIED",
38556	//         "INTENT_VIEW_FULL"
38557	//       ],
38558	//       "enumDescriptions": [
38559	//         "Training phrases field is not populated in the response.",
38560	//         "All fields are populated."
38561	//       ],
38562	//       "location": "query",
38563	//       "type": "string"
38564	//     },
38565	//     "languageCode": {
38566	//       "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).",
38567	//       "location": "query",
38568	//       "type": "string"
38569	//     },
38570	//     "pageSize": {
38571	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
38572	//       "format": "int32",
38573	//       "location": "query",
38574	//       "type": "integer"
38575	//     },
38576	//     "pageToken": {
38577	//       "description": "Optional. The next_page_token value returned from a previous list request.",
38578	//       "location": "query",
38579	//       "type": "string"
38580	//     },
38581	//     "parent": {
38582	//       "description": "Required. The agent to list all intents from. Format: `projects//agent`.",
38583	//       "location": "path",
38584	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
38585	//       "required": true,
38586	//       "type": "string"
38587	//     }
38588	//   },
38589	//   "path": "v2/{+parent}/intents",
38590	//   "response": {
38591	//     "$ref": "GoogleCloudDialogflowV2ListIntentsResponse"
38592	//   },
38593	//   "scopes": [
38594	//     "https://www.googleapis.com/auth/cloud-platform",
38595	//     "https://www.googleapis.com/auth/dialogflow"
38596	//   ]
38597	// }
38598
38599}
38600
38601// Pages invokes f for each page of results.
38602// A non-nil error returned from f will halt the iteration.
38603// The provided context supersedes any context provided to the Context method.
38604func (c *ProjectsLocationsAgentIntentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListIntentsResponse) error) error {
38605	c.ctx_ = ctx
38606	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
38607	for {
38608		x, err := c.Do()
38609		if err != nil {
38610			return err
38611		}
38612		if err := f(x); err != nil {
38613			return err
38614		}
38615		if x.NextPageToken == "" {
38616			return nil
38617		}
38618		c.PageToken(x.NextPageToken)
38619	}
38620}
38621
38622// method id "dialogflow.projects.locations.agent.intents.patch":
38623
38624type ProjectsLocationsAgentIntentsPatchCall struct {
38625	s                             *Service
38626	nameid                        string
38627	googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent
38628	urlParams_                    gensupport.URLParams
38629	ctx_                          context.Context
38630	header_                       http.Header
38631}
38632
38633// Patch: Updates the specified intent.
38634//
38635// - name: Optional. The unique identifier of this intent. Required for
38636//   Intents.UpdateIntent and Intents.BatchUpdateIntents methods.
38637//   Format: `projects//agent/intents/`.
38638func (r *ProjectsLocationsAgentIntentsService) Patch(nameid string, googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent) *ProjectsLocationsAgentIntentsPatchCall {
38639	c := &ProjectsLocationsAgentIntentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38640	c.nameid = nameid
38641	c.googleclouddialogflowv2intent = googleclouddialogflowv2intent
38642	return c
38643}
38644
38645// IntentView sets the optional parameter "intentView": The resource
38646// view to apply to the returned intent.
38647//
38648// Possible values:
38649//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
38650// in the response.
38651//   "INTENT_VIEW_FULL" - All fields are populated.
38652func (c *ProjectsLocationsAgentIntentsPatchCall) IntentView(intentView string) *ProjectsLocationsAgentIntentsPatchCall {
38653	c.urlParams_.Set("intentView", intentView)
38654	return c
38655}
38656
38657// LanguageCode sets the optional parameter "languageCode": The language
38658// used to access language-specific data. If not specified, the agent's
38659// default language is used. For more information, see Multilingual
38660// intent and entity data
38661// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
38662func (c *ProjectsLocationsAgentIntentsPatchCall) LanguageCode(languageCode string) *ProjectsLocationsAgentIntentsPatchCall {
38663	c.urlParams_.Set("languageCode", languageCode)
38664	return c
38665}
38666
38667// UpdateMask sets the optional parameter "updateMask": The mask to
38668// control which fields get updated.
38669func (c *ProjectsLocationsAgentIntentsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentIntentsPatchCall {
38670	c.urlParams_.Set("updateMask", updateMask)
38671	return c
38672}
38673
38674// Fields allows partial responses to be retrieved. See
38675// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38676// for more information.
38677func (c *ProjectsLocationsAgentIntentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsPatchCall {
38678	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38679	return c
38680}
38681
38682// Context sets the context to be used in this call's Do method. Any
38683// pending HTTP request will be aborted if the provided context is
38684// canceled.
38685func (c *ProjectsLocationsAgentIntentsPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsPatchCall {
38686	c.ctx_ = ctx
38687	return c
38688}
38689
38690// Header returns an http.Header that can be modified by the caller to
38691// add HTTP headers to the request.
38692func (c *ProjectsLocationsAgentIntentsPatchCall) Header() http.Header {
38693	if c.header_ == nil {
38694		c.header_ = make(http.Header)
38695	}
38696	return c.header_
38697}
38698
38699func (c *ProjectsLocationsAgentIntentsPatchCall) doRequest(alt string) (*http.Response, error) {
38700	reqHeaders := make(http.Header)
38701	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
38702	for k, v := range c.header_ {
38703		reqHeaders[k] = v
38704	}
38705	reqHeaders.Set("User-Agent", c.s.userAgent())
38706	var body io.Reader = nil
38707	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2intent)
38708	if err != nil {
38709		return nil, err
38710	}
38711	reqHeaders.Set("Content-Type", "application/json")
38712	c.urlParams_.Set("alt", alt)
38713	c.urlParams_.Set("prettyPrint", "false")
38714	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
38715	urls += "?" + c.urlParams_.Encode()
38716	req, err := http.NewRequest("PATCH", urls, body)
38717	if err != nil {
38718		return nil, err
38719	}
38720	req.Header = reqHeaders
38721	googleapi.Expand(req.URL, map[string]string{
38722		"name": c.nameid,
38723	})
38724	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38725}
38726
38727// Do executes the "dialogflow.projects.locations.agent.intents.patch" call.
38728// Exactly one of *GoogleCloudDialogflowV2Intent or error will be
38729// non-nil. Any non-2xx status code is an error. Response headers are in
38730// either *GoogleCloudDialogflowV2Intent.ServerResponse.Header or (if a
38731// response was returned at all) in error.(*googleapi.Error).Header. Use
38732// googleapi.IsNotModified to check whether the returned error was
38733// because http.StatusNotModified was returned.
38734func (c *ProjectsLocationsAgentIntentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Intent, error) {
38735	gensupport.SetOptions(c.urlParams_, opts...)
38736	res, err := c.doRequest("json")
38737	if res != nil && res.StatusCode == http.StatusNotModified {
38738		if res.Body != nil {
38739			res.Body.Close()
38740		}
38741		return nil, &googleapi.Error{
38742			Code:   res.StatusCode,
38743			Header: res.Header,
38744		}
38745	}
38746	if err != nil {
38747		return nil, err
38748	}
38749	defer googleapi.CloseBody(res)
38750	if err := googleapi.CheckResponse(res); err != nil {
38751		return nil, err
38752	}
38753	ret := &GoogleCloudDialogflowV2Intent{
38754		ServerResponse: googleapi.ServerResponse{
38755			Header:         res.Header,
38756			HTTPStatusCode: res.StatusCode,
38757		},
38758	}
38759	target := &ret
38760	if err := gensupport.DecodeResponse(target, res); err != nil {
38761		return nil, err
38762	}
38763	return ret, nil
38764	// {
38765	//   "description": "Updates the specified intent.",
38766	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents/{intentsId}",
38767	//   "httpMethod": "PATCH",
38768	//   "id": "dialogflow.projects.locations.agent.intents.patch",
38769	//   "parameterOrder": [
38770	//     "name"
38771	//   ],
38772	//   "parameters": {
38773	//     "intentView": {
38774	//       "description": "Optional. The resource view to apply to the returned intent.",
38775	//       "enum": [
38776	//         "INTENT_VIEW_UNSPECIFIED",
38777	//         "INTENT_VIEW_FULL"
38778	//       ],
38779	//       "enumDescriptions": [
38780	//         "Training phrases field is not populated in the response.",
38781	//         "All fields are populated."
38782	//       ],
38783	//       "location": "query",
38784	//       "type": "string"
38785	//     },
38786	//     "languageCode": {
38787	//       "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).",
38788	//       "location": "query",
38789	//       "type": "string"
38790	//     },
38791	//     "name": {
38792	//       "description": "Optional. The unique identifier of this intent. Required for Intents.UpdateIntent and Intents.BatchUpdateIntents methods. Format: `projects//agent/intents/`.",
38793	//       "location": "path",
38794	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/intents/[^/]+$",
38795	//       "required": true,
38796	//       "type": "string"
38797	//     },
38798	//     "updateMask": {
38799	//       "description": "Optional. The mask to control which fields get updated.",
38800	//       "format": "google-fieldmask",
38801	//       "location": "query",
38802	//       "type": "string"
38803	//     }
38804	//   },
38805	//   "path": "v2/{+name}",
38806	//   "request": {
38807	//     "$ref": "GoogleCloudDialogflowV2Intent"
38808	//   },
38809	//   "response": {
38810	//     "$ref": "GoogleCloudDialogflowV2Intent"
38811	//   },
38812	//   "scopes": [
38813	//     "https://www.googleapis.com/auth/cloud-platform",
38814	//     "https://www.googleapis.com/auth/dialogflow"
38815	//   ]
38816	// }
38817
38818}
38819
38820// method id "dialogflow.projects.locations.agent.sessions.deleteContexts":
38821
38822type ProjectsLocationsAgentSessionsDeleteContextsCall struct {
38823	s          *Service
38824	parent     string
38825	urlParams_ gensupport.URLParams
38826	ctx_       context.Context
38827	header_    http.Header
38828}
38829
38830// DeleteContexts: Deletes all active contexts in the specified session.
38831//
38832// - parent: The name of the session to delete all contexts from.
38833//   Format: `projects//agent/sessions/` or
38834//   `projects//agent/environments//users//sessions/`. If `Environment
38835//   ID` is not specified we assume default 'draft' environment. If
38836//   `User ID` is not specified, we assume default '-' user.
38837func (r *ProjectsLocationsAgentSessionsService) DeleteContexts(parent string) *ProjectsLocationsAgentSessionsDeleteContextsCall {
38838	c := &ProjectsLocationsAgentSessionsDeleteContextsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38839	c.parent = parent
38840	return c
38841}
38842
38843// Fields allows partial responses to be retrieved. See
38844// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38845// for more information.
38846func (c *ProjectsLocationsAgentSessionsDeleteContextsCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsDeleteContextsCall {
38847	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38848	return c
38849}
38850
38851// Context sets the context to be used in this call's Do method. Any
38852// pending HTTP request will be aborted if the provided context is
38853// canceled.
38854func (c *ProjectsLocationsAgentSessionsDeleteContextsCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsDeleteContextsCall {
38855	c.ctx_ = ctx
38856	return c
38857}
38858
38859// Header returns an http.Header that can be modified by the caller to
38860// add HTTP headers to the request.
38861func (c *ProjectsLocationsAgentSessionsDeleteContextsCall) Header() http.Header {
38862	if c.header_ == nil {
38863		c.header_ = make(http.Header)
38864	}
38865	return c.header_
38866}
38867
38868func (c *ProjectsLocationsAgentSessionsDeleteContextsCall) doRequest(alt string) (*http.Response, error) {
38869	reqHeaders := make(http.Header)
38870	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
38871	for k, v := range c.header_ {
38872		reqHeaders[k] = v
38873	}
38874	reqHeaders.Set("User-Agent", c.s.userAgent())
38875	var body io.Reader = nil
38876	c.urlParams_.Set("alt", alt)
38877	c.urlParams_.Set("prettyPrint", "false")
38878	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
38879	urls += "?" + c.urlParams_.Encode()
38880	req, err := http.NewRequest("DELETE", urls, body)
38881	if err != nil {
38882		return nil, err
38883	}
38884	req.Header = reqHeaders
38885	googleapi.Expand(req.URL, map[string]string{
38886		"parent": c.parent,
38887	})
38888	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38889}
38890
38891// Do executes the "dialogflow.projects.locations.agent.sessions.deleteContexts" call.
38892// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
38893// non-2xx status code is an error. Response headers are in either
38894// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
38895// returned at all) in error.(*googleapi.Error).Header. Use
38896// googleapi.IsNotModified to check whether the returned error was
38897// because http.StatusNotModified was returned.
38898func (c *ProjectsLocationsAgentSessionsDeleteContextsCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
38899	gensupport.SetOptions(c.urlParams_, opts...)
38900	res, err := c.doRequest("json")
38901	if res != nil && res.StatusCode == http.StatusNotModified {
38902		if res.Body != nil {
38903			res.Body.Close()
38904		}
38905		return nil, &googleapi.Error{
38906			Code:   res.StatusCode,
38907			Header: res.Header,
38908		}
38909	}
38910	if err != nil {
38911		return nil, err
38912	}
38913	defer googleapi.CloseBody(res)
38914	if err := googleapi.CheckResponse(res); err != nil {
38915		return nil, err
38916	}
38917	ret := &GoogleProtobufEmpty{
38918		ServerResponse: googleapi.ServerResponse{
38919			Header:         res.Header,
38920			HTTPStatusCode: res.StatusCode,
38921		},
38922	}
38923	target := &ret
38924	if err := gensupport.DecodeResponse(target, res); err != nil {
38925		return nil, err
38926	}
38927	return ret, nil
38928	// {
38929	//   "description": "Deletes all active contexts in the specified session.",
38930	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/contexts",
38931	//   "httpMethod": "DELETE",
38932	//   "id": "dialogflow.projects.locations.agent.sessions.deleteContexts",
38933	//   "parameterOrder": [
38934	//     "parent"
38935	//   ],
38936	//   "parameters": {
38937	//     "parent": {
38938	//       "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.",
38939	//       "location": "path",
38940	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+$",
38941	//       "required": true,
38942	//       "type": "string"
38943	//     }
38944	//   },
38945	//   "path": "v2/{+parent}/contexts",
38946	//   "response": {
38947	//     "$ref": "GoogleProtobufEmpty"
38948	//   },
38949	//   "scopes": [
38950	//     "https://www.googleapis.com/auth/cloud-platform",
38951	//     "https://www.googleapis.com/auth/dialogflow"
38952	//   ]
38953	// }
38954
38955}
38956
38957// method id "dialogflow.projects.locations.agent.sessions.detectIntent":
38958
38959type ProjectsLocationsAgentSessionsDetectIntentCall struct {
38960	s                                          *Service
38961	sessionid                                  string
38962	googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest
38963	urlParams_                                 gensupport.URLParams
38964	ctx_                                       context.Context
38965	header_                                    http.Header
38966}
38967
38968// DetectIntent: Processes a natural language query and returns
38969// structured, actionable data as a result. This method is not
38970// idempotent, because it may cause contexts and session entity types to
38971// be updated, which in turn might affect results of future queries.
38972// Note: Always use agent versions for production traffic. See Versions
38973// and environments
38974// (https://cloud.google.com/dialogflow/es/docs/agents-versions).
38975//
38976// - session: The name of the session this query is sent to. Format:
38977//   `projects//agent/sessions/`, or
38978//   `projects//agent/environments//users//sessions/`. If `Environment
38979//   ID` is not specified, we assume default 'draft' environment
38980//   (`Environment ID` might be referred to as environment name at some
38981//   places). If `User ID` is not specified, we are using "-". It's up
38982//   to the API caller to choose an appropriate `Session ID` and `User
38983//   Id`. They can be a random number or some type of user and session
38984//   identifiers (preferably hashed). The length of the `Session ID` and
38985//   `User ID` must not exceed 36 characters. For more information, see
38986//   the API interactions guide
38987//   (https://cloud.google.com/dialogflow/docs/api-overview). Note:
38988//   Always use agent versions for production traffic. See Versions and
38989//   environments
38990//   (https://cloud.google.com/dialogflow/es/docs/agents-versions).
38991func (r *ProjectsLocationsAgentSessionsService) DetectIntent(sessionid string, googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest) *ProjectsLocationsAgentSessionsDetectIntentCall {
38992	c := &ProjectsLocationsAgentSessionsDetectIntentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38993	c.sessionid = sessionid
38994	c.googleclouddialogflowv2detectintentrequest = googleclouddialogflowv2detectintentrequest
38995	return c
38996}
38997
38998// Fields allows partial responses to be retrieved. See
38999// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39000// for more information.
39001func (c *ProjectsLocationsAgentSessionsDetectIntentCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsDetectIntentCall {
39002	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39003	return c
39004}
39005
39006// Context sets the context to be used in this call's Do method. Any
39007// pending HTTP request will be aborted if the provided context is
39008// canceled.
39009func (c *ProjectsLocationsAgentSessionsDetectIntentCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsDetectIntentCall {
39010	c.ctx_ = ctx
39011	return c
39012}
39013
39014// Header returns an http.Header that can be modified by the caller to
39015// add HTTP headers to the request.
39016func (c *ProjectsLocationsAgentSessionsDetectIntentCall) Header() http.Header {
39017	if c.header_ == nil {
39018		c.header_ = make(http.Header)
39019	}
39020	return c.header_
39021}
39022
39023func (c *ProjectsLocationsAgentSessionsDetectIntentCall) doRequest(alt string) (*http.Response, error) {
39024	reqHeaders := make(http.Header)
39025	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
39026	for k, v := range c.header_ {
39027		reqHeaders[k] = v
39028	}
39029	reqHeaders.Set("User-Agent", c.s.userAgent())
39030	var body io.Reader = nil
39031	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2detectintentrequest)
39032	if err != nil {
39033		return nil, err
39034	}
39035	reqHeaders.Set("Content-Type", "application/json")
39036	c.urlParams_.Set("alt", alt)
39037	c.urlParams_.Set("prettyPrint", "false")
39038	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+session}:detectIntent")
39039	urls += "?" + c.urlParams_.Encode()
39040	req, err := http.NewRequest("POST", urls, body)
39041	if err != nil {
39042		return nil, err
39043	}
39044	req.Header = reqHeaders
39045	googleapi.Expand(req.URL, map[string]string{
39046		"session": c.sessionid,
39047	})
39048	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39049}
39050
39051// Do executes the "dialogflow.projects.locations.agent.sessions.detectIntent" call.
39052// Exactly one of *GoogleCloudDialogflowV2DetectIntentResponse or error
39053// will be non-nil. Any non-2xx status code is an error. Response
39054// headers are in either
39055// *GoogleCloudDialogflowV2DetectIntentResponse.ServerResponse.Header or
39056// (if a response was returned at all) in
39057// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
39058// whether the returned error was because http.StatusNotModified was
39059// returned.
39060func (c *ProjectsLocationsAgentSessionsDetectIntentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2DetectIntentResponse, error) {
39061	gensupport.SetOptions(c.urlParams_, opts...)
39062	res, err := c.doRequest("json")
39063	if res != nil && res.StatusCode == http.StatusNotModified {
39064		if res.Body != nil {
39065			res.Body.Close()
39066		}
39067		return nil, &googleapi.Error{
39068			Code:   res.StatusCode,
39069			Header: res.Header,
39070		}
39071	}
39072	if err != nil {
39073		return nil, err
39074	}
39075	defer googleapi.CloseBody(res)
39076	if err := googleapi.CheckResponse(res); err != nil {
39077		return nil, err
39078	}
39079	ret := &GoogleCloudDialogflowV2DetectIntentResponse{
39080		ServerResponse: googleapi.ServerResponse{
39081			Header:         res.Header,
39082			HTTPStatusCode: res.StatusCode,
39083		},
39084	}
39085	target := &ret
39086	if err := gensupport.DecodeResponse(target, res); err != nil {
39087		return nil, err
39088	}
39089	return ret, nil
39090	// {
39091	//   "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. Note: Always use agent versions for production traffic. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
39092	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}:detectIntent",
39093	//   "httpMethod": "POST",
39094	//   "id": "dialogflow.projects.locations.agent.sessions.detectIntent",
39095	//   "parameterOrder": [
39096	//     "session"
39097	//   ],
39098	//   "parameters": {
39099	//     "session": {
39100	//       "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).",
39101	//       "location": "path",
39102	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+$",
39103	//       "required": true,
39104	//       "type": "string"
39105	//     }
39106	//   },
39107	//   "path": "v2/{+session}:detectIntent",
39108	//   "request": {
39109	//     "$ref": "GoogleCloudDialogflowV2DetectIntentRequest"
39110	//   },
39111	//   "response": {
39112	//     "$ref": "GoogleCloudDialogflowV2DetectIntentResponse"
39113	//   },
39114	//   "scopes": [
39115	//     "https://www.googleapis.com/auth/cloud-platform",
39116	//     "https://www.googleapis.com/auth/dialogflow"
39117	//   ]
39118	// }
39119
39120}
39121
39122// method id "dialogflow.projects.locations.agent.sessions.contexts.create":
39123
39124type ProjectsLocationsAgentSessionsContextsCreateCall struct {
39125	s                              *Service
39126	parent                         string
39127	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
39128	urlParams_                     gensupport.URLParams
39129	ctx_                           context.Context
39130	header_                        http.Header
39131}
39132
39133// Create: Creates a context. If the specified context already exists,
39134// overrides the context.
39135//
39136// - parent: The session to create a context for. Format:
39137//   `projects//agent/sessions/` or
39138//   `projects//agent/environments//users//sessions/`. If `Environment
39139//   ID` is not specified, we assume default 'draft' environment. If
39140//   `User ID` is not specified, we assume default '-' user.
39141func (r *ProjectsLocationsAgentSessionsContextsService) Create(parent string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsLocationsAgentSessionsContextsCreateCall {
39142	c := &ProjectsLocationsAgentSessionsContextsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39143	c.parent = parent
39144	c.googleclouddialogflowv2context = googleclouddialogflowv2context
39145	return c
39146}
39147
39148// Fields allows partial responses to be retrieved. See
39149// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39150// for more information.
39151func (c *ProjectsLocationsAgentSessionsContextsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsContextsCreateCall {
39152	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39153	return c
39154}
39155
39156// Context sets the context to be used in this call's Do method. Any
39157// pending HTTP request will be aborted if the provided context is
39158// canceled.
39159func (c *ProjectsLocationsAgentSessionsContextsCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsContextsCreateCall {
39160	c.ctx_ = ctx
39161	return c
39162}
39163
39164// Header returns an http.Header that can be modified by the caller to
39165// add HTTP headers to the request.
39166func (c *ProjectsLocationsAgentSessionsContextsCreateCall) Header() http.Header {
39167	if c.header_ == nil {
39168		c.header_ = make(http.Header)
39169	}
39170	return c.header_
39171}
39172
39173func (c *ProjectsLocationsAgentSessionsContextsCreateCall) doRequest(alt string) (*http.Response, error) {
39174	reqHeaders := make(http.Header)
39175	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
39176	for k, v := range c.header_ {
39177		reqHeaders[k] = v
39178	}
39179	reqHeaders.Set("User-Agent", c.s.userAgent())
39180	var body io.Reader = nil
39181	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
39182	if err != nil {
39183		return nil, err
39184	}
39185	reqHeaders.Set("Content-Type", "application/json")
39186	c.urlParams_.Set("alt", alt)
39187	c.urlParams_.Set("prettyPrint", "false")
39188	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
39189	urls += "?" + c.urlParams_.Encode()
39190	req, err := http.NewRequest("POST", urls, body)
39191	if err != nil {
39192		return nil, err
39193	}
39194	req.Header = reqHeaders
39195	googleapi.Expand(req.URL, map[string]string{
39196		"parent": c.parent,
39197	})
39198	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39199}
39200
39201// Do executes the "dialogflow.projects.locations.agent.sessions.contexts.create" call.
39202// Exactly one of *GoogleCloudDialogflowV2Context or error will be
39203// non-nil. Any non-2xx status code is an error. Response headers are in
39204// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
39205// response was returned at all) in error.(*googleapi.Error).Header. Use
39206// googleapi.IsNotModified to check whether the returned error was
39207// because http.StatusNotModified was returned.
39208func (c *ProjectsLocationsAgentSessionsContextsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
39209	gensupport.SetOptions(c.urlParams_, opts...)
39210	res, err := c.doRequest("json")
39211	if res != nil && res.StatusCode == http.StatusNotModified {
39212		if res.Body != nil {
39213			res.Body.Close()
39214		}
39215		return nil, &googleapi.Error{
39216			Code:   res.StatusCode,
39217			Header: res.Header,
39218		}
39219	}
39220	if err != nil {
39221		return nil, err
39222	}
39223	defer googleapi.CloseBody(res)
39224	if err := googleapi.CheckResponse(res); err != nil {
39225		return nil, err
39226	}
39227	ret := &GoogleCloudDialogflowV2Context{
39228		ServerResponse: googleapi.ServerResponse{
39229			Header:         res.Header,
39230			HTTPStatusCode: res.StatusCode,
39231		},
39232	}
39233	target := &ret
39234	if err := gensupport.DecodeResponse(target, res); err != nil {
39235		return nil, err
39236	}
39237	return ret, nil
39238	// {
39239	//   "description": "Creates a context. If the specified context already exists, overrides the context.",
39240	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/contexts",
39241	//   "httpMethod": "POST",
39242	//   "id": "dialogflow.projects.locations.agent.sessions.contexts.create",
39243	//   "parameterOrder": [
39244	//     "parent"
39245	//   ],
39246	//   "parameters": {
39247	//     "parent": {
39248	//       "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.",
39249	//       "location": "path",
39250	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+$",
39251	//       "required": true,
39252	//       "type": "string"
39253	//     }
39254	//   },
39255	//   "path": "v2/{+parent}/contexts",
39256	//   "request": {
39257	//     "$ref": "GoogleCloudDialogflowV2Context"
39258	//   },
39259	//   "response": {
39260	//     "$ref": "GoogleCloudDialogflowV2Context"
39261	//   },
39262	//   "scopes": [
39263	//     "https://www.googleapis.com/auth/cloud-platform",
39264	//     "https://www.googleapis.com/auth/dialogflow"
39265	//   ]
39266	// }
39267
39268}
39269
39270// method id "dialogflow.projects.locations.agent.sessions.contexts.delete":
39271
39272type ProjectsLocationsAgentSessionsContextsDeleteCall struct {
39273	s          *Service
39274	name       string
39275	urlParams_ gensupport.URLParams
39276	ctx_       context.Context
39277	header_    http.Header
39278}
39279
39280// Delete: Deletes the specified context.
39281//
39282// - name: The name of the context to delete. Format:
39283//   `projects//agent/sessions//contexts/` or
39284//   `projects//agent/environments//users//sessions//contexts/`. If
39285//   `Environment ID` is not specified, we assume default 'draft'
39286//   environment. If `User ID` is not specified, we assume default '-'
39287//   user.
39288func (r *ProjectsLocationsAgentSessionsContextsService) Delete(name string) *ProjectsLocationsAgentSessionsContextsDeleteCall {
39289	c := &ProjectsLocationsAgentSessionsContextsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39290	c.name = name
39291	return c
39292}
39293
39294// Fields allows partial responses to be retrieved. See
39295// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39296// for more information.
39297func (c *ProjectsLocationsAgentSessionsContextsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsContextsDeleteCall {
39298	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39299	return c
39300}
39301
39302// Context sets the context to be used in this call's Do method. Any
39303// pending HTTP request will be aborted if the provided context is
39304// canceled.
39305func (c *ProjectsLocationsAgentSessionsContextsDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsContextsDeleteCall {
39306	c.ctx_ = ctx
39307	return c
39308}
39309
39310// Header returns an http.Header that can be modified by the caller to
39311// add HTTP headers to the request.
39312func (c *ProjectsLocationsAgentSessionsContextsDeleteCall) Header() http.Header {
39313	if c.header_ == nil {
39314		c.header_ = make(http.Header)
39315	}
39316	return c.header_
39317}
39318
39319func (c *ProjectsLocationsAgentSessionsContextsDeleteCall) doRequest(alt string) (*http.Response, error) {
39320	reqHeaders := make(http.Header)
39321	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
39322	for k, v := range c.header_ {
39323		reqHeaders[k] = v
39324	}
39325	reqHeaders.Set("User-Agent", c.s.userAgent())
39326	var body io.Reader = nil
39327	c.urlParams_.Set("alt", alt)
39328	c.urlParams_.Set("prettyPrint", "false")
39329	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
39330	urls += "?" + c.urlParams_.Encode()
39331	req, err := http.NewRequest("DELETE", urls, body)
39332	if err != nil {
39333		return nil, err
39334	}
39335	req.Header = reqHeaders
39336	googleapi.Expand(req.URL, map[string]string{
39337		"name": c.name,
39338	})
39339	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39340}
39341
39342// Do executes the "dialogflow.projects.locations.agent.sessions.contexts.delete" call.
39343// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
39344// non-2xx status code is an error. Response headers are in either
39345// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
39346// returned at all) in error.(*googleapi.Error).Header. Use
39347// googleapi.IsNotModified to check whether the returned error was
39348// because http.StatusNotModified was returned.
39349func (c *ProjectsLocationsAgentSessionsContextsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
39350	gensupport.SetOptions(c.urlParams_, opts...)
39351	res, err := c.doRequest("json")
39352	if res != nil && res.StatusCode == http.StatusNotModified {
39353		if res.Body != nil {
39354			res.Body.Close()
39355		}
39356		return nil, &googleapi.Error{
39357			Code:   res.StatusCode,
39358			Header: res.Header,
39359		}
39360	}
39361	if err != nil {
39362		return nil, err
39363	}
39364	defer googleapi.CloseBody(res)
39365	if err := googleapi.CheckResponse(res); err != nil {
39366		return nil, err
39367	}
39368	ret := &GoogleProtobufEmpty{
39369		ServerResponse: googleapi.ServerResponse{
39370			Header:         res.Header,
39371			HTTPStatusCode: res.StatusCode,
39372		},
39373	}
39374	target := &ret
39375	if err := gensupport.DecodeResponse(target, res); err != nil {
39376		return nil, err
39377	}
39378	return ret, nil
39379	// {
39380	//   "description": "Deletes the specified context.",
39381	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/contexts/{contextsId}",
39382	//   "httpMethod": "DELETE",
39383	//   "id": "dialogflow.projects.locations.agent.sessions.contexts.delete",
39384	//   "parameterOrder": [
39385	//     "name"
39386	//   ],
39387	//   "parameters": {
39388	//     "name": {
39389	//       "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.",
39390	//       "location": "path",
39391	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+/contexts/[^/]+$",
39392	//       "required": true,
39393	//       "type": "string"
39394	//     }
39395	//   },
39396	//   "path": "v2/{+name}",
39397	//   "response": {
39398	//     "$ref": "GoogleProtobufEmpty"
39399	//   },
39400	//   "scopes": [
39401	//     "https://www.googleapis.com/auth/cloud-platform",
39402	//     "https://www.googleapis.com/auth/dialogflow"
39403	//   ]
39404	// }
39405
39406}
39407
39408// method id "dialogflow.projects.locations.agent.sessions.contexts.get":
39409
39410type ProjectsLocationsAgentSessionsContextsGetCall struct {
39411	s            *Service
39412	name         string
39413	urlParams_   gensupport.URLParams
39414	ifNoneMatch_ string
39415	ctx_         context.Context
39416	header_      http.Header
39417}
39418
39419// Get: Retrieves the specified context.
39420//
39421// - name: The name of the context. Format:
39422//   `projects//agent/sessions//contexts/` or
39423//   `projects//agent/environments//users//sessions//contexts/`. If
39424//   `Environment ID` is not specified, we assume default 'draft'
39425//   environment. If `User ID` is not specified, we assume default '-'
39426//   user.
39427func (r *ProjectsLocationsAgentSessionsContextsService) Get(name string) *ProjectsLocationsAgentSessionsContextsGetCall {
39428	c := &ProjectsLocationsAgentSessionsContextsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39429	c.name = name
39430	return c
39431}
39432
39433// Fields allows partial responses to be retrieved. See
39434// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39435// for more information.
39436func (c *ProjectsLocationsAgentSessionsContextsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsContextsGetCall {
39437	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39438	return c
39439}
39440
39441// IfNoneMatch sets the optional parameter which makes the operation
39442// fail if the object's ETag matches the given value. This is useful for
39443// getting updates only after the object has changed since the last
39444// request. Use googleapi.IsNotModified to check whether the response
39445// error from Do is the result of In-None-Match.
39446func (c *ProjectsLocationsAgentSessionsContextsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentSessionsContextsGetCall {
39447	c.ifNoneMatch_ = entityTag
39448	return c
39449}
39450
39451// Context sets the context to be used in this call's Do method. Any
39452// pending HTTP request will be aborted if the provided context is
39453// canceled.
39454func (c *ProjectsLocationsAgentSessionsContextsGetCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsContextsGetCall {
39455	c.ctx_ = ctx
39456	return c
39457}
39458
39459// Header returns an http.Header that can be modified by the caller to
39460// add HTTP headers to the request.
39461func (c *ProjectsLocationsAgentSessionsContextsGetCall) Header() http.Header {
39462	if c.header_ == nil {
39463		c.header_ = make(http.Header)
39464	}
39465	return c.header_
39466}
39467
39468func (c *ProjectsLocationsAgentSessionsContextsGetCall) doRequest(alt string) (*http.Response, error) {
39469	reqHeaders := make(http.Header)
39470	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
39471	for k, v := range c.header_ {
39472		reqHeaders[k] = v
39473	}
39474	reqHeaders.Set("User-Agent", c.s.userAgent())
39475	if c.ifNoneMatch_ != "" {
39476		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39477	}
39478	var body io.Reader = nil
39479	c.urlParams_.Set("alt", alt)
39480	c.urlParams_.Set("prettyPrint", "false")
39481	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
39482	urls += "?" + c.urlParams_.Encode()
39483	req, err := http.NewRequest("GET", urls, body)
39484	if err != nil {
39485		return nil, err
39486	}
39487	req.Header = reqHeaders
39488	googleapi.Expand(req.URL, map[string]string{
39489		"name": c.name,
39490	})
39491	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39492}
39493
39494// Do executes the "dialogflow.projects.locations.agent.sessions.contexts.get" call.
39495// Exactly one of *GoogleCloudDialogflowV2Context or error will be
39496// non-nil. Any non-2xx status code is an error. Response headers are in
39497// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
39498// response was returned at all) in error.(*googleapi.Error).Header. Use
39499// googleapi.IsNotModified to check whether the returned error was
39500// because http.StatusNotModified was returned.
39501func (c *ProjectsLocationsAgentSessionsContextsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
39502	gensupport.SetOptions(c.urlParams_, opts...)
39503	res, err := c.doRequest("json")
39504	if res != nil && res.StatusCode == http.StatusNotModified {
39505		if res.Body != nil {
39506			res.Body.Close()
39507		}
39508		return nil, &googleapi.Error{
39509			Code:   res.StatusCode,
39510			Header: res.Header,
39511		}
39512	}
39513	if err != nil {
39514		return nil, err
39515	}
39516	defer googleapi.CloseBody(res)
39517	if err := googleapi.CheckResponse(res); err != nil {
39518		return nil, err
39519	}
39520	ret := &GoogleCloudDialogflowV2Context{
39521		ServerResponse: googleapi.ServerResponse{
39522			Header:         res.Header,
39523			HTTPStatusCode: res.StatusCode,
39524		},
39525	}
39526	target := &ret
39527	if err := gensupport.DecodeResponse(target, res); err != nil {
39528		return nil, err
39529	}
39530	return ret, nil
39531	// {
39532	//   "description": "Retrieves the specified context.",
39533	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/contexts/{contextsId}",
39534	//   "httpMethod": "GET",
39535	//   "id": "dialogflow.projects.locations.agent.sessions.contexts.get",
39536	//   "parameterOrder": [
39537	//     "name"
39538	//   ],
39539	//   "parameters": {
39540	//     "name": {
39541	//       "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.",
39542	//       "location": "path",
39543	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+/contexts/[^/]+$",
39544	//       "required": true,
39545	//       "type": "string"
39546	//     }
39547	//   },
39548	//   "path": "v2/{+name}",
39549	//   "response": {
39550	//     "$ref": "GoogleCloudDialogflowV2Context"
39551	//   },
39552	//   "scopes": [
39553	//     "https://www.googleapis.com/auth/cloud-platform",
39554	//     "https://www.googleapis.com/auth/dialogflow"
39555	//   ]
39556	// }
39557
39558}
39559
39560// method id "dialogflow.projects.locations.agent.sessions.contexts.list":
39561
39562type ProjectsLocationsAgentSessionsContextsListCall struct {
39563	s            *Service
39564	parent       string
39565	urlParams_   gensupport.URLParams
39566	ifNoneMatch_ string
39567	ctx_         context.Context
39568	header_      http.Header
39569}
39570
39571// List: Returns the list of all contexts in the specified session.
39572//
39573// - parent: The session to list all contexts from. Format:
39574//   `projects//agent/sessions/` or
39575//   `projects//agent/environments//users//sessions/`. If `Environment
39576//   ID` is not specified, we assume default 'draft' environment. If
39577//   `User ID` is not specified, we assume default '-' user.
39578func (r *ProjectsLocationsAgentSessionsContextsService) List(parent string) *ProjectsLocationsAgentSessionsContextsListCall {
39579	c := &ProjectsLocationsAgentSessionsContextsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39580	c.parent = parent
39581	return c
39582}
39583
39584// PageSize sets the optional parameter "pageSize": The maximum number
39585// of items to return in a single page. By default 100 and at most 1000.
39586func (c *ProjectsLocationsAgentSessionsContextsListCall) PageSize(pageSize int64) *ProjectsLocationsAgentSessionsContextsListCall {
39587	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
39588	return c
39589}
39590
39591// PageToken sets the optional parameter "pageToken": The
39592// next_page_token value returned from a previous list request.
39593func (c *ProjectsLocationsAgentSessionsContextsListCall) PageToken(pageToken string) *ProjectsLocationsAgentSessionsContextsListCall {
39594	c.urlParams_.Set("pageToken", pageToken)
39595	return c
39596}
39597
39598// Fields allows partial responses to be retrieved. See
39599// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39600// for more information.
39601func (c *ProjectsLocationsAgentSessionsContextsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsContextsListCall {
39602	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39603	return c
39604}
39605
39606// IfNoneMatch sets the optional parameter which makes the operation
39607// fail if the object's ETag matches the given value. This is useful for
39608// getting updates only after the object has changed since the last
39609// request. Use googleapi.IsNotModified to check whether the response
39610// error from Do is the result of In-None-Match.
39611func (c *ProjectsLocationsAgentSessionsContextsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentSessionsContextsListCall {
39612	c.ifNoneMatch_ = entityTag
39613	return c
39614}
39615
39616// Context sets the context to be used in this call's Do method. Any
39617// pending HTTP request will be aborted if the provided context is
39618// canceled.
39619func (c *ProjectsLocationsAgentSessionsContextsListCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsContextsListCall {
39620	c.ctx_ = ctx
39621	return c
39622}
39623
39624// Header returns an http.Header that can be modified by the caller to
39625// add HTTP headers to the request.
39626func (c *ProjectsLocationsAgentSessionsContextsListCall) Header() http.Header {
39627	if c.header_ == nil {
39628		c.header_ = make(http.Header)
39629	}
39630	return c.header_
39631}
39632
39633func (c *ProjectsLocationsAgentSessionsContextsListCall) doRequest(alt string) (*http.Response, error) {
39634	reqHeaders := make(http.Header)
39635	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
39636	for k, v := range c.header_ {
39637		reqHeaders[k] = v
39638	}
39639	reqHeaders.Set("User-Agent", c.s.userAgent())
39640	if c.ifNoneMatch_ != "" {
39641		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39642	}
39643	var body io.Reader = nil
39644	c.urlParams_.Set("alt", alt)
39645	c.urlParams_.Set("prettyPrint", "false")
39646	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
39647	urls += "?" + c.urlParams_.Encode()
39648	req, err := http.NewRequest("GET", urls, body)
39649	if err != nil {
39650		return nil, err
39651	}
39652	req.Header = reqHeaders
39653	googleapi.Expand(req.URL, map[string]string{
39654		"parent": c.parent,
39655	})
39656	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39657}
39658
39659// Do executes the "dialogflow.projects.locations.agent.sessions.contexts.list" call.
39660// Exactly one of *GoogleCloudDialogflowV2ListContextsResponse or error
39661// will be non-nil. Any non-2xx status code is an error. Response
39662// headers are in either
39663// *GoogleCloudDialogflowV2ListContextsResponse.ServerResponse.Header or
39664// (if a response was returned at all) in
39665// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
39666// whether the returned error was because http.StatusNotModified was
39667// returned.
39668func (c *ProjectsLocationsAgentSessionsContextsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListContextsResponse, error) {
39669	gensupport.SetOptions(c.urlParams_, opts...)
39670	res, err := c.doRequest("json")
39671	if res != nil && res.StatusCode == http.StatusNotModified {
39672		if res.Body != nil {
39673			res.Body.Close()
39674		}
39675		return nil, &googleapi.Error{
39676			Code:   res.StatusCode,
39677			Header: res.Header,
39678		}
39679	}
39680	if err != nil {
39681		return nil, err
39682	}
39683	defer googleapi.CloseBody(res)
39684	if err := googleapi.CheckResponse(res); err != nil {
39685		return nil, err
39686	}
39687	ret := &GoogleCloudDialogflowV2ListContextsResponse{
39688		ServerResponse: googleapi.ServerResponse{
39689			Header:         res.Header,
39690			HTTPStatusCode: res.StatusCode,
39691		},
39692	}
39693	target := &ret
39694	if err := gensupport.DecodeResponse(target, res); err != nil {
39695		return nil, err
39696	}
39697	return ret, nil
39698	// {
39699	//   "description": "Returns the list of all contexts in the specified session.",
39700	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/contexts",
39701	//   "httpMethod": "GET",
39702	//   "id": "dialogflow.projects.locations.agent.sessions.contexts.list",
39703	//   "parameterOrder": [
39704	//     "parent"
39705	//   ],
39706	//   "parameters": {
39707	//     "pageSize": {
39708	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
39709	//       "format": "int32",
39710	//       "location": "query",
39711	//       "type": "integer"
39712	//     },
39713	//     "pageToken": {
39714	//       "description": "Optional. The next_page_token value returned from a previous list request.",
39715	//       "location": "query",
39716	//       "type": "string"
39717	//     },
39718	//     "parent": {
39719	//       "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.",
39720	//       "location": "path",
39721	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+$",
39722	//       "required": true,
39723	//       "type": "string"
39724	//     }
39725	//   },
39726	//   "path": "v2/{+parent}/contexts",
39727	//   "response": {
39728	//     "$ref": "GoogleCloudDialogflowV2ListContextsResponse"
39729	//   },
39730	//   "scopes": [
39731	//     "https://www.googleapis.com/auth/cloud-platform",
39732	//     "https://www.googleapis.com/auth/dialogflow"
39733	//   ]
39734	// }
39735
39736}
39737
39738// Pages invokes f for each page of results.
39739// A non-nil error returned from f will halt the iteration.
39740// The provided context supersedes any context provided to the Context method.
39741func (c *ProjectsLocationsAgentSessionsContextsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListContextsResponse) error) error {
39742	c.ctx_ = ctx
39743	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
39744	for {
39745		x, err := c.Do()
39746		if err != nil {
39747			return err
39748		}
39749		if err := f(x); err != nil {
39750			return err
39751		}
39752		if x.NextPageToken == "" {
39753			return nil
39754		}
39755		c.PageToken(x.NextPageToken)
39756	}
39757}
39758
39759// method id "dialogflow.projects.locations.agent.sessions.contexts.patch":
39760
39761type ProjectsLocationsAgentSessionsContextsPatchCall struct {
39762	s                              *Service
39763	nameid                         string
39764	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
39765	urlParams_                     gensupport.URLParams
39766	ctx_                           context.Context
39767	header_                        http.Header
39768}
39769
39770// Patch: Updates the specified context.
39771//
39772// - name: The unique identifier of the context. Format:
39773//   `projects//agent/sessions//contexts/`, or
39774//   `projects//agent/environments//users//sessions//contexts/`. The
39775//   `Context ID` is always converted to lowercase, may only contain
39776//   characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If
39777//   `Environment ID` is not specified, we assume default 'draft'
39778//   environment. If `User ID` is not specified, we assume default '-'
39779//   user. The following context names are reserved for internal use by
39780//   Dialogflow. You should not use these contexts or create contexts
39781//   with these names: * `__system_counters__` * `*_id_dialog_context` *
39782//   `*_dialog_params_size`.
39783func (r *ProjectsLocationsAgentSessionsContextsService) Patch(nameid string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsLocationsAgentSessionsContextsPatchCall {
39784	c := &ProjectsLocationsAgentSessionsContextsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39785	c.nameid = nameid
39786	c.googleclouddialogflowv2context = googleclouddialogflowv2context
39787	return c
39788}
39789
39790// UpdateMask sets the optional parameter "updateMask": The mask to
39791// control which fields get updated.
39792func (c *ProjectsLocationsAgentSessionsContextsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentSessionsContextsPatchCall {
39793	c.urlParams_.Set("updateMask", updateMask)
39794	return c
39795}
39796
39797// Fields allows partial responses to be retrieved. See
39798// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39799// for more information.
39800func (c *ProjectsLocationsAgentSessionsContextsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsContextsPatchCall {
39801	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39802	return c
39803}
39804
39805// Context sets the context to be used in this call's Do method. Any
39806// pending HTTP request will be aborted if the provided context is
39807// canceled.
39808func (c *ProjectsLocationsAgentSessionsContextsPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsContextsPatchCall {
39809	c.ctx_ = ctx
39810	return c
39811}
39812
39813// Header returns an http.Header that can be modified by the caller to
39814// add HTTP headers to the request.
39815func (c *ProjectsLocationsAgentSessionsContextsPatchCall) Header() http.Header {
39816	if c.header_ == nil {
39817		c.header_ = make(http.Header)
39818	}
39819	return c.header_
39820}
39821
39822func (c *ProjectsLocationsAgentSessionsContextsPatchCall) doRequest(alt string) (*http.Response, error) {
39823	reqHeaders := make(http.Header)
39824	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
39825	for k, v := range c.header_ {
39826		reqHeaders[k] = v
39827	}
39828	reqHeaders.Set("User-Agent", c.s.userAgent())
39829	var body io.Reader = nil
39830	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
39831	if err != nil {
39832		return nil, err
39833	}
39834	reqHeaders.Set("Content-Type", "application/json")
39835	c.urlParams_.Set("alt", alt)
39836	c.urlParams_.Set("prettyPrint", "false")
39837	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
39838	urls += "?" + c.urlParams_.Encode()
39839	req, err := http.NewRequest("PATCH", urls, body)
39840	if err != nil {
39841		return nil, err
39842	}
39843	req.Header = reqHeaders
39844	googleapi.Expand(req.URL, map[string]string{
39845		"name": c.nameid,
39846	})
39847	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39848}
39849
39850// Do executes the "dialogflow.projects.locations.agent.sessions.contexts.patch" call.
39851// Exactly one of *GoogleCloudDialogflowV2Context or error will be
39852// non-nil. Any non-2xx status code is an error. Response headers are in
39853// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
39854// response was returned at all) in error.(*googleapi.Error).Header. Use
39855// googleapi.IsNotModified to check whether the returned error was
39856// because http.StatusNotModified was returned.
39857func (c *ProjectsLocationsAgentSessionsContextsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
39858	gensupport.SetOptions(c.urlParams_, opts...)
39859	res, err := c.doRequest("json")
39860	if res != nil && res.StatusCode == http.StatusNotModified {
39861		if res.Body != nil {
39862			res.Body.Close()
39863		}
39864		return nil, &googleapi.Error{
39865			Code:   res.StatusCode,
39866			Header: res.Header,
39867		}
39868	}
39869	if err != nil {
39870		return nil, err
39871	}
39872	defer googleapi.CloseBody(res)
39873	if err := googleapi.CheckResponse(res); err != nil {
39874		return nil, err
39875	}
39876	ret := &GoogleCloudDialogflowV2Context{
39877		ServerResponse: googleapi.ServerResponse{
39878			Header:         res.Header,
39879			HTTPStatusCode: res.StatusCode,
39880		},
39881	}
39882	target := &ret
39883	if err := gensupport.DecodeResponse(target, res); err != nil {
39884		return nil, err
39885	}
39886	return ret, nil
39887	// {
39888	//   "description": "Updates the specified context.",
39889	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/contexts/{contextsId}",
39890	//   "httpMethod": "PATCH",
39891	//   "id": "dialogflow.projects.locations.agent.sessions.contexts.patch",
39892	//   "parameterOrder": [
39893	//     "name"
39894	//   ],
39895	//   "parameters": {
39896	//     "name": {
39897	//       "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`",
39898	//       "location": "path",
39899	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+/contexts/[^/]+$",
39900	//       "required": true,
39901	//       "type": "string"
39902	//     },
39903	//     "updateMask": {
39904	//       "description": "Optional. The mask to control which fields get updated.",
39905	//       "format": "google-fieldmask",
39906	//       "location": "query",
39907	//       "type": "string"
39908	//     }
39909	//   },
39910	//   "path": "v2/{+name}",
39911	//   "request": {
39912	//     "$ref": "GoogleCloudDialogflowV2Context"
39913	//   },
39914	//   "response": {
39915	//     "$ref": "GoogleCloudDialogflowV2Context"
39916	//   },
39917	//   "scopes": [
39918	//     "https://www.googleapis.com/auth/cloud-platform",
39919	//     "https://www.googleapis.com/auth/dialogflow"
39920	//   ]
39921	// }
39922
39923}
39924
39925// method id "dialogflow.projects.locations.agent.sessions.entityTypes.create":
39926
39927type ProjectsLocationsAgentSessionsEntityTypesCreateCall struct {
39928	s                                        *Service
39929	parent                                   string
39930	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
39931	urlParams_                               gensupport.URLParams
39932	ctx_                                     context.Context
39933	header_                                  http.Header
39934}
39935
39936// Create: Creates a session entity type. If the specified session
39937// entity type already exists, overrides the session entity type. This
39938// method doesn't work with Google Assistant integration. Contact
39939// Dialogflow support if you need to use session entities with Google
39940// Assistant integration.
39941//
39942// - parent: The session to create a session entity type for. Format:
39943//   `projects//agent/sessions/` or
39944//   `projects//agent/environments//users// sessions/`. If `Environment
39945//   ID` is not specified, we assume default 'draft' environment. If
39946//   `User ID` is not specified, we assume default '-' user.
39947func (r *ProjectsLocationsAgentSessionsEntityTypesService) Create(parent string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsLocationsAgentSessionsEntityTypesCreateCall {
39948	c := &ProjectsLocationsAgentSessionsEntityTypesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39949	c.parent = parent
39950	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
39951	return c
39952}
39953
39954// Fields allows partial responses to be retrieved. See
39955// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39956// for more information.
39957func (c *ProjectsLocationsAgentSessionsEntityTypesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsEntityTypesCreateCall {
39958	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39959	return c
39960}
39961
39962// Context sets the context to be used in this call's Do method. Any
39963// pending HTTP request will be aborted if the provided context is
39964// canceled.
39965func (c *ProjectsLocationsAgentSessionsEntityTypesCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsEntityTypesCreateCall {
39966	c.ctx_ = ctx
39967	return c
39968}
39969
39970// Header returns an http.Header that can be modified by the caller to
39971// add HTTP headers to the request.
39972func (c *ProjectsLocationsAgentSessionsEntityTypesCreateCall) Header() http.Header {
39973	if c.header_ == nil {
39974		c.header_ = make(http.Header)
39975	}
39976	return c.header_
39977}
39978
39979func (c *ProjectsLocationsAgentSessionsEntityTypesCreateCall) doRequest(alt string) (*http.Response, error) {
39980	reqHeaders := make(http.Header)
39981	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
39982	for k, v := range c.header_ {
39983		reqHeaders[k] = v
39984	}
39985	reqHeaders.Set("User-Agent", c.s.userAgent())
39986	var body io.Reader = nil
39987	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
39988	if err != nil {
39989		return nil, err
39990	}
39991	reqHeaders.Set("Content-Type", "application/json")
39992	c.urlParams_.Set("alt", alt)
39993	c.urlParams_.Set("prettyPrint", "false")
39994	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
39995	urls += "?" + c.urlParams_.Encode()
39996	req, err := http.NewRequest("POST", urls, body)
39997	if err != nil {
39998		return nil, err
39999	}
40000	req.Header = reqHeaders
40001	googleapi.Expand(req.URL, map[string]string{
40002		"parent": c.parent,
40003	})
40004	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40005}
40006
40007// Do executes the "dialogflow.projects.locations.agent.sessions.entityTypes.create" call.
40008// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
40009// will be non-nil. Any non-2xx status code is an error. Response
40010// headers are in either
40011// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
40012// (if a response was returned at all) in
40013// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
40014// whether the returned error was because http.StatusNotModified was
40015// returned.
40016func (c *ProjectsLocationsAgentSessionsEntityTypesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
40017	gensupport.SetOptions(c.urlParams_, opts...)
40018	res, err := c.doRequest("json")
40019	if res != nil && res.StatusCode == http.StatusNotModified {
40020		if res.Body != nil {
40021			res.Body.Close()
40022		}
40023		return nil, &googleapi.Error{
40024			Code:   res.StatusCode,
40025			Header: res.Header,
40026		}
40027	}
40028	if err != nil {
40029		return nil, err
40030	}
40031	defer googleapi.CloseBody(res)
40032	if err := googleapi.CheckResponse(res); err != nil {
40033		return nil, err
40034	}
40035	ret := &GoogleCloudDialogflowV2SessionEntityType{
40036		ServerResponse: googleapi.ServerResponse{
40037			Header:         res.Header,
40038			HTTPStatusCode: res.StatusCode,
40039		},
40040	}
40041	target := &ret
40042	if err := gensupport.DecodeResponse(target, res); err != nil {
40043		return nil, err
40044	}
40045	return ret, nil
40046	// {
40047	//   "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.",
40048	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/entityTypes",
40049	//   "httpMethod": "POST",
40050	//   "id": "dialogflow.projects.locations.agent.sessions.entityTypes.create",
40051	//   "parameterOrder": [
40052	//     "parent"
40053	//   ],
40054	//   "parameters": {
40055	//     "parent": {
40056	//       "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.",
40057	//       "location": "path",
40058	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+$",
40059	//       "required": true,
40060	//       "type": "string"
40061	//     }
40062	//   },
40063	//   "path": "v2/{+parent}/entityTypes",
40064	//   "request": {
40065	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
40066	//   },
40067	//   "response": {
40068	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
40069	//   },
40070	//   "scopes": [
40071	//     "https://www.googleapis.com/auth/cloud-platform",
40072	//     "https://www.googleapis.com/auth/dialogflow"
40073	//   ]
40074	// }
40075
40076}
40077
40078// method id "dialogflow.projects.locations.agent.sessions.entityTypes.delete":
40079
40080type ProjectsLocationsAgentSessionsEntityTypesDeleteCall struct {
40081	s          *Service
40082	name       string
40083	urlParams_ gensupport.URLParams
40084	ctx_       context.Context
40085	header_    http.Header
40086}
40087
40088// Delete: Deletes the specified session entity type. This method
40089// doesn't work with Google Assistant integration. Contact Dialogflow
40090// support if you need to use session entities with Google Assistant
40091// integration.
40092//
40093// - name: The name of the entity type to delete. Format:
40094//   `projects//agent/sessions//entityTypes/` or
40095//   `projects//agent/environments//users//sessions//entityTypes/`. If
40096//   `Environment ID` is not specified, we assume default 'draft'
40097//   environment. If `User ID` is not specified, we assume default '-'
40098//   user.
40099func (r *ProjectsLocationsAgentSessionsEntityTypesService) Delete(name string) *ProjectsLocationsAgentSessionsEntityTypesDeleteCall {
40100	c := &ProjectsLocationsAgentSessionsEntityTypesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40101	c.name = name
40102	return c
40103}
40104
40105// Fields allows partial responses to be retrieved. See
40106// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40107// for more information.
40108func (c *ProjectsLocationsAgentSessionsEntityTypesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsEntityTypesDeleteCall {
40109	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40110	return c
40111}
40112
40113// Context sets the context to be used in this call's Do method. Any
40114// pending HTTP request will be aborted if the provided context is
40115// canceled.
40116func (c *ProjectsLocationsAgentSessionsEntityTypesDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsEntityTypesDeleteCall {
40117	c.ctx_ = ctx
40118	return c
40119}
40120
40121// Header returns an http.Header that can be modified by the caller to
40122// add HTTP headers to the request.
40123func (c *ProjectsLocationsAgentSessionsEntityTypesDeleteCall) Header() http.Header {
40124	if c.header_ == nil {
40125		c.header_ = make(http.Header)
40126	}
40127	return c.header_
40128}
40129
40130func (c *ProjectsLocationsAgentSessionsEntityTypesDeleteCall) doRequest(alt string) (*http.Response, error) {
40131	reqHeaders := make(http.Header)
40132	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
40133	for k, v := range c.header_ {
40134		reqHeaders[k] = v
40135	}
40136	reqHeaders.Set("User-Agent", c.s.userAgent())
40137	var body io.Reader = nil
40138	c.urlParams_.Set("alt", alt)
40139	c.urlParams_.Set("prettyPrint", "false")
40140	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
40141	urls += "?" + c.urlParams_.Encode()
40142	req, err := http.NewRequest("DELETE", urls, body)
40143	if err != nil {
40144		return nil, err
40145	}
40146	req.Header = reqHeaders
40147	googleapi.Expand(req.URL, map[string]string{
40148		"name": c.name,
40149	})
40150	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40151}
40152
40153// Do executes the "dialogflow.projects.locations.agent.sessions.entityTypes.delete" call.
40154// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
40155// non-2xx status code is an error. Response headers are in either
40156// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
40157// returned at all) in error.(*googleapi.Error).Header. Use
40158// googleapi.IsNotModified to check whether the returned error was
40159// because http.StatusNotModified was returned.
40160func (c *ProjectsLocationsAgentSessionsEntityTypesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
40161	gensupport.SetOptions(c.urlParams_, opts...)
40162	res, err := c.doRequest("json")
40163	if res != nil && res.StatusCode == http.StatusNotModified {
40164		if res.Body != nil {
40165			res.Body.Close()
40166		}
40167		return nil, &googleapi.Error{
40168			Code:   res.StatusCode,
40169			Header: res.Header,
40170		}
40171	}
40172	if err != nil {
40173		return nil, err
40174	}
40175	defer googleapi.CloseBody(res)
40176	if err := googleapi.CheckResponse(res); err != nil {
40177		return nil, err
40178	}
40179	ret := &GoogleProtobufEmpty{
40180		ServerResponse: googleapi.ServerResponse{
40181			Header:         res.Header,
40182			HTTPStatusCode: res.StatusCode,
40183		},
40184	}
40185	target := &ret
40186	if err := gensupport.DecodeResponse(target, res); err != nil {
40187		return nil, err
40188	}
40189	return ret, nil
40190	// {
40191	//   "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.",
40192	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/entityTypes/{entityTypesId}",
40193	//   "httpMethod": "DELETE",
40194	//   "id": "dialogflow.projects.locations.agent.sessions.entityTypes.delete",
40195	//   "parameterOrder": [
40196	//     "name"
40197	//   ],
40198	//   "parameters": {
40199	//     "name": {
40200	//       "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.",
40201	//       "location": "path",
40202	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+/entityTypes/[^/]+$",
40203	//       "required": true,
40204	//       "type": "string"
40205	//     }
40206	//   },
40207	//   "path": "v2/{+name}",
40208	//   "response": {
40209	//     "$ref": "GoogleProtobufEmpty"
40210	//   },
40211	//   "scopes": [
40212	//     "https://www.googleapis.com/auth/cloud-platform",
40213	//     "https://www.googleapis.com/auth/dialogflow"
40214	//   ]
40215	// }
40216
40217}
40218
40219// method id "dialogflow.projects.locations.agent.sessions.entityTypes.get":
40220
40221type ProjectsLocationsAgentSessionsEntityTypesGetCall struct {
40222	s            *Service
40223	name         string
40224	urlParams_   gensupport.URLParams
40225	ifNoneMatch_ string
40226	ctx_         context.Context
40227	header_      http.Header
40228}
40229
40230// Get: Retrieves the specified session entity type. This method doesn't
40231// work with Google Assistant integration. Contact Dialogflow support if
40232// you need to use session entities with Google Assistant integration.
40233//
40234// - name: The name of the session entity type. Format:
40235//   `projects//agent/sessions//entityTypes/` or
40236//   `projects//agent/environments//users//sessions//entityTypes/`. If
40237//   `Environment ID` is not specified, we assume default 'draft'
40238//   environment. If `User ID` is not specified, we assume default '-'
40239//   user.
40240func (r *ProjectsLocationsAgentSessionsEntityTypesService) Get(name string) *ProjectsLocationsAgentSessionsEntityTypesGetCall {
40241	c := &ProjectsLocationsAgentSessionsEntityTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40242	c.name = name
40243	return c
40244}
40245
40246// Fields allows partial responses to be retrieved. See
40247// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40248// for more information.
40249func (c *ProjectsLocationsAgentSessionsEntityTypesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsEntityTypesGetCall {
40250	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40251	return c
40252}
40253
40254// IfNoneMatch sets the optional parameter which makes the operation
40255// fail if the object's ETag matches the given value. This is useful for
40256// getting updates only after the object has changed since the last
40257// request. Use googleapi.IsNotModified to check whether the response
40258// error from Do is the result of In-None-Match.
40259func (c *ProjectsLocationsAgentSessionsEntityTypesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentSessionsEntityTypesGetCall {
40260	c.ifNoneMatch_ = entityTag
40261	return c
40262}
40263
40264// Context sets the context to be used in this call's Do method. Any
40265// pending HTTP request will be aborted if the provided context is
40266// canceled.
40267func (c *ProjectsLocationsAgentSessionsEntityTypesGetCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsEntityTypesGetCall {
40268	c.ctx_ = ctx
40269	return c
40270}
40271
40272// Header returns an http.Header that can be modified by the caller to
40273// add HTTP headers to the request.
40274func (c *ProjectsLocationsAgentSessionsEntityTypesGetCall) Header() http.Header {
40275	if c.header_ == nil {
40276		c.header_ = make(http.Header)
40277	}
40278	return c.header_
40279}
40280
40281func (c *ProjectsLocationsAgentSessionsEntityTypesGetCall) doRequest(alt string) (*http.Response, error) {
40282	reqHeaders := make(http.Header)
40283	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
40284	for k, v := range c.header_ {
40285		reqHeaders[k] = v
40286	}
40287	reqHeaders.Set("User-Agent", c.s.userAgent())
40288	if c.ifNoneMatch_ != "" {
40289		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
40290	}
40291	var body io.Reader = nil
40292	c.urlParams_.Set("alt", alt)
40293	c.urlParams_.Set("prettyPrint", "false")
40294	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
40295	urls += "?" + c.urlParams_.Encode()
40296	req, err := http.NewRequest("GET", urls, body)
40297	if err != nil {
40298		return nil, err
40299	}
40300	req.Header = reqHeaders
40301	googleapi.Expand(req.URL, map[string]string{
40302		"name": c.name,
40303	})
40304	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40305}
40306
40307// Do executes the "dialogflow.projects.locations.agent.sessions.entityTypes.get" call.
40308// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
40309// will be non-nil. Any non-2xx status code is an error. Response
40310// headers are in either
40311// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
40312// (if a response was returned at all) in
40313// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
40314// whether the returned error was because http.StatusNotModified was
40315// returned.
40316func (c *ProjectsLocationsAgentSessionsEntityTypesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
40317	gensupport.SetOptions(c.urlParams_, opts...)
40318	res, err := c.doRequest("json")
40319	if res != nil && res.StatusCode == http.StatusNotModified {
40320		if res.Body != nil {
40321			res.Body.Close()
40322		}
40323		return nil, &googleapi.Error{
40324			Code:   res.StatusCode,
40325			Header: res.Header,
40326		}
40327	}
40328	if err != nil {
40329		return nil, err
40330	}
40331	defer googleapi.CloseBody(res)
40332	if err := googleapi.CheckResponse(res); err != nil {
40333		return nil, err
40334	}
40335	ret := &GoogleCloudDialogflowV2SessionEntityType{
40336		ServerResponse: googleapi.ServerResponse{
40337			Header:         res.Header,
40338			HTTPStatusCode: res.StatusCode,
40339		},
40340	}
40341	target := &ret
40342	if err := gensupport.DecodeResponse(target, res); err != nil {
40343		return nil, err
40344	}
40345	return ret, nil
40346	// {
40347	//   "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.",
40348	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/entityTypes/{entityTypesId}",
40349	//   "httpMethod": "GET",
40350	//   "id": "dialogflow.projects.locations.agent.sessions.entityTypes.get",
40351	//   "parameterOrder": [
40352	//     "name"
40353	//   ],
40354	//   "parameters": {
40355	//     "name": {
40356	//       "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.",
40357	//       "location": "path",
40358	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+/entityTypes/[^/]+$",
40359	//       "required": true,
40360	//       "type": "string"
40361	//     }
40362	//   },
40363	//   "path": "v2/{+name}",
40364	//   "response": {
40365	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
40366	//   },
40367	//   "scopes": [
40368	//     "https://www.googleapis.com/auth/cloud-platform",
40369	//     "https://www.googleapis.com/auth/dialogflow"
40370	//   ]
40371	// }
40372
40373}
40374
40375// method id "dialogflow.projects.locations.agent.sessions.entityTypes.list":
40376
40377type ProjectsLocationsAgentSessionsEntityTypesListCall struct {
40378	s            *Service
40379	parent       string
40380	urlParams_   gensupport.URLParams
40381	ifNoneMatch_ string
40382	ctx_         context.Context
40383	header_      http.Header
40384}
40385
40386// List: Returns the list of all session entity types in the specified
40387// session. This method doesn't work with Google Assistant integration.
40388// Contact Dialogflow support if you need to use session entities with
40389// Google Assistant integration.
40390//
40391// - parent: The session to list all session entity types from. Format:
40392//   `projects//agent/sessions/` or
40393//   `projects//agent/environments//users// sessions/`. If `Environment
40394//   ID` is not specified, we assume default 'draft' environment. If
40395//   `User ID` is not specified, we assume default '-' user.
40396func (r *ProjectsLocationsAgentSessionsEntityTypesService) List(parent string) *ProjectsLocationsAgentSessionsEntityTypesListCall {
40397	c := &ProjectsLocationsAgentSessionsEntityTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40398	c.parent = parent
40399	return c
40400}
40401
40402// PageSize sets the optional parameter "pageSize": The maximum number
40403// of items to return in a single page. By default 100 and at most 1000.
40404func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) PageSize(pageSize int64) *ProjectsLocationsAgentSessionsEntityTypesListCall {
40405	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
40406	return c
40407}
40408
40409// PageToken sets the optional parameter "pageToken": The
40410// next_page_token value returned from a previous list request.
40411func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) PageToken(pageToken string) *ProjectsLocationsAgentSessionsEntityTypesListCall {
40412	c.urlParams_.Set("pageToken", pageToken)
40413	return c
40414}
40415
40416// Fields allows partial responses to be retrieved. See
40417// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40418// for more information.
40419func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsEntityTypesListCall {
40420	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40421	return c
40422}
40423
40424// IfNoneMatch sets the optional parameter which makes the operation
40425// fail if the object's ETag matches the given value. This is useful for
40426// getting updates only after the object has changed since the last
40427// request. Use googleapi.IsNotModified to check whether the response
40428// error from Do is the result of In-None-Match.
40429func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentSessionsEntityTypesListCall {
40430	c.ifNoneMatch_ = entityTag
40431	return c
40432}
40433
40434// Context sets the context to be used in this call's Do method. Any
40435// pending HTTP request will be aborted if the provided context is
40436// canceled.
40437func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsEntityTypesListCall {
40438	c.ctx_ = ctx
40439	return c
40440}
40441
40442// Header returns an http.Header that can be modified by the caller to
40443// add HTTP headers to the request.
40444func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) Header() http.Header {
40445	if c.header_ == nil {
40446		c.header_ = make(http.Header)
40447	}
40448	return c.header_
40449}
40450
40451func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) doRequest(alt string) (*http.Response, error) {
40452	reqHeaders := make(http.Header)
40453	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
40454	for k, v := range c.header_ {
40455		reqHeaders[k] = v
40456	}
40457	reqHeaders.Set("User-Agent", c.s.userAgent())
40458	if c.ifNoneMatch_ != "" {
40459		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
40460	}
40461	var body io.Reader = nil
40462	c.urlParams_.Set("alt", alt)
40463	c.urlParams_.Set("prettyPrint", "false")
40464	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
40465	urls += "?" + c.urlParams_.Encode()
40466	req, err := http.NewRequest("GET", urls, body)
40467	if err != nil {
40468		return nil, err
40469	}
40470	req.Header = reqHeaders
40471	googleapi.Expand(req.URL, map[string]string{
40472		"parent": c.parent,
40473	})
40474	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40475}
40476
40477// Do executes the "dialogflow.projects.locations.agent.sessions.entityTypes.list" call.
40478// Exactly one of *GoogleCloudDialogflowV2ListSessionEntityTypesResponse
40479// or error will be non-nil. Any non-2xx status code is an error.
40480// Response headers are in either
40481// *GoogleCloudDialogflowV2ListSessionEntityTypesResponse.ServerResponse.
40482// Header or (if a response was returned at all) in
40483// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
40484// whether the returned error was because http.StatusNotModified was
40485// returned.
40486func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListSessionEntityTypesResponse, error) {
40487	gensupport.SetOptions(c.urlParams_, opts...)
40488	res, err := c.doRequest("json")
40489	if res != nil && res.StatusCode == http.StatusNotModified {
40490		if res.Body != nil {
40491			res.Body.Close()
40492		}
40493		return nil, &googleapi.Error{
40494			Code:   res.StatusCode,
40495			Header: res.Header,
40496		}
40497	}
40498	if err != nil {
40499		return nil, err
40500	}
40501	defer googleapi.CloseBody(res)
40502	if err := googleapi.CheckResponse(res); err != nil {
40503		return nil, err
40504	}
40505	ret := &GoogleCloudDialogflowV2ListSessionEntityTypesResponse{
40506		ServerResponse: googleapi.ServerResponse{
40507			Header:         res.Header,
40508			HTTPStatusCode: res.StatusCode,
40509		},
40510	}
40511	target := &ret
40512	if err := gensupport.DecodeResponse(target, res); err != nil {
40513		return nil, err
40514	}
40515	return ret, nil
40516	// {
40517	//   "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.",
40518	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/entityTypes",
40519	//   "httpMethod": "GET",
40520	//   "id": "dialogflow.projects.locations.agent.sessions.entityTypes.list",
40521	//   "parameterOrder": [
40522	//     "parent"
40523	//   ],
40524	//   "parameters": {
40525	//     "pageSize": {
40526	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
40527	//       "format": "int32",
40528	//       "location": "query",
40529	//       "type": "integer"
40530	//     },
40531	//     "pageToken": {
40532	//       "description": "Optional. The next_page_token value returned from a previous list request.",
40533	//       "location": "query",
40534	//       "type": "string"
40535	//     },
40536	//     "parent": {
40537	//       "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.",
40538	//       "location": "path",
40539	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+$",
40540	//       "required": true,
40541	//       "type": "string"
40542	//     }
40543	//   },
40544	//   "path": "v2/{+parent}/entityTypes",
40545	//   "response": {
40546	//     "$ref": "GoogleCloudDialogflowV2ListSessionEntityTypesResponse"
40547	//   },
40548	//   "scopes": [
40549	//     "https://www.googleapis.com/auth/cloud-platform",
40550	//     "https://www.googleapis.com/auth/dialogflow"
40551	//   ]
40552	// }
40553
40554}
40555
40556// Pages invokes f for each page of results.
40557// A non-nil error returned from f will halt the iteration.
40558// The provided context supersedes any context provided to the Context method.
40559func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListSessionEntityTypesResponse) error) error {
40560	c.ctx_ = ctx
40561	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
40562	for {
40563		x, err := c.Do()
40564		if err != nil {
40565			return err
40566		}
40567		if err := f(x); err != nil {
40568			return err
40569		}
40570		if x.NextPageToken == "" {
40571			return nil
40572		}
40573		c.PageToken(x.NextPageToken)
40574	}
40575}
40576
40577// method id "dialogflow.projects.locations.agent.sessions.entityTypes.patch":
40578
40579type ProjectsLocationsAgentSessionsEntityTypesPatchCall struct {
40580	s                                        *Service
40581	nameid                                   string
40582	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
40583	urlParams_                               gensupport.URLParams
40584	ctx_                                     context.Context
40585	header_                                  http.Header
40586}
40587
40588// Patch: Updates the specified session entity type. This method doesn't
40589// work with Google Assistant integration. Contact Dialogflow support if
40590// you need to use session entities with Google Assistant integration.
40591//
40592// - name: The unique identifier of this session entity type. Format:
40593//   `projects//agent/sessions//entityTypes/`, or
40594//   `projects//agent/environments//users//sessions//entityTypes/`. If
40595//   `Environment ID` is not specified, we assume default 'draft'
40596//   environment. If `User ID` is not specified, we assume default '-'
40597//   user. `` must be the display name of an existing entity type in the
40598//   same agent that will be overridden or supplemented.
40599func (r *ProjectsLocationsAgentSessionsEntityTypesService) Patch(nameid string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsLocationsAgentSessionsEntityTypesPatchCall {
40600	c := &ProjectsLocationsAgentSessionsEntityTypesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40601	c.nameid = nameid
40602	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
40603	return c
40604}
40605
40606// UpdateMask sets the optional parameter "updateMask": The mask to
40607// control which fields get updated.
40608func (c *ProjectsLocationsAgentSessionsEntityTypesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentSessionsEntityTypesPatchCall {
40609	c.urlParams_.Set("updateMask", updateMask)
40610	return c
40611}
40612
40613// Fields allows partial responses to be retrieved. See
40614// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40615// for more information.
40616func (c *ProjectsLocationsAgentSessionsEntityTypesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsEntityTypesPatchCall {
40617	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40618	return c
40619}
40620
40621// Context sets the context to be used in this call's Do method. Any
40622// pending HTTP request will be aborted if the provided context is
40623// canceled.
40624func (c *ProjectsLocationsAgentSessionsEntityTypesPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsEntityTypesPatchCall {
40625	c.ctx_ = ctx
40626	return c
40627}
40628
40629// Header returns an http.Header that can be modified by the caller to
40630// add HTTP headers to the request.
40631func (c *ProjectsLocationsAgentSessionsEntityTypesPatchCall) Header() http.Header {
40632	if c.header_ == nil {
40633		c.header_ = make(http.Header)
40634	}
40635	return c.header_
40636}
40637
40638func (c *ProjectsLocationsAgentSessionsEntityTypesPatchCall) doRequest(alt string) (*http.Response, error) {
40639	reqHeaders := make(http.Header)
40640	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
40641	for k, v := range c.header_ {
40642		reqHeaders[k] = v
40643	}
40644	reqHeaders.Set("User-Agent", c.s.userAgent())
40645	var body io.Reader = nil
40646	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
40647	if err != nil {
40648		return nil, err
40649	}
40650	reqHeaders.Set("Content-Type", "application/json")
40651	c.urlParams_.Set("alt", alt)
40652	c.urlParams_.Set("prettyPrint", "false")
40653	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
40654	urls += "?" + c.urlParams_.Encode()
40655	req, err := http.NewRequest("PATCH", urls, body)
40656	if err != nil {
40657		return nil, err
40658	}
40659	req.Header = reqHeaders
40660	googleapi.Expand(req.URL, map[string]string{
40661		"name": c.nameid,
40662	})
40663	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40664}
40665
40666// Do executes the "dialogflow.projects.locations.agent.sessions.entityTypes.patch" call.
40667// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
40668// will be non-nil. Any non-2xx status code is an error. Response
40669// headers are in either
40670// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
40671// (if a response was returned at all) in
40672// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
40673// whether the returned error was because http.StatusNotModified was
40674// returned.
40675func (c *ProjectsLocationsAgentSessionsEntityTypesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
40676	gensupport.SetOptions(c.urlParams_, opts...)
40677	res, err := c.doRequest("json")
40678	if res != nil && res.StatusCode == http.StatusNotModified {
40679		if res.Body != nil {
40680			res.Body.Close()
40681		}
40682		return nil, &googleapi.Error{
40683			Code:   res.StatusCode,
40684			Header: res.Header,
40685		}
40686	}
40687	if err != nil {
40688		return nil, err
40689	}
40690	defer googleapi.CloseBody(res)
40691	if err := googleapi.CheckResponse(res); err != nil {
40692		return nil, err
40693	}
40694	ret := &GoogleCloudDialogflowV2SessionEntityType{
40695		ServerResponse: googleapi.ServerResponse{
40696			Header:         res.Header,
40697			HTTPStatusCode: res.StatusCode,
40698		},
40699	}
40700	target := &ret
40701	if err := gensupport.DecodeResponse(target, res); err != nil {
40702		return nil, err
40703	}
40704	return ret, nil
40705	// {
40706	//   "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.",
40707	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/entityTypes/{entityTypesId}",
40708	//   "httpMethod": "PATCH",
40709	//   "id": "dialogflow.projects.locations.agent.sessions.entityTypes.patch",
40710	//   "parameterOrder": [
40711	//     "name"
40712	//   ],
40713	//   "parameters": {
40714	//     "name": {
40715	//       "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.",
40716	//       "location": "path",
40717	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+/entityTypes/[^/]+$",
40718	//       "required": true,
40719	//       "type": "string"
40720	//     },
40721	//     "updateMask": {
40722	//       "description": "Optional. The mask to control which fields get updated.",
40723	//       "format": "google-fieldmask",
40724	//       "location": "query",
40725	//       "type": "string"
40726	//     }
40727	//   },
40728	//   "path": "v2/{+name}",
40729	//   "request": {
40730	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
40731	//   },
40732	//   "response": {
40733	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
40734	//   },
40735	//   "scopes": [
40736	//     "https://www.googleapis.com/auth/cloud-platform",
40737	//     "https://www.googleapis.com/auth/dialogflow"
40738	//   ]
40739	// }
40740
40741}
40742
40743// method id "dialogflow.projects.locations.answerRecords.list":
40744
40745type ProjectsLocationsAnswerRecordsListCall struct {
40746	s            *Service
40747	parent       string
40748	urlParams_   gensupport.URLParams
40749	ifNoneMatch_ string
40750	ctx_         context.Context
40751	header_      http.Header
40752}
40753
40754// List: Returns the list of all answer records in the specified project
40755// in reverse chronological order.
40756//
40757// - parent: The project to list all answer records for in reverse
40758//   chronological order. Format: `projects//locations/`.
40759func (r *ProjectsLocationsAnswerRecordsService) List(parent string) *ProjectsLocationsAnswerRecordsListCall {
40760	c := &ProjectsLocationsAnswerRecordsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40761	c.parent = parent
40762	return c
40763}
40764
40765// Filter sets the optional parameter "filter": Required. Filters to
40766// restrict results to specific answer records. Filter on answer record
40767// type. Currently predicates on `type` is supported, valid values are
40768// `ARTICLE_ANSWER`, `FAQ_ANSWER`. For more information about filtering,
40769// see API Filtering (https://aip.dev/160).
40770func (c *ProjectsLocationsAnswerRecordsListCall) Filter(filter string) *ProjectsLocationsAnswerRecordsListCall {
40771	c.urlParams_.Set("filter", filter)
40772	return c
40773}
40774
40775// PageSize sets the optional parameter "pageSize": The maximum number
40776// of records to return in a single page. The server may return fewer
40777// records than this. If unspecified, we use 10. The maximum is 100.
40778func (c *ProjectsLocationsAnswerRecordsListCall) PageSize(pageSize int64) *ProjectsLocationsAnswerRecordsListCall {
40779	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
40780	return c
40781}
40782
40783// PageToken sets the optional parameter "pageToken": The
40784// ListAnswerRecordsResponse.next_page_token value returned from a
40785// previous list request used to continue listing on the next page.
40786func (c *ProjectsLocationsAnswerRecordsListCall) PageToken(pageToken string) *ProjectsLocationsAnswerRecordsListCall {
40787	c.urlParams_.Set("pageToken", pageToken)
40788	return c
40789}
40790
40791// Fields allows partial responses to be retrieved. See
40792// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40793// for more information.
40794func (c *ProjectsLocationsAnswerRecordsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAnswerRecordsListCall {
40795	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40796	return c
40797}
40798
40799// IfNoneMatch sets the optional parameter which makes the operation
40800// fail if the object's ETag matches the given value. This is useful for
40801// getting updates only after the object has changed since the last
40802// request. Use googleapi.IsNotModified to check whether the response
40803// error from Do is the result of In-None-Match.
40804func (c *ProjectsLocationsAnswerRecordsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAnswerRecordsListCall {
40805	c.ifNoneMatch_ = entityTag
40806	return c
40807}
40808
40809// Context sets the context to be used in this call's Do method. Any
40810// pending HTTP request will be aborted if the provided context is
40811// canceled.
40812func (c *ProjectsLocationsAnswerRecordsListCall) Context(ctx context.Context) *ProjectsLocationsAnswerRecordsListCall {
40813	c.ctx_ = ctx
40814	return c
40815}
40816
40817// Header returns an http.Header that can be modified by the caller to
40818// add HTTP headers to the request.
40819func (c *ProjectsLocationsAnswerRecordsListCall) Header() http.Header {
40820	if c.header_ == nil {
40821		c.header_ = make(http.Header)
40822	}
40823	return c.header_
40824}
40825
40826func (c *ProjectsLocationsAnswerRecordsListCall) doRequest(alt string) (*http.Response, error) {
40827	reqHeaders := make(http.Header)
40828	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
40829	for k, v := range c.header_ {
40830		reqHeaders[k] = v
40831	}
40832	reqHeaders.Set("User-Agent", c.s.userAgent())
40833	if c.ifNoneMatch_ != "" {
40834		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
40835	}
40836	var body io.Reader = nil
40837	c.urlParams_.Set("alt", alt)
40838	c.urlParams_.Set("prettyPrint", "false")
40839	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/answerRecords")
40840	urls += "?" + c.urlParams_.Encode()
40841	req, err := http.NewRequest("GET", urls, body)
40842	if err != nil {
40843		return nil, err
40844	}
40845	req.Header = reqHeaders
40846	googleapi.Expand(req.URL, map[string]string{
40847		"parent": c.parent,
40848	})
40849	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40850}
40851
40852// Do executes the "dialogflow.projects.locations.answerRecords.list" call.
40853// Exactly one of *GoogleCloudDialogflowV2ListAnswerRecordsResponse or
40854// error will be non-nil. Any non-2xx status code is an error. Response
40855// headers are in either
40856// *GoogleCloudDialogflowV2ListAnswerRecordsResponse.ServerResponse.Heade
40857// r or (if a response was returned at all) in
40858// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
40859// whether the returned error was because http.StatusNotModified was
40860// returned.
40861func (c *ProjectsLocationsAnswerRecordsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListAnswerRecordsResponse, error) {
40862	gensupport.SetOptions(c.urlParams_, opts...)
40863	res, err := c.doRequest("json")
40864	if res != nil && res.StatusCode == http.StatusNotModified {
40865		if res.Body != nil {
40866			res.Body.Close()
40867		}
40868		return nil, &googleapi.Error{
40869			Code:   res.StatusCode,
40870			Header: res.Header,
40871		}
40872	}
40873	if err != nil {
40874		return nil, err
40875	}
40876	defer googleapi.CloseBody(res)
40877	if err := googleapi.CheckResponse(res); err != nil {
40878		return nil, err
40879	}
40880	ret := &GoogleCloudDialogflowV2ListAnswerRecordsResponse{
40881		ServerResponse: googleapi.ServerResponse{
40882			Header:         res.Header,
40883			HTTPStatusCode: res.StatusCode,
40884		},
40885	}
40886	target := &ret
40887	if err := gensupport.DecodeResponse(target, res); err != nil {
40888		return nil, err
40889	}
40890	return ret, nil
40891	// {
40892	//   "description": "Returns the list of all answer records in the specified project in reverse chronological order.",
40893	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/answerRecords",
40894	//   "httpMethod": "GET",
40895	//   "id": "dialogflow.projects.locations.answerRecords.list",
40896	//   "parameterOrder": [
40897	//     "parent"
40898	//   ],
40899	//   "parameters": {
40900	//     "filter": {
40901	//       "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).",
40902	//       "location": "query",
40903	//       "type": "string"
40904	//     },
40905	//     "pageSize": {
40906	//       "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.",
40907	//       "format": "int32",
40908	//       "location": "query",
40909	//       "type": "integer"
40910	//     },
40911	//     "pageToken": {
40912	//       "description": "Optional. The ListAnswerRecordsResponse.next_page_token value returned from a previous list request used to continue listing on the next page.",
40913	//       "location": "query",
40914	//       "type": "string"
40915	//     },
40916	//     "parent": {
40917	//       "description": "Required. The project to list all answer records for in reverse chronological order. Format: `projects//locations/`.",
40918	//       "location": "path",
40919	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
40920	//       "required": true,
40921	//       "type": "string"
40922	//     }
40923	//   },
40924	//   "path": "v2/{+parent}/answerRecords",
40925	//   "response": {
40926	//     "$ref": "GoogleCloudDialogflowV2ListAnswerRecordsResponse"
40927	//   },
40928	//   "scopes": [
40929	//     "https://www.googleapis.com/auth/cloud-platform",
40930	//     "https://www.googleapis.com/auth/dialogflow"
40931	//   ]
40932	// }
40933
40934}
40935
40936// Pages invokes f for each page of results.
40937// A non-nil error returned from f will halt the iteration.
40938// The provided context supersedes any context provided to the Context method.
40939func (c *ProjectsLocationsAnswerRecordsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListAnswerRecordsResponse) error) error {
40940	c.ctx_ = ctx
40941	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
40942	for {
40943		x, err := c.Do()
40944		if err != nil {
40945			return err
40946		}
40947		if err := f(x); err != nil {
40948			return err
40949		}
40950		if x.NextPageToken == "" {
40951			return nil
40952		}
40953		c.PageToken(x.NextPageToken)
40954	}
40955}
40956
40957// method id "dialogflow.projects.locations.answerRecords.patch":
40958
40959type ProjectsLocationsAnswerRecordsPatchCall struct {
40960	s                                   *Service
40961	nameid                              string
40962	googleclouddialogflowv2answerrecord *GoogleCloudDialogflowV2AnswerRecord
40963	urlParams_                          gensupport.URLParams
40964	ctx_                                context.Context
40965	header_                             http.Header
40966}
40967
40968// Patch: Updates the specified answer record.
40969//
40970// - name: The unique identifier of this answer record. Format:
40971//   `projects//locations//answerRecords/`.
40972func (r *ProjectsLocationsAnswerRecordsService) Patch(nameid string, googleclouddialogflowv2answerrecord *GoogleCloudDialogflowV2AnswerRecord) *ProjectsLocationsAnswerRecordsPatchCall {
40973	c := &ProjectsLocationsAnswerRecordsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40974	c.nameid = nameid
40975	c.googleclouddialogflowv2answerrecord = googleclouddialogflowv2answerrecord
40976	return c
40977}
40978
40979// UpdateMask sets the optional parameter "updateMask": Required. The
40980// mask to control which fields get updated.
40981func (c *ProjectsLocationsAnswerRecordsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAnswerRecordsPatchCall {
40982	c.urlParams_.Set("updateMask", updateMask)
40983	return c
40984}
40985
40986// Fields allows partial responses to be retrieved. See
40987// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40988// for more information.
40989func (c *ProjectsLocationsAnswerRecordsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAnswerRecordsPatchCall {
40990	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40991	return c
40992}
40993
40994// Context sets the context to be used in this call's Do method. Any
40995// pending HTTP request will be aborted if the provided context is
40996// canceled.
40997func (c *ProjectsLocationsAnswerRecordsPatchCall) Context(ctx context.Context) *ProjectsLocationsAnswerRecordsPatchCall {
40998	c.ctx_ = ctx
40999	return c
41000}
41001
41002// Header returns an http.Header that can be modified by the caller to
41003// add HTTP headers to the request.
41004func (c *ProjectsLocationsAnswerRecordsPatchCall) Header() http.Header {
41005	if c.header_ == nil {
41006		c.header_ = make(http.Header)
41007	}
41008	return c.header_
41009}
41010
41011func (c *ProjectsLocationsAnswerRecordsPatchCall) doRequest(alt string) (*http.Response, error) {
41012	reqHeaders := make(http.Header)
41013	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
41014	for k, v := range c.header_ {
41015		reqHeaders[k] = v
41016	}
41017	reqHeaders.Set("User-Agent", c.s.userAgent())
41018	var body io.Reader = nil
41019	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2answerrecord)
41020	if err != nil {
41021		return nil, err
41022	}
41023	reqHeaders.Set("Content-Type", "application/json")
41024	c.urlParams_.Set("alt", alt)
41025	c.urlParams_.Set("prettyPrint", "false")
41026	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
41027	urls += "?" + c.urlParams_.Encode()
41028	req, err := http.NewRequest("PATCH", urls, body)
41029	if err != nil {
41030		return nil, err
41031	}
41032	req.Header = reqHeaders
41033	googleapi.Expand(req.URL, map[string]string{
41034		"name": c.nameid,
41035	})
41036	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41037}
41038
41039// Do executes the "dialogflow.projects.locations.answerRecords.patch" call.
41040// Exactly one of *GoogleCloudDialogflowV2AnswerRecord or error will be
41041// non-nil. Any non-2xx status code is an error. Response headers are in
41042// either *GoogleCloudDialogflowV2AnswerRecord.ServerResponse.Header or
41043// (if a response was returned at all) in
41044// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
41045// whether the returned error was because http.StatusNotModified was
41046// returned.
41047func (c *ProjectsLocationsAnswerRecordsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2AnswerRecord, error) {
41048	gensupport.SetOptions(c.urlParams_, opts...)
41049	res, err := c.doRequest("json")
41050	if res != nil && res.StatusCode == http.StatusNotModified {
41051		if res.Body != nil {
41052			res.Body.Close()
41053		}
41054		return nil, &googleapi.Error{
41055			Code:   res.StatusCode,
41056			Header: res.Header,
41057		}
41058	}
41059	if err != nil {
41060		return nil, err
41061	}
41062	defer googleapi.CloseBody(res)
41063	if err := googleapi.CheckResponse(res); err != nil {
41064		return nil, err
41065	}
41066	ret := &GoogleCloudDialogflowV2AnswerRecord{
41067		ServerResponse: googleapi.ServerResponse{
41068			Header:         res.Header,
41069			HTTPStatusCode: res.StatusCode,
41070		},
41071	}
41072	target := &ret
41073	if err := gensupport.DecodeResponse(target, res); err != nil {
41074		return nil, err
41075	}
41076	return ret, nil
41077	// {
41078	//   "description": "Updates the specified answer record.",
41079	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/answerRecords/{answerRecordsId}",
41080	//   "httpMethod": "PATCH",
41081	//   "id": "dialogflow.projects.locations.answerRecords.patch",
41082	//   "parameterOrder": [
41083	//     "name"
41084	//   ],
41085	//   "parameters": {
41086	//     "name": {
41087	//       "description": "The unique identifier of this answer record. Format: `projects//locations//answerRecords/`.",
41088	//       "location": "path",
41089	//       "pattern": "^projects/[^/]+/locations/[^/]+/answerRecords/[^/]+$",
41090	//       "required": true,
41091	//       "type": "string"
41092	//     },
41093	//     "updateMask": {
41094	//       "description": "Required. The mask to control which fields get updated.",
41095	//       "format": "google-fieldmask",
41096	//       "location": "query",
41097	//       "type": "string"
41098	//     }
41099	//   },
41100	//   "path": "v2/{+name}",
41101	//   "request": {
41102	//     "$ref": "GoogleCloudDialogflowV2AnswerRecord"
41103	//   },
41104	//   "response": {
41105	//     "$ref": "GoogleCloudDialogflowV2AnswerRecord"
41106	//   },
41107	//   "scopes": [
41108	//     "https://www.googleapis.com/auth/cloud-platform",
41109	//     "https://www.googleapis.com/auth/dialogflow"
41110	//   ]
41111	// }
41112
41113}
41114
41115// method id "dialogflow.projects.locations.conversationProfiles.create":
41116
41117type ProjectsLocationsConversationProfilesCreateCall struct {
41118	s                                          *Service
41119	parent                                     string
41120	googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile
41121	urlParams_                                 gensupport.URLParams
41122	ctx_                                       context.Context
41123	header_                                    http.Header
41124}
41125
41126// Create: Creates a conversation profile in the specified project.
41127// ConversationProfile.CreateTime and ConversationProfile.UpdateTime
41128// aren't populated in the response. You can retrieve them via
41129// GetConversationProfile API.
41130//
41131// - parent: The project to create a conversation profile for. Format:
41132//   `projects//locations/`.
41133func (r *ProjectsLocationsConversationProfilesService) Create(parent string, googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile) *ProjectsLocationsConversationProfilesCreateCall {
41134	c := &ProjectsLocationsConversationProfilesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41135	c.parent = parent
41136	c.googleclouddialogflowv2conversationprofile = googleclouddialogflowv2conversationprofile
41137	return c
41138}
41139
41140// Fields allows partial responses to be retrieved. See
41141// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41142// for more information.
41143func (c *ProjectsLocationsConversationProfilesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationProfilesCreateCall {
41144	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41145	return c
41146}
41147
41148// Context sets the context to be used in this call's Do method. Any
41149// pending HTTP request will be aborted if the provided context is
41150// canceled.
41151func (c *ProjectsLocationsConversationProfilesCreateCall) Context(ctx context.Context) *ProjectsLocationsConversationProfilesCreateCall {
41152	c.ctx_ = ctx
41153	return c
41154}
41155
41156// Header returns an http.Header that can be modified by the caller to
41157// add HTTP headers to the request.
41158func (c *ProjectsLocationsConversationProfilesCreateCall) Header() http.Header {
41159	if c.header_ == nil {
41160		c.header_ = make(http.Header)
41161	}
41162	return c.header_
41163}
41164
41165func (c *ProjectsLocationsConversationProfilesCreateCall) doRequest(alt string) (*http.Response, error) {
41166	reqHeaders := make(http.Header)
41167	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
41168	for k, v := range c.header_ {
41169		reqHeaders[k] = v
41170	}
41171	reqHeaders.Set("User-Agent", c.s.userAgent())
41172	var body io.Reader = nil
41173	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2conversationprofile)
41174	if err != nil {
41175		return nil, err
41176	}
41177	reqHeaders.Set("Content-Type", "application/json")
41178	c.urlParams_.Set("alt", alt)
41179	c.urlParams_.Set("prettyPrint", "false")
41180	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversationProfiles")
41181	urls += "?" + c.urlParams_.Encode()
41182	req, err := http.NewRequest("POST", urls, body)
41183	if err != nil {
41184		return nil, err
41185	}
41186	req.Header = reqHeaders
41187	googleapi.Expand(req.URL, map[string]string{
41188		"parent": c.parent,
41189	})
41190	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41191}
41192
41193// Do executes the "dialogflow.projects.locations.conversationProfiles.create" call.
41194// Exactly one of *GoogleCloudDialogflowV2ConversationProfile or error
41195// will be non-nil. Any non-2xx status code is an error. Response
41196// headers are in either
41197// *GoogleCloudDialogflowV2ConversationProfile.ServerResponse.Header or
41198// (if a response was returned at all) in
41199// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
41200// whether the returned error was because http.StatusNotModified was
41201// returned.
41202func (c *ProjectsLocationsConversationProfilesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ConversationProfile, error) {
41203	gensupport.SetOptions(c.urlParams_, opts...)
41204	res, err := c.doRequest("json")
41205	if res != nil && res.StatusCode == http.StatusNotModified {
41206		if res.Body != nil {
41207			res.Body.Close()
41208		}
41209		return nil, &googleapi.Error{
41210			Code:   res.StatusCode,
41211			Header: res.Header,
41212		}
41213	}
41214	if err != nil {
41215		return nil, err
41216	}
41217	defer googleapi.CloseBody(res)
41218	if err := googleapi.CheckResponse(res); err != nil {
41219		return nil, err
41220	}
41221	ret := &GoogleCloudDialogflowV2ConversationProfile{
41222		ServerResponse: googleapi.ServerResponse{
41223			Header:         res.Header,
41224			HTTPStatusCode: res.StatusCode,
41225		},
41226	}
41227	target := &ret
41228	if err := gensupport.DecodeResponse(target, res); err != nil {
41229		return nil, err
41230	}
41231	return ret, nil
41232	// {
41233	//   "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.",
41234	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversationProfiles",
41235	//   "httpMethod": "POST",
41236	//   "id": "dialogflow.projects.locations.conversationProfiles.create",
41237	//   "parameterOrder": [
41238	//     "parent"
41239	//   ],
41240	//   "parameters": {
41241	//     "parent": {
41242	//       "description": "Required. The project to create a conversation profile for. Format: `projects//locations/`.",
41243	//       "location": "path",
41244	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
41245	//       "required": true,
41246	//       "type": "string"
41247	//     }
41248	//   },
41249	//   "path": "v2/{+parent}/conversationProfiles",
41250	//   "request": {
41251	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
41252	//   },
41253	//   "response": {
41254	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
41255	//   },
41256	//   "scopes": [
41257	//     "https://www.googleapis.com/auth/cloud-platform",
41258	//     "https://www.googleapis.com/auth/dialogflow"
41259	//   ]
41260	// }
41261
41262}
41263
41264// method id "dialogflow.projects.locations.conversationProfiles.delete":
41265
41266type ProjectsLocationsConversationProfilesDeleteCall struct {
41267	s          *Service
41268	name       string
41269	urlParams_ gensupport.URLParams
41270	ctx_       context.Context
41271	header_    http.Header
41272}
41273
41274// Delete: Deletes the specified conversation profile.
41275//
41276// - name: The name of the conversation profile to delete. Format:
41277//   `projects//locations//conversationProfiles/`.
41278func (r *ProjectsLocationsConversationProfilesService) Delete(name string) *ProjectsLocationsConversationProfilesDeleteCall {
41279	c := &ProjectsLocationsConversationProfilesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41280	c.name = name
41281	return c
41282}
41283
41284// Fields allows partial responses to be retrieved. See
41285// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41286// for more information.
41287func (c *ProjectsLocationsConversationProfilesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationProfilesDeleteCall {
41288	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41289	return c
41290}
41291
41292// Context sets the context to be used in this call's Do method. Any
41293// pending HTTP request will be aborted if the provided context is
41294// canceled.
41295func (c *ProjectsLocationsConversationProfilesDeleteCall) Context(ctx context.Context) *ProjectsLocationsConversationProfilesDeleteCall {
41296	c.ctx_ = ctx
41297	return c
41298}
41299
41300// Header returns an http.Header that can be modified by the caller to
41301// add HTTP headers to the request.
41302func (c *ProjectsLocationsConversationProfilesDeleteCall) Header() http.Header {
41303	if c.header_ == nil {
41304		c.header_ = make(http.Header)
41305	}
41306	return c.header_
41307}
41308
41309func (c *ProjectsLocationsConversationProfilesDeleteCall) doRequest(alt string) (*http.Response, error) {
41310	reqHeaders := make(http.Header)
41311	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
41312	for k, v := range c.header_ {
41313		reqHeaders[k] = v
41314	}
41315	reqHeaders.Set("User-Agent", c.s.userAgent())
41316	var body io.Reader = nil
41317	c.urlParams_.Set("alt", alt)
41318	c.urlParams_.Set("prettyPrint", "false")
41319	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
41320	urls += "?" + c.urlParams_.Encode()
41321	req, err := http.NewRequest("DELETE", urls, body)
41322	if err != nil {
41323		return nil, err
41324	}
41325	req.Header = reqHeaders
41326	googleapi.Expand(req.URL, map[string]string{
41327		"name": c.name,
41328	})
41329	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41330}
41331
41332// Do executes the "dialogflow.projects.locations.conversationProfiles.delete" call.
41333// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
41334// non-2xx status code is an error. Response headers are in either
41335// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
41336// returned at all) in error.(*googleapi.Error).Header. Use
41337// googleapi.IsNotModified to check whether the returned error was
41338// because http.StatusNotModified was returned.
41339func (c *ProjectsLocationsConversationProfilesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
41340	gensupport.SetOptions(c.urlParams_, opts...)
41341	res, err := c.doRequest("json")
41342	if res != nil && res.StatusCode == http.StatusNotModified {
41343		if res.Body != nil {
41344			res.Body.Close()
41345		}
41346		return nil, &googleapi.Error{
41347			Code:   res.StatusCode,
41348			Header: res.Header,
41349		}
41350	}
41351	if err != nil {
41352		return nil, err
41353	}
41354	defer googleapi.CloseBody(res)
41355	if err := googleapi.CheckResponse(res); err != nil {
41356		return nil, err
41357	}
41358	ret := &GoogleProtobufEmpty{
41359		ServerResponse: googleapi.ServerResponse{
41360			Header:         res.Header,
41361			HTTPStatusCode: res.StatusCode,
41362		},
41363	}
41364	target := &ret
41365	if err := gensupport.DecodeResponse(target, res); err != nil {
41366		return nil, err
41367	}
41368	return ret, nil
41369	// {
41370	//   "description": "Deletes the specified conversation profile.",
41371	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversationProfiles/{conversationProfilesId}",
41372	//   "httpMethod": "DELETE",
41373	//   "id": "dialogflow.projects.locations.conversationProfiles.delete",
41374	//   "parameterOrder": [
41375	//     "name"
41376	//   ],
41377	//   "parameters": {
41378	//     "name": {
41379	//       "description": "Required. The name of the conversation profile to delete. Format: `projects//locations//conversationProfiles/`.",
41380	//       "location": "path",
41381	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversationProfiles/[^/]+$",
41382	//       "required": true,
41383	//       "type": "string"
41384	//     }
41385	//   },
41386	//   "path": "v2/{+name}",
41387	//   "response": {
41388	//     "$ref": "GoogleProtobufEmpty"
41389	//   },
41390	//   "scopes": [
41391	//     "https://www.googleapis.com/auth/cloud-platform",
41392	//     "https://www.googleapis.com/auth/dialogflow"
41393	//   ]
41394	// }
41395
41396}
41397
41398// method id "dialogflow.projects.locations.conversationProfiles.get":
41399
41400type ProjectsLocationsConversationProfilesGetCall struct {
41401	s            *Service
41402	name         string
41403	urlParams_   gensupport.URLParams
41404	ifNoneMatch_ string
41405	ctx_         context.Context
41406	header_      http.Header
41407}
41408
41409// Get: Retrieves the specified conversation profile.
41410//
41411// - name: The resource name of the conversation profile. Format:
41412//   `projects//locations//conversationProfiles/`.
41413func (r *ProjectsLocationsConversationProfilesService) Get(name string) *ProjectsLocationsConversationProfilesGetCall {
41414	c := &ProjectsLocationsConversationProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41415	c.name = name
41416	return c
41417}
41418
41419// Fields allows partial responses to be retrieved. See
41420// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41421// for more information.
41422func (c *ProjectsLocationsConversationProfilesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationProfilesGetCall {
41423	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41424	return c
41425}
41426
41427// IfNoneMatch sets the optional parameter which makes the operation
41428// fail if the object's ETag matches the given value. This is useful for
41429// getting updates only after the object has changed since the last
41430// request. Use googleapi.IsNotModified to check whether the response
41431// error from Do is the result of In-None-Match.
41432func (c *ProjectsLocationsConversationProfilesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationProfilesGetCall {
41433	c.ifNoneMatch_ = entityTag
41434	return c
41435}
41436
41437// Context sets the context to be used in this call's Do method. Any
41438// pending HTTP request will be aborted if the provided context is
41439// canceled.
41440func (c *ProjectsLocationsConversationProfilesGetCall) Context(ctx context.Context) *ProjectsLocationsConversationProfilesGetCall {
41441	c.ctx_ = ctx
41442	return c
41443}
41444
41445// Header returns an http.Header that can be modified by the caller to
41446// add HTTP headers to the request.
41447func (c *ProjectsLocationsConversationProfilesGetCall) Header() http.Header {
41448	if c.header_ == nil {
41449		c.header_ = make(http.Header)
41450	}
41451	return c.header_
41452}
41453
41454func (c *ProjectsLocationsConversationProfilesGetCall) doRequest(alt string) (*http.Response, error) {
41455	reqHeaders := make(http.Header)
41456	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
41457	for k, v := range c.header_ {
41458		reqHeaders[k] = v
41459	}
41460	reqHeaders.Set("User-Agent", c.s.userAgent())
41461	if c.ifNoneMatch_ != "" {
41462		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41463	}
41464	var body io.Reader = nil
41465	c.urlParams_.Set("alt", alt)
41466	c.urlParams_.Set("prettyPrint", "false")
41467	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
41468	urls += "?" + c.urlParams_.Encode()
41469	req, err := http.NewRequest("GET", urls, body)
41470	if err != nil {
41471		return nil, err
41472	}
41473	req.Header = reqHeaders
41474	googleapi.Expand(req.URL, map[string]string{
41475		"name": c.name,
41476	})
41477	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41478}
41479
41480// Do executes the "dialogflow.projects.locations.conversationProfiles.get" call.
41481// Exactly one of *GoogleCloudDialogflowV2ConversationProfile or error
41482// will be non-nil. Any non-2xx status code is an error. Response
41483// headers are in either
41484// *GoogleCloudDialogflowV2ConversationProfile.ServerResponse.Header or
41485// (if a response was returned at all) in
41486// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
41487// whether the returned error was because http.StatusNotModified was
41488// returned.
41489func (c *ProjectsLocationsConversationProfilesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ConversationProfile, error) {
41490	gensupport.SetOptions(c.urlParams_, opts...)
41491	res, err := c.doRequest("json")
41492	if res != nil && res.StatusCode == http.StatusNotModified {
41493		if res.Body != nil {
41494			res.Body.Close()
41495		}
41496		return nil, &googleapi.Error{
41497			Code:   res.StatusCode,
41498			Header: res.Header,
41499		}
41500	}
41501	if err != nil {
41502		return nil, err
41503	}
41504	defer googleapi.CloseBody(res)
41505	if err := googleapi.CheckResponse(res); err != nil {
41506		return nil, err
41507	}
41508	ret := &GoogleCloudDialogflowV2ConversationProfile{
41509		ServerResponse: googleapi.ServerResponse{
41510			Header:         res.Header,
41511			HTTPStatusCode: res.StatusCode,
41512		},
41513	}
41514	target := &ret
41515	if err := gensupport.DecodeResponse(target, res); err != nil {
41516		return nil, err
41517	}
41518	return ret, nil
41519	// {
41520	//   "description": "Retrieves the specified conversation profile.",
41521	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversationProfiles/{conversationProfilesId}",
41522	//   "httpMethod": "GET",
41523	//   "id": "dialogflow.projects.locations.conversationProfiles.get",
41524	//   "parameterOrder": [
41525	//     "name"
41526	//   ],
41527	//   "parameters": {
41528	//     "name": {
41529	//       "description": "Required. The resource name of the conversation profile. Format: `projects//locations//conversationProfiles/`.",
41530	//       "location": "path",
41531	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversationProfiles/[^/]+$",
41532	//       "required": true,
41533	//       "type": "string"
41534	//     }
41535	//   },
41536	//   "path": "v2/{+name}",
41537	//   "response": {
41538	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
41539	//   },
41540	//   "scopes": [
41541	//     "https://www.googleapis.com/auth/cloud-platform",
41542	//     "https://www.googleapis.com/auth/dialogflow"
41543	//   ]
41544	// }
41545
41546}
41547
41548// method id "dialogflow.projects.locations.conversationProfiles.list":
41549
41550type ProjectsLocationsConversationProfilesListCall struct {
41551	s            *Service
41552	parent       string
41553	urlParams_   gensupport.URLParams
41554	ifNoneMatch_ string
41555	ctx_         context.Context
41556	header_      http.Header
41557}
41558
41559// List: Returns the list of all conversation profiles in the specified
41560// project.
41561//
41562// - parent: The project to list all conversation profiles from. Format:
41563//   `projects//locations/`.
41564func (r *ProjectsLocationsConversationProfilesService) List(parent string) *ProjectsLocationsConversationProfilesListCall {
41565	c := &ProjectsLocationsConversationProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41566	c.parent = parent
41567	return c
41568}
41569
41570// PageSize sets the optional parameter "pageSize": The maximum number
41571// of items to return in a single page. By default 100 and at most 1000.
41572func (c *ProjectsLocationsConversationProfilesListCall) PageSize(pageSize int64) *ProjectsLocationsConversationProfilesListCall {
41573	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
41574	return c
41575}
41576
41577// PageToken sets the optional parameter "pageToken": The
41578// next_page_token value returned from a previous list request.
41579func (c *ProjectsLocationsConversationProfilesListCall) PageToken(pageToken string) *ProjectsLocationsConversationProfilesListCall {
41580	c.urlParams_.Set("pageToken", pageToken)
41581	return c
41582}
41583
41584// Fields allows partial responses to be retrieved. See
41585// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41586// for more information.
41587func (c *ProjectsLocationsConversationProfilesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationProfilesListCall {
41588	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41589	return c
41590}
41591
41592// IfNoneMatch sets the optional parameter which makes the operation
41593// fail if the object's ETag matches the given value. This is useful for
41594// getting updates only after the object has changed since the last
41595// request. Use googleapi.IsNotModified to check whether the response
41596// error from Do is the result of In-None-Match.
41597func (c *ProjectsLocationsConversationProfilesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationProfilesListCall {
41598	c.ifNoneMatch_ = entityTag
41599	return c
41600}
41601
41602// Context sets the context to be used in this call's Do method. Any
41603// pending HTTP request will be aborted if the provided context is
41604// canceled.
41605func (c *ProjectsLocationsConversationProfilesListCall) Context(ctx context.Context) *ProjectsLocationsConversationProfilesListCall {
41606	c.ctx_ = ctx
41607	return c
41608}
41609
41610// Header returns an http.Header that can be modified by the caller to
41611// add HTTP headers to the request.
41612func (c *ProjectsLocationsConversationProfilesListCall) Header() http.Header {
41613	if c.header_ == nil {
41614		c.header_ = make(http.Header)
41615	}
41616	return c.header_
41617}
41618
41619func (c *ProjectsLocationsConversationProfilesListCall) doRequest(alt string) (*http.Response, error) {
41620	reqHeaders := make(http.Header)
41621	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
41622	for k, v := range c.header_ {
41623		reqHeaders[k] = v
41624	}
41625	reqHeaders.Set("User-Agent", c.s.userAgent())
41626	if c.ifNoneMatch_ != "" {
41627		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41628	}
41629	var body io.Reader = nil
41630	c.urlParams_.Set("alt", alt)
41631	c.urlParams_.Set("prettyPrint", "false")
41632	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversationProfiles")
41633	urls += "?" + c.urlParams_.Encode()
41634	req, err := http.NewRequest("GET", urls, body)
41635	if err != nil {
41636		return nil, err
41637	}
41638	req.Header = reqHeaders
41639	googleapi.Expand(req.URL, map[string]string{
41640		"parent": c.parent,
41641	})
41642	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41643}
41644
41645// Do executes the "dialogflow.projects.locations.conversationProfiles.list" call.
41646// Exactly one of
41647// *GoogleCloudDialogflowV2ListConversationProfilesResponse or error
41648// will be non-nil. Any non-2xx status code is an error. Response
41649// headers are in either
41650// *GoogleCloudDialogflowV2ListConversationProfilesResponse.ServerRespons
41651// e.Header or (if a response was returned at all) in
41652// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
41653// whether the returned error was because http.StatusNotModified was
41654// returned.
41655func (c *ProjectsLocationsConversationProfilesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListConversationProfilesResponse, error) {
41656	gensupport.SetOptions(c.urlParams_, opts...)
41657	res, err := c.doRequest("json")
41658	if res != nil && res.StatusCode == http.StatusNotModified {
41659		if res.Body != nil {
41660			res.Body.Close()
41661		}
41662		return nil, &googleapi.Error{
41663			Code:   res.StatusCode,
41664			Header: res.Header,
41665		}
41666	}
41667	if err != nil {
41668		return nil, err
41669	}
41670	defer googleapi.CloseBody(res)
41671	if err := googleapi.CheckResponse(res); err != nil {
41672		return nil, err
41673	}
41674	ret := &GoogleCloudDialogflowV2ListConversationProfilesResponse{
41675		ServerResponse: googleapi.ServerResponse{
41676			Header:         res.Header,
41677			HTTPStatusCode: res.StatusCode,
41678		},
41679	}
41680	target := &ret
41681	if err := gensupport.DecodeResponse(target, res); err != nil {
41682		return nil, err
41683	}
41684	return ret, nil
41685	// {
41686	//   "description": "Returns the list of all conversation profiles in the specified project.",
41687	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversationProfiles",
41688	//   "httpMethod": "GET",
41689	//   "id": "dialogflow.projects.locations.conversationProfiles.list",
41690	//   "parameterOrder": [
41691	//     "parent"
41692	//   ],
41693	//   "parameters": {
41694	//     "pageSize": {
41695	//       "description": "The maximum number of items to return in a single page. By default 100 and at most 1000.",
41696	//       "format": "int32",
41697	//       "location": "query",
41698	//       "type": "integer"
41699	//     },
41700	//     "pageToken": {
41701	//       "description": "The next_page_token value returned from a previous list request.",
41702	//       "location": "query",
41703	//       "type": "string"
41704	//     },
41705	//     "parent": {
41706	//       "description": "Required. The project to list all conversation profiles from. Format: `projects//locations/`.",
41707	//       "location": "path",
41708	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
41709	//       "required": true,
41710	//       "type": "string"
41711	//     }
41712	//   },
41713	//   "path": "v2/{+parent}/conversationProfiles",
41714	//   "response": {
41715	//     "$ref": "GoogleCloudDialogflowV2ListConversationProfilesResponse"
41716	//   },
41717	//   "scopes": [
41718	//     "https://www.googleapis.com/auth/cloud-platform",
41719	//     "https://www.googleapis.com/auth/dialogflow"
41720	//   ]
41721	// }
41722
41723}
41724
41725// Pages invokes f for each page of results.
41726// A non-nil error returned from f will halt the iteration.
41727// The provided context supersedes any context provided to the Context method.
41728func (c *ProjectsLocationsConversationProfilesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListConversationProfilesResponse) error) error {
41729	c.ctx_ = ctx
41730	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
41731	for {
41732		x, err := c.Do()
41733		if err != nil {
41734			return err
41735		}
41736		if err := f(x); err != nil {
41737			return err
41738		}
41739		if x.NextPageToken == "" {
41740			return nil
41741		}
41742		c.PageToken(x.NextPageToken)
41743	}
41744}
41745
41746// method id "dialogflow.projects.locations.conversationProfiles.patch":
41747
41748type ProjectsLocationsConversationProfilesPatchCall struct {
41749	s                                          *Service
41750	nameid                                     string
41751	googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile
41752	urlParams_                                 gensupport.URLParams
41753	ctx_                                       context.Context
41754	header_                                    http.Header
41755}
41756
41757// Patch: Updates the specified conversation profile.
41758// ConversationProfile.CreateTime and ConversationProfile.UpdateTime
41759// aren't populated in the response. You can retrieve them via
41760// GetConversationProfile API.
41761//
41762// - name: The unique identifier of this conversation profile. Format:
41763//   `projects//locations//conversationProfiles/`.
41764func (r *ProjectsLocationsConversationProfilesService) Patch(nameid string, googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile) *ProjectsLocationsConversationProfilesPatchCall {
41765	c := &ProjectsLocationsConversationProfilesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41766	c.nameid = nameid
41767	c.googleclouddialogflowv2conversationprofile = googleclouddialogflowv2conversationprofile
41768	return c
41769}
41770
41771// UpdateMask sets the optional parameter "updateMask": Required. The
41772// mask to control which fields to update.
41773func (c *ProjectsLocationsConversationProfilesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsConversationProfilesPatchCall {
41774	c.urlParams_.Set("updateMask", updateMask)
41775	return c
41776}
41777
41778// Fields allows partial responses to be retrieved. See
41779// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41780// for more information.
41781func (c *ProjectsLocationsConversationProfilesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationProfilesPatchCall {
41782	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41783	return c
41784}
41785
41786// Context sets the context to be used in this call's Do method. Any
41787// pending HTTP request will be aborted if the provided context is
41788// canceled.
41789func (c *ProjectsLocationsConversationProfilesPatchCall) Context(ctx context.Context) *ProjectsLocationsConversationProfilesPatchCall {
41790	c.ctx_ = ctx
41791	return c
41792}
41793
41794// Header returns an http.Header that can be modified by the caller to
41795// add HTTP headers to the request.
41796func (c *ProjectsLocationsConversationProfilesPatchCall) Header() http.Header {
41797	if c.header_ == nil {
41798		c.header_ = make(http.Header)
41799	}
41800	return c.header_
41801}
41802
41803func (c *ProjectsLocationsConversationProfilesPatchCall) doRequest(alt string) (*http.Response, error) {
41804	reqHeaders := make(http.Header)
41805	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
41806	for k, v := range c.header_ {
41807		reqHeaders[k] = v
41808	}
41809	reqHeaders.Set("User-Agent", c.s.userAgent())
41810	var body io.Reader = nil
41811	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2conversationprofile)
41812	if err != nil {
41813		return nil, err
41814	}
41815	reqHeaders.Set("Content-Type", "application/json")
41816	c.urlParams_.Set("alt", alt)
41817	c.urlParams_.Set("prettyPrint", "false")
41818	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
41819	urls += "?" + c.urlParams_.Encode()
41820	req, err := http.NewRequest("PATCH", urls, body)
41821	if err != nil {
41822		return nil, err
41823	}
41824	req.Header = reqHeaders
41825	googleapi.Expand(req.URL, map[string]string{
41826		"name": c.nameid,
41827	})
41828	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41829}
41830
41831// Do executes the "dialogflow.projects.locations.conversationProfiles.patch" call.
41832// Exactly one of *GoogleCloudDialogflowV2ConversationProfile or error
41833// will be non-nil. Any non-2xx status code is an error. Response
41834// headers are in either
41835// *GoogleCloudDialogflowV2ConversationProfile.ServerResponse.Header or
41836// (if a response was returned at all) in
41837// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
41838// whether the returned error was because http.StatusNotModified was
41839// returned.
41840func (c *ProjectsLocationsConversationProfilesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ConversationProfile, error) {
41841	gensupport.SetOptions(c.urlParams_, opts...)
41842	res, err := c.doRequest("json")
41843	if res != nil && res.StatusCode == http.StatusNotModified {
41844		if res.Body != nil {
41845			res.Body.Close()
41846		}
41847		return nil, &googleapi.Error{
41848			Code:   res.StatusCode,
41849			Header: res.Header,
41850		}
41851	}
41852	if err != nil {
41853		return nil, err
41854	}
41855	defer googleapi.CloseBody(res)
41856	if err := googleapi.CheckResponse(res); err != nil {
41857		return nil, err
41858	}
41859	ret := &GoogleCloudDialogflowV2ConversationProfile{
41860		ServerResponse: googleapi.ServerResponse{
41861			Header:         res.Header,
41862			HTTPStatusCode: res.StatusCode,
41863		},
41864	}
41865	target := &ret
41866	if err := gensupport.DecodeResponse(target, res); err != nil {
41867		return nil, err
41868	}
41869	return ret, nil
41870	// {
41871	//   "description": "Updates the specified conversation profile. ConversationProfile.CreateTime and ConversationProfile.UpdateTime aren't populated in the response. You can retrieve them via GetConversationProfile API.",
41872	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversationProfiles/{conversationProfilesId}",
41873	//   "httpMethod": "PATCH",
41874	//   "id": "dialogflow.projects.locations.conversationProfiles.patch",
41875	//   "parameterOrder": [
41876	//     "name"
41877	//   ],
41878	//   "parameters": {
41879	//     "name": {
41880	//       "description": "The unique identifier of this conversation profile. Format: `projects//locations//conversationProfiles/`.",
41881	//       "location": "path",
41882	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversationProfiles/[^/]+$",
41883	//       "required": true,
41884	//       "type": "string"
41885	//     },
41886	//     "updateMask": {
41887	//       "description": "Required. The mask to control which fields to update.",
41888	//       "format": "google-fieldmask",
41889	//       "location": "query",
41890	//       "type": "string"
41891	//     }
41892	//   },
41893	//   "path": "v2/{+name}",
41894	//   "request": {
41895	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
41896	//   },
41897	//   "response": {
41898	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
41899	//   },
41900	//   "scopes": [
41901	//     "https://www.googleapis.com/auth/cloud-platform",
41902	//     "https://www.googleapis.com/auth/dialogflow"
41903	//   ]
41904	// }
41905
41906}
41907
41908// method id "dialogflow.projects.locations.conversations.complete":
41909
41910type ProjectsLocationsConversationsCompleteCall struct {
41911	s                                                  *Service
41912	nameid                                             string
41913	googleclouddialogflowv2completeconversationrequest *GoogleCloudDialogflowV2CompleteConversationRequest
41914	urlParams_                                         gensupport.URLParams
41915	ctx_                                               context.Context
41916	header_                                            http.Header
41917}
41918
41919// Complete: Completes the specified conversation. Finished
41920// conversations are purged from the database after 30 days.
41921//
41922// - name: Resource identifier of the conversation to close. Format:
41923//   `projects//locations//conversations/`.
41924func (r *ProjectsLocationsConversationsService) Complete(nameid string, googleclouddialogflowv2completeconversationrequest *GoogleCloudDialogflowV2CompleteConversationRequest) *ProjectsLocationsConversationsCompleteCall {
41925	c := &ProjectsLocationsConversationsCompleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41926	c.nameid = nameid
41927	c.googleclouddialogflowv2completeconversationrequest = googleclouddialogflowv2completeconversationrequest
41928	return c
41929}
41930
41931// Fields allows partial responses to be retrieved. See
41932// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41933// for more information.
41934func (c *ProjectsLocationsConversationsCompleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsCompleteCall {
41935	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41936	return c
41937}
41938
41939// Context sets the context to be used in this call's Do method. Any
41940// pending HTTP request will be aborted if the provided context is
41941// canceled.
41942func (c *ProjectsLocationsConversationsCompleteCall) Context(ctx context.Context) *ProjectsLocationsConversationsCompleteCall {
41943	c.ctx_ = ctx
41944	return c
41945}
41946
41947// Header returns an http.Header that can be modified by the caller to
41948// add HTTP headers to the request.
41949func (c *ProjectsLocationsConversationsCompleteCall) Header() http.Header {
41950	if c.header_ == nil {
41951		c.header_ = make(http.Header)
41952	}
41953	return c.header_
41954}
41955
41956func (c *ProjectsLocationsConversationsCompleteCall) doRequest(alt string) (*http.Response, error) {
41957	reqHeaders := make(http.Header)
41958	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
41959	for k, v := range c.header_ {
41960		reqHeaders[k] = v
41961	}
41962	reqHeaders.Set("User-Agent", c.s.userAgent())
41963	var body io.Reader = nil
41964	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2completeconversationrequest)
41965	if err != nil {
41966		return nil, err
41967	}
41968	reqHeaders.Set("Content-Type", "application/json")
41969	c.urlParams_.Set("alt", alt)
41970	c.urlParams_.Set("prettyPrint", "false")
41971	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:complete")
41972	urls += "?" + c.urlParams_.Encode()
41973	req, err := http.NewRequest("POST", urls, body)
41974	if err != nil {
41975		return nil, err
41976	}
41977	req.Header = reqHeaders
41978	googleapi.Expand(req.URL, map[string]string{
41979		"name": c.nameid,
41980	})
41981	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41982}
41983
41984// Do executes the "dialogflow.projects.locations.conversations.complete" call.
41985// Exactly one of *GoogleCloudDialogflowV2Conversation or error will be
41986// non-nil. Any non-2xx status code is an error. Response headers are in
41987// either *GoogleCloudDialogflowV2Conversation.ServerResponse.Header or
41988// (if a response was returned at all) in
41989// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
41990// whether the returned error was because http.StatusNotModified was
41991// returned.
41992func (c *ProjectsLocationsConversationsCompleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Conversation, error) {
41993	gensupport.SetOptions(c.urlParams_, opts...)
41994	res, err := c.doRequest("json")
41995	if res != nil && res.StatusCode == http.StatusNotModified {
41996		if res.Body != nil {
41997			res.Body.Close()
41998		}
41999		return nil, &googleapi.Error{
42000			Code:   res.StatusCode,
42001			Header: res.Header,
42002		}
42003	}
42004	if err != nil {
42005		return nil, err
42006	}
42007	defer googleapi.CloseBody(res)
42008	if err := googleapi.CheckResponse(res); err != nil {
42009		return nil, err
42010	}
42011	ret := &GoogleCloudDialogflowV2Conversation{
42012		ServerResponse: googleapi.ServerResponse{
42013			Header:         res.Header,
42014			HTTPStatusCode: res.StatusCode,
42015		},
42016	}
42017	target := &ret
42018	if err := gensupport.DecodeResponse(target, res); err != nil {
42019		return nil, err
42020	}
42021	return ret, nil
42022	// {
42023	//   "description": "Completes the specified conversation. Finished conversations are purged from the database after 30 days.",
42024	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}:complete",
42025	//   "httpMethod": "POST",
42026	//   "id": "dialogflow.projects.locations.conversations.complete",
42027	//   "parameterOrder": [
42028	//     "name"
42029	//   ],
42030	//   "parameters": {
42031	//     "name": {
42032	//       "description": "Required. Resource identifier of the conversation to close. Format: `projects//locations//conversations/`.",
42033	//       "location": "path",
42034	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+$",
42035	//       "required": true,
42036	//       "type": "string"
42037	//     }
42038	//   },
42039	//   "path": "v2/{+name}:complete",
42040	//   "request": {
42041	//     "$ref": "GoogleCloudDialogflowV2CompleteConversationRequest"
42042	//   },
42043	//   "response": {
42044	//     "$ref": "GoogleCloudDialogflowV2Conversation"
42045	//   },
42046	//   "scopes": [
42047	//     "https://www.googleapis.com/auth/cloud-platform",
42048	//     "https://www.googleapis.com/auth/dialogflow"
42049	//   ]
42050	// }
42051
42052}
42053
42054// method id "dialogflow.projects.locations.conversations.create":
42055
42056type ProjectsLocationsConversationsCreateCall struct {
42057	s                                   *Service
42058	parentid                            string
42059	googleclouddialogflowv2conversation *GoogleCloudDialogflowV2Conversation
42060	urlParams_                          gensupport.URLParams
42061	ctx_                                context.Context
42062	header_                             http.Header
42063}
42064
42065// Create: Creates a new conversation. Conversations are auto-completed
42066// after 24 hours. Conversation Lifecycle: There are two stages during a
42067// conversation: Automated Agent Stage and Assist Stage. For Automated
42068// Agent Stage, there will be a dialogflow agent responding to user
42069// queries. For Assist Stage, there's no dialogflow agent responding to
42070// user queries. But we will provide suggestions which are generated
42071// from conversation. If Conversation.conversation_profile is configured
42072// for a dialogflow agent, conversation will start from `Automated Agent
42073// Stage`, otherwise, it will start from `Assist Stage`. And during
42074// `Automated Agent Stage`, once an Intent with
42075// Intent.live_agent_handoff is triggered, conversation will transfer to
42076// Assist Stage.
42077//
42078// - parent: Resource identifier of the project creating the
42079//   conversation. Format: `projects//locations/`.
42080func (r *ProjectsLocationsConversationsService) Create(parentid string, googleclouddialogflowv2conversation *GoogleCloudDialogflowV2Conversation) *ProjectsLocationsConversationsCreateCall {
42081	c := &ProjectsLocationsConversationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42082	c.parentid = parentid
42083	c.googleclouddialogflowv2conversation = googleclouddialogflowv2conversation
42084	return c
42085}
42086
42087// ConversationId sets the optional parameter "conversationId":
42088// Identifier of the conversation. Generally it's auto generated by
42089// Google. Only set it if you cannot wait for the response to return a
42090// auto-generated one to you. The conversation ID must be compliant with
42091// the regression fomula "a-zA-Z*" with the characters length in range
42092// of [3,64]. If the field is provided, the caller is resposible for 1.
42093// the uniqueness of the ID, otherwise the request will be rejected. 2.
42094// the consistency for whether to use custom ID or not under a project
42095// to better ensure uniqueness.
42096func (c *ProjectsLocationsConversationsCreateCall) ConversationId(conversationId string) *ProjectsLocationsConversationsCreateCall {
42097	c.urlParams_.Set("conversationId", conversationId)
42098	return c
42099}
42100
42101// Fields allows partial responses to be retrieved. See
42102// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42103// for more information.
42104func (c *ProjectsLocationsConversationsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsCreateCall {
42105	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42106	return c
42107}
42108
42109// Context sets the context to be used in this call's Do method. Any
42110// pending HTTP request will be aborted if the provided context is
42111// canceled.
42112func (c *ProjectsLocationsConversationsCreateCall) Context(ctx context.Context) *ProjectsLocationsConversationsCreateCall {
42113	c.ctx_ = ctx
42114	return c
42115}
42116
42117// Header returns an http.Header that can be modified by the caller to
42118// add HTTP headers to the request.
42119func (c *ProjectsLocationsConversationsCreateCall) Header() http.Header {
42120	if c.header_ == nil {
42121		c.header_ = make(http.Header)
42122	}
42123	return c.header_
42124}
42125
42126func (c *ProjectsLocationsConversationsCreateCall) doRequest(alt string) (*http.Response, error) {
42127	reqHeaders := make(http.Header)
42128	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
42129	for k, v := range c.header_ {
42130		reqHeaders[k] = v
42131	}
42132	reqHeaders.Set("User-Agent", c.s.userAgent())
42133	var body io.Reader = nil
42134	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2conversation)
42135	if err != nil {
42136		return nil, err
42137	}
42138	reqHeaders.Set("Content-Type", "application/json")
42139	c.urlParams_.Set("alt", alt)
42140	c.urlParams_.Set("prettyPrint", "false")
42141	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversations")
42142	urls += "?" + c.urlParams_.Encode()
42143	req, err := http.NewRequest("POST", urls, body)
42144	if err != nil {
42145		return nil, err
42146	}
42147	req.Header = reqHeaders
42148	googleapi.Expand(req.URL, map[string]string{
42149		"parent": c.parentid,
42150	})
42151	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42152}
42153
42154// Do executes the "dialogflow.projects.locations.conversations.create" call.
42155// Exactly one of *GoogleCloudDialogflowV2Conversation or error will be
42156// non-nil. Any non-2xx status code is an error. Response headers are in
42157// either *GoogleCloudDialogflowV2Conversation.ServerResponse.Header or
42158// (if a response was returned at all) in
42159// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
42160// whether the returned error was because http.StatusNotModified was
42161// returned.
42162func (c *ProjectsLocationsConversationsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Conversation, error) {
42163	gensupport.SetOptions(c.urlParams_, opts...)
42164	res, err := c.doRequest("json")
42165	if res != nil && res.StatusCode == http.StatusNotModified {
42166		if res.Body != nil {
42167			res.Body.Close()
42168		}
42169		return nil, &googleapi.Error{
42170			Code:   res.StatusCode,
42171			Header: res.Header,
42172		}
42173	}
42174	if err != nil {
42175		return nil, err
42176	}
42177	defer googleapi.CloseBody(res)
42178	if err := googleapi.CheckResponse(res); err != nil {
42179		return nil, err
42180	}
42181	ret := &GoogleCloudDialogflowV2Conversation{
42182		ServerResponse: googleapi.ServerResponse{
42183			Header:         res.Header,
42184			HTTPStatusCode: res.StatusCode,
42185		},
42186	}
42187	target := &ret
42188	if err := gensupport.DecodeResponse(target, res); err != nil {
42189		return nil, err
42190	}
42191	return ret, nil
42192	// {
42193	//   "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.",
42194	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations",
42195	//   "httpMethod": "POST",
42196	//   "id": "dialogflow.projects.locations.conversations.create",
42197	//   "parameterOrder": [
42198	//     "parent"
42199	//   ],
42200	//   "parameters": {
42201	//     "conversationId": {
42202	//       "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.",
42203	//       "location": "query",
42204	//       "type": "string"
42205	//     },
42206	//     "parent": {
42207	//       "description": "Required. Resource identifier of the project creating the conversation. Format: `projects//locations/`.",
42208	//       "location": "path",
42209	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
42210	//       "required": true,
42211	//       "type": "string"
42212	//     }
42213	//   },
42214	//   "path": "v2/{+parent}/conversations",
42215	//   "request": {
42216	//     "$ref": "GoogleCloudDialogflowV2Conversation"
42217	//   },
42218	//   "response": {
42219	//     "$ref": "GoogleCloudDialogflowV2Conversation"
42220	//   },
42221	//   "scopes": [
42222	//     "https://www.googleapis.com/auth/cloud-platform",
42223	//     "https://www.googleapis.com/auth/dialogflow"
42224	//   ]
42225	// }
42226
42227}
42228
42229// method id "dialogflow.projects.locations.conversations.get":
42230
42231type ProjectsLocationsConversationsGetCall struct {
42232	s            *Service
42233	name         string
42234	urlParams_   gensupport.URLParams
42235	ifNoneMatch_ string
42236	ctx_         context.Context
42237	header_      http.Header
42238}
42239
42240// Get: Retrieves the specific conversation.
42241//
42242// - name: The name of the conversation. Format:
42243//   `projects//locations//conversations/`.
42244func (r *ProjectsLocationsConversationsService) Get(name string) *ProjectsLocationsConversationsGetCall {
42245	c := &ProjectsLocationsConversationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42246	c.name = name
42247	return c
42248}
42249
42250// Fields allows partial responses to be retrieved. See
42251// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42252// for more information.
42253func (c *ProjectsLocationsConversationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsGetCall {
42254	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42255	return c
42256}
42257
42258// IfNoneMatch sets the optional parameter which makes the operation
42259// fail if the object's ETag matches the given value. This is useful for
42260// getting updates only after the object has changed since the last
42261// request. Use googleapi.IsNotModified to check whether the response
42262// error from Do is the result of In-None-Match.
42263func (c *ProjectsLocationsConversationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationsGetCall {
42264	c.ifNoneMatch_ = entityTag
42265	return c
42266}
42267
42268// Context sets the context to be used in this call's Do method. Any
42269// pending HTTP request will be aborted if the provided context is
42270// canceled.
42271func (c *ProjectsLocationsConversationsGetCall) Context(ctx context.Context) *ProjectsLocationsConversationsGetCall {
42272	c.ctx_ = ctx
42273	return c
42274}
42275
42276// Header returns an http.Header that can be modified by the caller to
42277// add HTTP headers to the request.
42278func (c *ProjectsLocationsConversationsGetCall) Header() http.Header {
42279	if c.header_ == nil {
42280		c.header_ = make(http.Header)
42281	}
42282	return c.header_
42283}
42284
42285func (c *ProjectsLocationsConversationsGetCall) doRequest(alt string) (*http.Response, error) {
42286	reqHeaders := make(http.Header)
42287	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
42288	for k, v := range c.header_ {
42289		reqHeaders[k] = v
42290	}
42291	reqHeaders.Set("User-Agent", c.s.userAgent())
42292	if c.ifNoneMatch_ != "" {
42293		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42294	}
42295	var body io.Reader = nil
42296	c.urlParams_.Set("alt", alt)
42297	c.urlParams_.Set("prettyPrint", "false")
42298	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
42299	urls += "?" + c.urlParams_.Encode()
42300	req, err := http.NewRequest("GET", urls, body)
42301	if err != nil {
42302		return nil, err
42303	}
42304	req.Header = reqHeaders
42305	googleapi.Expand(req.URL, map[string]string{
42306		"name": c.name,
42307	})
42308	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42309}
42310
42311// Do executes the "dialogflow.projects.locations.conversations.get" call.
42312// Exactly one of *GoogleCloudDialogflowV2Conversation or error will be
42313// non-nil. Any non-2xx status code is an error. Response headers are in
42314// either *GoogleCloudDialogflowV2Conversation.ServerResponse.Header or
42315// (if a response was returned at all) in
42316// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
42317// whether the returned error was because http.StatusNotModified was
42318// returned.
42319func (c *ProjectsLocationsConversationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Conversation, error) {
42320	gensupport.SetOptions(c.urlParams_, opts...)
42321	res, err := c.doRequest("json")
42322	if res != nil && res.StatusCode == http.StatusNotModified {
42323		if res.Body != nil {
42324			res.Body.Close()
42325		}
42326		return nil, &googleapi.Error{
42327			Code:   res.StatusCode,
42328			Header: res.Header,
42329		}
42330	}
42331	if err != nil {
42332		return nil, err
42333	}
42334	defer googleapi.CloseBody(res)
42335	if err := googleapi.CheckResponse(res); err != nil {
42336		return nil, err
42337	}
42338	ret := &GoogleCloudDialogflowV2Conversation{
42339		ServerResponse: googleapi.ServerResponse{
42340			Header:         res.Header,
42341			HTTPStatusCode: res.StatusCode,
42342		},
42343	}
42344	target := &ret
42345	if err := gensupport.DecodeResponse(target, res); err != nil {
42346		return nil, err
42347	}
42348	return ret, nil
42349	// {
42350	//   "description": "Retrieves the specific conversation.",
42351	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}",
42352	//   "httpMethod": "GET",
42353	//   "id": "dialogflow.projects.locations.conversations.get",
42354	//   "parameterOrder": [
42355	//     "name"
42356	//   ],
42357	//   "parameters": {
42358	//     "name": {
42359	//       "description": "Required. The name of the conversation. Format: `projects//locations//conversations/`.",
42360	//       "location": "path",
42361	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+$",
42362	//       "required": true,
42363	//       "type": "string"
42364	//     }
42365	//   },
42366	//   "path": "v2/{+name}",
42367	//   "response": {
42368	//     "$ref": "GoogleCloudDialogflowV2Conversation"
42369	//   },
42370	//   "scopes": [
42371	//     "https://www.googleapis.com/auth/cloud-platform",
42372	//     "https://www.googleapis.com/auth/dialogflow"
42373	//   ]
42374	// }
42375
42376}
42377
42378// method id "dialogflow.projects.locations.conversations.list":
42379
42380type ProjectsLocationsConversationsListCall struct {
42381	s            *Service
42382	parent       string
42383	urlParams_   gensupport.URLParams
42384	ifNoneMatch_ string
42385	ctx_         context.Context
42386	header_      http.Header
42387}
42388
42389// List: Returns the list of all conversations in the specified project.
42390//
42391// - parent: The project from which to list all conversation. Format:
42392//   `projects//locations/`.
42393func (r *ProjectsLocationsConversationsService) List(parent string) *ProjectsLocationsConversationsListCall {
42394	c := &ProjectsLocationsConversationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42395	c.parent = parent
42396	return c
42397}
42398
42399// Filter sets the optional parameter "filter": A filter expression that
42400// filters conversations listed in the response. In general, the
42401// expression must specify the field name, a comparison operator, and
42402// the value to use for filtering: - The value must be a string, a
42403// number, or a boolean. - The comparison operator must be either
42404// `=`,`!=`, `>`, or `<`. - To filter on multiple expressions, separate
42405// the expressions with `AND` or `OR` (omitting both implies `AND`). -
42406// For clarity, expressions can be enclosed in parentheses. Only
42407// `lifecycle_state` can be filtered on in this way. For example, the
42408// following expression only returns `COMPLETED` conversations:
42409// `lifecycle_state = "COMPLETED" For more information about filtering,
42410// see API Filtering (https://aip.dev/160).
42411func (c *ProjectsLocationsConversationsListCall) Filter(filter string) *ProjectsLocationsConversationsListCall {
42412	c.urlParams_.Set("filter", filter)
42413	return c
42414}
42415
42416// PageSize sets the optional parameter "pageSize": The maximum number
42417// of items to return in a single page. By default 100 and at most 1000.
42418func (c *ProjectsLocationsConversationsListCall) PageSize(pageSize int64) *ProjectsLocationsConversationsListCall {
42419	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
42420	return c
42421}
42422
42423// PageToken sets the optional parameter "pageToken": The
42424// next_page_token value returned from a previous list request.
42425func (c *ProjectsLocationsConversationsListCall) PageToken(pageToken string) *ProjectsLocationsConversationsListCall {
42426	c.urlParams_.Set("pageToken", pageToken)
42427	return c
42428}
42429
42430// Fields allows partial responses to be retrieved. See
42431// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42432// for more information.
42433func (c *ProjectsLocationsConversationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsListCall {
42434	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42435	return c
42436}
42437
42438// IfNoneMatch sets the optional parameter which makes the operation
42439// fail if the object's ETag matches the given value. This is useful for
42440// getting updates only after the object has changed since the last
42441// request. Use googleapi.IsNotModified to check whether the response
42442// error from Do is the result of In-None-Match.
42443func (c *ProjectsLocationsConversationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationsListCall {
42444	c.ifNoneMatch_ = entityTag
42445	return c
42446}
42447
42448// Context sets the context to be used in this call's Do method. Any
42449// pending HTTP request will be aborted if the provided context is
42450// canceled.
42451func (c *ProjectsLocationsConversationsListCall) Context(ctx context.Context) *ProjectsLocationsConversationsListCall {
42452	c.ctx_ = ctx
42453	return c
42454}
42455
42456// Header returns an http.Header that can be modified by the caller to
42457// add HTTP headers to the request.
42458func (c *ProjectsLocationsConversationsListCall) Header() http.Header {
42459	if c.header_ == nil {
42460		c.header_ = make(http.Header)
42461	}
42462	return c.header_
42463}
42464
42465func (c *ProjectsLocationsConversationsListCall) doRequest(alt string) (*http.Response, error) {
42466	reqHeaders := make(http.Header)
42467	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
42468	for k, v := range c.header_ {
42469		reqHeaders[k] = v
42470	}
42471	reqHeaders.Set("User-Agent", c.s.userAgent())
42472	if c.ifNoneMatch_ != "" {
42473		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42474	}
42475	var body io.Reader = nil
42476	c.urlParams_.Set("alt", alt)
42477	c.urlParams_.Set("prettyPrint", "false")
42478	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversations")
42479	urls += "?" + c.urlParams_.Encode()
42480	req, err := http.NewRequest("GET", urls, body)
42481	if err != nil {
42482		return nil, err
42483	}
42484	req.Header = reqHeaders
42485	googleapi.Expand(req.URL, map[string]string{
42486		"parent": c.parent,
42487	})
42488	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42489}
42490
42491// Do executes the "dialogflow.projects.locations.conversations.list" call.
42492// Exactly one of *GoogleCloudDialogflowV2ListConversationsResponse or
42493// error will be non-nil. Any non-2xx status code is an error. Response
42494// headers are in either
42495// *GoogleCloudDialogflowV2ListConversationsResponse.ServerResponse.Heade
42496// r or (if a response was returned at all) in
42497// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
42498// whether the returned error was because http.StatusNotModified was
42499// returned.
42500func (c *ProjectsLocationsConversationsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListConversationsResponse, error) {
42501	gensupport.SetOptions(c.urlParams_, opts...)
42502	res, err := c.doRequest("json")
42503	if res != nil && res.StatusCode == http.StatusNotModified {
42504		if res.Body != nil {
42505			res.Body.Close()
42506		}
42507		return nil, &googleapi.Error{
42508			Code:   res.StatusCode,
42509			Header: res.Header,
42510		}
42511	}
42512	if err != nil {
42513		return nil, err
42514	}
42515	defer googleapi.CloseBody(res)
42516	if err := googleapi.CheckResponse(res); err != nil {
42517		return nil, err
42518	}
42519	ret := &GoogleCloudDialogflowV2ListConversationsResponse{
42520		ServerResponse: googleapi.ServerResponse{
42521			Header:         res.Header,
42522			HTTPStatusCode: res.StatusCode,
42523		},
42524	}
42525	target := &ret
42526	if err := gensupport.DecodeResponse(target, res); err != nil {
42527		return nil, err
42528	}
42529	return ret, nil
42530	// {
42531	//   "description": "Returns the list of all conversations in the specified project.",
42532	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations",
42533	//   "httpMethod": "GET",
42534	//   "id": "dialogflow.projects.locations.conversations.list",
42535	//   "parameterOrder": [
42536	//     "parent"
42537	//   ],
42538	//   "parameters": {
42539	//     "filter": {
42540	//       "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).",
42541	//       "location": "query",
42542	//       "type": "string"
42543	//     },
42544	//     "pageSize": {
42545	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
42546	//       "format": "int32",
42547	//       "location": "query",
42548	//       "type": "integer"
42549	//     },
42550	//     "pageToken": {
42551	//       "description": "Optional. The next_page_token value returned from a previous list request.",
42552	//       "location": "query",
42553	//       "type": "string"
42554	//     },
42555	//     "parent": {
42556	//       "description": "Required. The project from which to list all conversation. Format: `projects//locations/`.",
42557	//       "location": "path",
42558	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
42559	//       "required": true,
42560	//       "type": "string"
42561	//     }
42562	//   },
42563	//   "path": "v2/{+parent}/conversations",
42564	//   "response": {
42565	//     "$ref": "GoogleCloudDialogflowV2ListConversationsResponse"
42566	//   },
42567	//   "scopes": [
42568	//     "https://www.googleapis.com/auth/cloud-platform",
42569	//     "https://www.googleapis.com/auth/dialogflow"
42570	//   ]
42571	// }
42572
42573}
42574
42575// Pages invokes f for each page of results.
42576// A non-nil error returned from f will halt the iteration.
42577// The provided context supersedes any context provided to the Context method.
42578func (c *ProjectsLocationsConversationsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListConversationsResponse) error) error {
42579	c.ctx_ = ctx
42580	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
42581	for {
42582		x, err := c.Do()
42583		if err != nil {
42584			return err
42585		}
42586		if err := f(x); err != nil {
42587			return err
42588		}
42589		if x.NextPageToken == "" {
42590			return nil
42591		}
42592		c.PageToken(x.NextPageToken)
42593	}
42594}
42595
42596// method id "dialogflow.projects.locations.conversations.messages.list":
42597
42598type ProjectsLocationsConversationsMessagesListCall struct {
42599	s            *Service
42600	parent       string
42601	urlParams_   gensupport.URLParams
42602	ifNoneMatch_ string
42603	ctx_         context.Context
42604	header_      http.Header
42605}
42606
42607// List: Lists messages that belong to a given conversation. `messages`
42608// are ordered by `create_time` in descending order. To fetch updates
42609// without duplication, send request with filter
42610// `create_time_epoch_microseconds > [first item's create_time of
42611// previous request]` and empty page_token.
42612//
42613// - parent: The name of the conversation to list messages for. Format:
42614//   `projects//locations//conversations/`.
42615func (r *ProjectsLocationsConversationsMessagesService) List(parent string) *ProjectsLocationsConversationsMessagesListCall {
42616	c := &ProjectsLocationsConversationsMessagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42617	c.parent = parent
42618	return c
42619}
42620
42621// Filter sets the optional parameter "filter": Filter on message
42622// fields. Currently predicates on `create_time` and
42623// `create_time_epoch_microseconds` are supported. `create_time` only
42624// support milliseconds accuracy. E.g., `create_time_epoch_microseconds
42625// > 1551790877964485` or `create_time > 2017-01-15T01:30:15.01Z`. For
42626// more information about filtering, see API Filtering
42627// (https://aip.dev/160).
42628func (c *ProjectsLocationsConversationsMessagesListCall) Filter(filter string) *ProjectsLocationsConversationsMessagesListCall {
42629	c.urlParams_.Set("filter", filter)
42630	return c
42631}
42632
42633// PageSize sets the optional parameter "pageSize": The maximum number
42634// of items to return in a single page. By default 100 and at most 1000.
42635func (c *ProjectsLocationsConversationsMessagesListCall) PageSize(pageSize int64) *ProjectsLocationsConversationsMessagesListCall {
42636	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
42637	return c
42638}
42639
42640// PageToken sets the optional parameter "pageToken": The
42641// next_page_token value returned from a previous list request.
42642func (c *ProjectsLocationsConversationsMessagesListCall) PageToken(pageToken string) *ProjectsLocationsConversationsMessagesListCall {
42643	c.urlParams_.Set("pageToken", pageToken)
42644	return c
42645}
42646
42647// Fields allows partial responses to be retrieved. See
42648// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42649// for more information.
42650func (c *ProjectsLocationsConversationsMessagesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsMessagesListCall {
42651	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42652	return c
42653}
42654
42655// IfNoneMatch sets the optional parameter which makes the operation
42656// fail if the object's ETag matches the given value. This is useful for
42657// getting updates only after the object has changed since the last
42658// request. Use googleapi.IsNotModified to check whether the response
42659// error from Do is the result of In-None-Match.
42660func (c *ProjectsLocationsConversationsMessagesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationsMessagesListCall {
42661	c.ifNoneMatch_ = entityTag
42662	return c
42663}
42664
42665// Context sets the context to be used in this call's Do method. Any
42666// pending HTTP request will be aborted if the provided context is
42667// canceled.
42668func (c *ProjectsLocationsConversationsMessagesListCall) Context(ctx context.Context) *ProjectsLocationsConversationsMessagesListCall {
42669	c.ctx_ = ctx
42670	return c
42671}
42672
42673// Header returns an http.Header that can be modified by the caller to
42674// add HTTP headers to the request.
42675func (c *ProjectsLocationsConversationsMessagesListCall) Header() http.Header {
42676	if c.header_ == nil {
42677		c.header_ = make(http.Header)
42678	}
42679	return c.header_
42680}
42681
42682func (c *ProjectsLocationsConversationsMessagesListCall) doRequest(alt string) (*http.Response, error) {
42683	reqHeaders := make(http.Header)
42684	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
42685	for k, v := range c.header_ {
42686		reqHeaders[k] = v
42687	}
42688	reqHeaders.Set("User-Agent", c.s.userAgent())
42689	if c.ifNoneMatch_ != "" {
42690		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42691	}
42692	var body io.Reader = nil
42693	c.urlParams_.Set("alt", alt)
42694	c.urlParams_.Set("prettyPrint", "false")
42695	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/messages")
42696	urls += "?" + c.urlParams_.Encode()
42697	req, err := http.NewRequest("GET", urls, body)
42698	if err != nil {
42699		return nil, err
42700	}
42701	req.Header = reqHeaders
42702	googleapi.Expand(req.URL, map[string]string{
42703		"parent": c.parent,
42704	})
42705	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42706}
42707
42708// Do executes the "dialogflow.projects.locations.conversations.messages.list" call.
42709// Exactly one of *GoogleCloudDialogflowV2ListMessagesResponse or error
42710// will be non-nil. Any non-2xx status code is an error. Response
42711// headers are in either
42712// *GoogleCloudDialogflowV2ListMessagesResponse.ServerResponse.Header or
42713// (if a response was returned at all) in
42714// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
42715// whether the returned error was because http.StatusNotModified was
42716// returned.
42717func (c *ProjectsLocationsConversationsMessagesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListMessagesResponse, error) {
42718	gensupport.SetOptions(c.urlParams_, opts...)
42719	res, err := c.doRequest("json")
42720	if res != nil && res.StatusCode == http.StatusNotModified {
42721		if res.Body != nil {
42722			res.Body.Close()
42723		}
42724		return nil, &googleapi.Error{
42725			Code:   res.StatusCode,
42726			Header: res.Header,
42727		}
42728	}
42729	if err != nil {
42730		return nil, err
42731	}
42732	defer googleapi.CloseBody(res)
42733	if err := googleapi.CheckResponse(res); err != nil {
42734		return nil, err
42735	}
42736	ret := &GoogleCloudDialogflowV2ListMessagesResponse{
42737		ServerResponse: googleapi.ServerResponse{
42738			Header:         res.Header,
42739			HTTPStatusCode: res.StatusCode,
42740		},
42741	}
42742	target := &ret
42743	if err := gensupport.DecodeResponse(target, res); err != nil {
42744		return nil, err
42745	}
42746	return ret, nil
42747	// {
42748	//   "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.",
42749	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/messages",
42750	//   "httpMethod": "GET",
42751	//   "id": "dialogflow.projects.locations.conversations.messages.list",
42752	//   "parameterOrder": [
42753	//     "parent"
42754	//   ],
42755	//   "parameters": {
42756	//     "filter": {
42757	//       "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).",
42758	//       "location": "query",
42759	//       "type": "string"
42760	//     },
42761	//     "pageSize": {
42762	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
42763	//       "format": "int32",
42764	//       "location": "query",
42765	//       "type": "integer"
42766	//     },
42767	//     "pageToken": {
42768	//       "description": "Optional. The next_page_token value returned from a previous list request.",
42769	//       "location": "query",
42770	//       "type": "string"
42771	//     },
42772	//     "parent": {
42773	//       "description": "Required. The name of the conversation to list messages for. Format: `projects//locations//conversations/`",
42774	//       "location": "path",
42775	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+$",
42776	//       "required": true,
42777	//       "type": "string"
42778	//     }
42779	//   },
42780	//   "path": "v2/{+parent}/messages",
42781	//   "response": {
42782	//     "$ref": "GoogleCloudDialogflowV2ListMessagesResponse"
42783	//   },
42784	//   "scopes": [
42785	//     "https://www.googleapis.com/auth/cloud-platform",
42786	//     "https://www.googleapis.com/auth/dialogflow"
42787	//   ]
42788	// }
42789
42790}
42791
42792// Pages invokes f for each page of results.
42793// A non-nil error returned from f will halt the iteration.
42794// The provided context supersedes any context provided to the Context method.
42795func (c *ProjectsLocationsConversationsMessagesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListMessagesResponse) error) error {
42796	c.ctx_ = ctx
42797	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
42798	for {
42799		x, err := c.Do()
42800		if err != nil {
42801			return err
42802		}
42803		if err := f(x); err != nil {
42804			return err
42805		}
42806		if x.NextPageToken == "" {
42807			return nil
42808		}
42809		c.PageToken(x.NextPageToken)
42810	}
42811}
42812
42813// method id "dialogflow.projects.locations.conversations.participants.analyzeContent":
42814
42815type ProjectsLocationsConversationsParticipantsAnalyzeContentCall struct {
42816	s                                            *Service
42817	participant                                  string
42818	googleclouddialogflowv2analyzecontentrequest *GoogleCloudDialogflowV2AnalyzeContentRequest
42819	urlParams_                                   gensupport.URLParams
42820	ctx_                                         context.Context
42821	header_                                      http.Header
42822}
42823
42824// AnalyzeContent: Adds a text (chat, for example), or audio (phone
42825// recording, for example) message from a participant into the
42826// conversation. Note: Always use agent versions for production traffic
42827// sent to virtual agents. See Versions and environments
42828// (https://cloud.google.com/dialogflow/es/docs/agents-versions).
42829//
42830// - participant: The name of the participant this text comes from.
42831//   Format: `projects//locations//conversations//participants/`.
42832func (r *ProjectsLocationsConversationsParticipantsService) AnalyzeContent(participant string, googleclouddialogflowv2analyzecontentrequest *GoogleCloudDialogflowV2AnalyzeContentRequest) *ProjectsLocationsConversationsParticipantsAnalyzeContentCall {
42833	c := &ProjectsLocationsConversationsParticipantsAnalyzeContentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42834	c.participant = participant
42835	c.googleclouddialogflowv2analyzecontentrequest = googleclouddialogflowv2analyzecontentrequest
42836	return c
42837}
42838
42839// Fields allows partial responses to be retrieved. See
42840// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42841// for more information.
42842func (c *ProjectsLocationsConversationsParticipantsAnalyzeContentCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsAnalyzeContentCall {
42843	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42844	return c
42845}
42846
42847// Context sets the context to be used in this call's Do method. Any
42848// pending HTTP request will be aborted if the provided context is
42849// canceled.
42850func (c *ProjectsLocationsConversationsParticipantsAnalyzeContentCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsAnalyzeContentCall {
42851	c.ctx_ = ctx
42852	return c
42853}
42854
42855// Header returns an http.Header that can be modified by the caller to
42856// add HTTP headers to the request.
42857func (c *ProjectsLocationsConversationsParticipantsAnalyzeContentCall) Header() http.Header {
42858	if c.header_ == nil {
42859		c.header_ = make(http.Header)
42860	}
42861	return c.header_
42862}
42863
42864func (c *ProjectsLocationsConversationsParticipantsAnalyzeContentCall) doRequest(alt string) (*http.Response, error) {
42865	reqHeaders := make(http.Header)
42866	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
42867	for k, v := range c.header_ {
42868		reqHeaders[k] = v
42869	}
42870	reqHeaders.Set("User-Agent", c.s.userAgent())
42871	var body io.Reader = nil
42872	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2analyzecontentrequest)
42873	if err != nil {
42874		return nil, err
42875	}
42876	reqHeaders.Set("Content-Type", "application/json")
42877	c.urlParams_.Set("alt", alt)
42878	c.urlParams_.Set("prettyPrint", "false")
42879	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+participant}:analyzeContent")
42880	urls += "?" + c.urlParams_.Encode()
42881	req, err := http.NewRequest("POST", urls, body)
42882	if err != nil {
42883		return nil, err
42884	}
42885	req.Header = reqHeaders
42886	googleapi.Expand(req.URL, map[string]string{
42887		"participant": c.participant,
42888	})
42889	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42890}
42891
42892// Do executes the "dialogflow.projects.locations.conversations.participants.analyzeContent" call.
42893// Exactly one of *GoogleCloudDialogflowV2AnalyzeContentResponse or
42894// error will be non-nil. Any non-2xx status code is an error. Response
42895// headers are in either
42896// *GoogleCloudDialogflowV2AnalyzeContentResponse.ServerResponse.Header
42897// or (if a response was returned at all) in
42898// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
42899// whether the returned error was because http.StatusNotModified was
42900// returned.
42901func (c *ProjectsLocationsConversationsParticipantsAnalyzeContentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2AnalyzeContentResponse, error) {
42902	gensupport.SetOptions(c.urlParams_, opts...)
42903	res, err := c.doRequest("json")
42904	if res != nil && res.StatusCode == http.StatusNotModified {
42905		if res.Body != nil {
42906			res.Body.Close()
42907		}
42908		return nil, &googleapi.Error{
42909			Code:   res.StatusCode,
42910			Header: res.Header,
42911		}
42912	}
42913	if err != nil {
42914		return nil, err
42915	}
42916	defer googleapi.CloseBody(res)
42917	if err := googleapi.CheckResponse(res); err != nil {
42918		return nil, err
42919	}
42920	ret := &GoogleCloudDialogflowV2AnalyzeContentResponse{
42921		ServerResponse: googleapi.ServerResponse{
42922			Header:         res.Header,
42923			HTTPStatusCode: res.StatusCode,
42924		},
42925	}
42926	target := &ret
42927	if err := gensupport.DecodeResponse(target, res); err != nil {
42928		return nil, err
42929	}
42930	return ret, nil
42931	// {
42932	//   "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).",
42933	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants/{participantsId}:analyzeContent",
42934	//   "httpMethod": "POST",
42935	//   "id": "dialogflow.projects.locations.conversations.participants.analyzeContent",
42936	//   "parameterOrder": [
42937	//     "participant"
42938	//   ],
42939	//   "parameters": {
42940	//     "participant": {
42941	//       "description": "Required. The name of the participant this text comes from. Format: `projects//locations//conversations//participants/`.",
42942	//       "location": "path",
42943	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+/participants/[^/]+$",
42944	//       "required": true,
42945	//       "type": "string"
42946	//     }
42947	//   },
42948	//   "path": "v2/{+participant}:analyzeContent",
42949	//   "request": {
42950	//     "$ref": "GoogleCloudDialogflowV2AnalyzeContentRequest"
42951	//   },
42952	//   "response": {
42953	//     "$ref": "GoogleCloudDialogflowV2AnalyzeContentResponse"
42954	//   },
42955	//   "scopes": [
42956	//     "https://www.googleapis.com/auth/cloud-platform",
42957	//     "https://www.googleapis.com/auth/dialogflow"
42958	//   ]
42959	// }
42960
42961}
42962
42963// method id "dialogflow.projects.locations.conversations.participants.create":
42964
42965type ProjectsLocationsConversationsParticipantsCreateCall struct {
42966	s                                  *Service
42967	parentid                           string
42968	googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant
42969	urlParams_                         gensupport.URLParams
42970	ctx_                               context.Context
42971	header_                            http.Header
42972}
42973
42974// Create: Creates a new participant in a conversation.
42975//
42976// - parent: Resource identifier of the conversation adding the
42977//   participant. Format: `projects//locations//conversations/`.
42978func (r *ProjectsLocationsConversationsParticipantsService) Create(parentid string, googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant) *ProjectsLocationsConversationsParticipantsCreateCall {
42979	c := &ProjectsLocationsConversationsParticipantsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42980	c.parentid = parentid
42981	c.googleclouddialogflowv2participant = googleclouddialogflowv2participant
42982	return c
42983}
42984
42985// Fields allows partial responses to be retrieved. See
42986// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42987// for more information.
42988func (c *ProjectsLocationsConversationsParticipantsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsCreateCall {
42989	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42990	return c
42991}
42992
42993// Context sets the context to be used in this call's Do method. Any
42994// pending HTTP request will be aborted if the provided context is
42995// canceled.
42996func (c *ProjectsLocationsConversationsParticipantsCreateCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsCreateCall {
42997	c.ctx_ = ctx
42998	return c
42999}
43000
43001// Header returns an http.Header that can be modified by the caller to
43002// add HTTP headers to the request.
43003func (c *ProjectsLocationsConversationsParticipantsCreateCall) Header() http.Header {
43004	if c.header_ == nil {
43005		c.header_ = make(http.Header)
43006	}
43007	return c.header_
43008}
43009
43010func (c *ProjectsLocationsConversationsParticipantsCreateCall) doRequest(alt string) (*http.Response, error) {
43011	reqHeaders := make(http.Header)
43012	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
43013	for k, v := range c.header_ {
43014		reqHeaders[k] = v
43015	}
43016	reqHeaders.Set("User-Agent", c.s.userAgent())
43017	var body io.Reader = nil
43018	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2participant)
43019	if err != nil {
43020		return nil, err
43021	}
43022	reqHeaders.Set("Content-Type", "application/json")
43023	c.urlParams_.Set("alt", alt)
43024	c.urlParams_.Set("prettyPrint", "false")
43025	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/participants")
43026	urls += "?" + c.urlParams_.Encode()
43027	req, err := http.NewRequest("POST", urls, body)
43028	if err != nil {
43029		return nil, err
43030	}
43031	req.Header = reqHeaders
43032	googleapi.Expand(req.URL, map[string]string{
43033		"parent": c.parentid,
43034	})
43035	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43036}
43037
43038// Do executes the "dialogflow.projects.locations.conversations.participants.create" call.
43039// Exactly one of *GoogleCloudDialogflowV2Participant or error will be
43040// non-nil. Any non-2xx status code is an error. Response headers are in
43041// either *GoogleCloudDialogflowV2Participant.ServerResponse.Header or
43042// (if a response was returned at all) in
43043// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
43044// whether the returned error was because http.StatusNotModified was
43045// returned.
43046func (c *ProjectsLocationsConversationsParticipantsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Participant, error) {
43047	gensupport.SetOptions(c.urlParams_, opts...)
43048	res, err := c.doRequest("json")
43049	if res != nil && res.StatusCode == http.StatusNotModified {
43050		if res.Body != nil {
43051			res.Body.Close()
43052		}
43053		return nil, &googleapi.Error{
43054			Code:   res.StatusCode,
43055			Header: res.Header,
43056		}
43057	}
43058	if err != nil {
43059		return nil, err
43060	}
43061	defer googleapi.CloseBody(res)
43062	if err := googleapi.CheckResponse(res); err != nil {
43063		return nil, err
43064	}
43065	ret := &GoogleCloudDialogflowV2Participant{
43066		ServerResponse: googleapi.ServerResponse{
43067			Header:         res.Header,
43068			HTTPStatusCode: res.StatusCode,
43069		},
43070	}
43071	target := &ret
43072	if err := gensupport.DecodeResponse(target, res); err != nil {
43073		return nil, err
43074	}
43075	return ret, nil
43076	// {
43077	//   "description": "Creates a new participant in a conversation.",
43078	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants",
43079	//   "httpMethod": "POST",
43080	//   "id": "dialogflow.projects.locations.conversations.participants.create",
43081	//   "parameterOrder": [
43082	//     "parent"
43083	//   ],
43084	//   "parameters": {
43085	//     "parent": {
43086	//       "description": "Required. Resource identifier of the conversation adding the participant. Format: `projects//locations//conversations/`.",
43087	//       "location": "path",
43088	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+$",
43089	//       "required": true,
43090	//       "type": "string"
43091	//     }
43092	//   },
43093	//   "path": "v2/{+parent}/participants",
43094	//   "request": {
43095	//     "$ref": "GoogleCloudDialogflowV2Participant"
43096	//   },
43097	//   "response": {
43098	//     "$ref": "GoogleCloudDialogflowV2Participant"
43099	//   },
43100	//   "scopes": [
43101	//     "https://www.googleapis.com/auth/cloud-platform",
43102	//     "https://www.googleapis.com/auth/dialogflow"
43103	//   ]
43104	// }
43105
43106}
43107
43108// method id "dialogflow.projects.locations.conversations.participants.get":
43109
43110type ProjectsLocationsConversationsParticipantsGetCall struct {
43111	s            *Service
43112	name         string
43113	urlParams_   gensupport.URLParams
43114	ifNoneMatch_ string
43115	ctx_         context.Context
43116	header_      http.Header
43117}
43118
43119// Get: Retrieves a conversation participant.
43120//
43121// - name: The name of the participant. Format:
43122//   `projects//locations//conversations//participants/`.
43123func (r *ProjectsLocationsConversationsParticipantsService) Get(name string) *ProjectsLocationsConversationsParticipantsGetCall {
43124	c := &ProjectsLocationsConversationsParticipantsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43125	c.name = name
43126	return c
43127}
43128
43129// Fields allows partial responses to be retrieved. See
43130// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43131// for more information.
43132func (c *ProjectsLocationsConversationsParticipantsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsGetCall {
43133	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43134	return c
43135}
43136
43137// IfNoneMatch sets the optional parameter which makes the operation
43138// fail if the object's ETag matches the given value. This is useful for
43139// getting updates only after the object has changed since the last
43140// request. Use googleapi.IsNotModified to check whether the response
43141// error from Do is the result of In-None-Match.
43142func (c *ProjectsLocationsConversationsParticipantsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationsParticipantsGetCall {
43143	c.ifNoneMatch_ = entityTag
43144	return c
43145}
43146
43147// Context sets the context to be used in this call's Do method. Any
43148// pending HTTP request will be aborted if the provided context is
43149// canceled.
43150func (c *ProjectsLocationsConversationsParticipantsGetCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsGetCall {
43151	c.ctx_ = ctx
43152	return c
43153}
43154
43155// Header returns an http.Header that can be modified by the caller to
43156// add HTTP headers to the request.
43157func (c *ProjectsLocationsConversationsParticipantsGetCall) Header() http.Header {
43158	if c.header_ == nil {
43159		c.header_ = make(http.Header)
43160	}
43161	return c.header_
43162}
43163
43164func (c *ProjectsLocationsConversationsParticipantsGetCall) doRequest(alt string) (*http.Response, error) {
43165	reqHeaders := make(http.Header)
43166	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
43167	for k, v := range c.header_ {
43168		reqHeaders[k] = v
43169	}
43170	reqHeaders.Set("User-Agent", c.s.userAgent())
43171	if c.ifNoneMatch_ != "" {
43172		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43173	}
43174	var body io.Reader = nil
43175	c.urlParams_.Set("alt", alt)
43176	c.urlParams_.Set("prettyPrint", "false")
43177	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
43178	urls += "?" + c.urlParams_.Encode()
43179	req, err := http.NewRequest("GET", urls, body)
43180	if err != nil {
43181		return nil, err
43182	}
43183	req.Header = reqHeaders
43184	googleapi.Expand(req.URL, map[string]string{
43185		"name": c.name,
43186	})
43187	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43188}
43189
43190// Do executes the "dialogflow.projects.locations.conversations.participants.get" call.
43191// Exactly one of *GoogleCloudDialogflowV2Participant or error will be
43192// non-nil. Any non-2xx status code is an error. Response headers are in
43193// either *GoogleCloudDialogflowV2Participant.ServerResponse.Header or
43194// (if a response was returned at all) in
43195// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
43196// whether the returned error was because http.StatusNotModified was
43197// returned.
43198func (c *ProjectsLocationsConversationsParticipantsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Participant, error) {
43199	gensupport.SetOptions(c.urlParams_, opts...)
43200	res, err := c.doRequest("json")
43201	if res != nil && res.StatusCode == http.StatusNotModified {
43202		if res.Body != nil {
43203			res.Body.Close()
43204		}
43205		return nil, &googleapi.Error{
43206			Code:   res.StatusCode,
43207			Header: res.Header,
43208		}
43209	}
43210	if err != nil {
43211		return nil, err
43212	}
43213	defer googleapi.CloseBody(res)
43214	if err := googleapi.CheckResponse(res); err != nil {
43215		return nil, err
43216	}
43217	ret := &GoogleCloudDialogflowV2Participant{
43218		ServerResponse: googleapi.ServerResponse{
43219			Header:         res.Header,
43220			HTTPStatusCode: res.StatusCode,
43221		},
43222	}
43223	target := &ret
43224	if err := gensupport.DecodeResponse(target, res); err != nil {
43225		return nil, err
43226	}
43227	return ret, nil
43228	// {
43229	//   "description": "Retrieves a conversation participant.",
43230	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants/{participantsId}",
43231	//   "httpMethod": "GET",
43232	//   "id": "dialogflow.projects.locations.conversations.participants.get",
43233	//   "parameterOrder": [
43234	//     "name"
43235	//   ],
43236	//   "parameters": {
43237	//     "name": {
43238	//       "description": "Required. The name of the participant. Format: `projects//locations//conversations//participants/`.",
43239	//       "location": "path",
43240	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+/participants/[^/]+$",
43241	//       "required": true,
43242	//       "type": "string"
43243	//     }
43244	//   },
43245	//   "path": "v2/{+name}",
43246	//   "response": {
43247	//     "$ref": "GoogleCloudDialogflowV2Participant"
43248	//   },
43249	//   "scopes": [
43250	//     "https://www.googleapis.com/auth/cloud-platform",
43251	//     "https://www.googleapis.com/auth/dialogflow"
43252	//   ]
43253	// }
43254
43255}
43256
43257// method id "dialogflow.projects.locations.conversations.participants.list":
43258
43259type ProjectsLocationsConversationsParticipantsListCall struct {
43260	s            *Service
43261	parent       string
43262	urlParams_   gensupport.URLParams
43263	ifNoneMatch_ string
43264	ctx_         context.Context
43265	header_      http.Header
43266}
43267
43268// List: Returns the list of all participants in the specified
43269// conversation.
43270//
43271// - parent: The conversation to list all participants from. Format:
43272//   `projects//locations//conversations/`.
43273func (r *ProjectsLocationsConversationsParticipantsService) List(parent string) *ProjectsLocationsConversationsParticipantsListCall {
43274	c := &ProjectsLocationsConversationsParticipantsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43275	c.parent = parent
43276	return c
43277}
43278
43279// PageSize sets the optional parameter "pageSize": The maximum number
43280// of items to return in a single page. By default 100 and at most 1000.
43281func (c *ProjectsLocationsConversationsParticipantsListCall) PageSize(pageSize int64) *ProjectsLocationsConversationsParticipantsListCall {
43282	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
43283	return c
43284}
43285
43286// PageToken sets the optional parameter "pageToken": The
43287// next_page_token value returned from a previous list request.
43288func (c *ProjectsLocationsConversationsParticipantsListCall) PageToken(pageToken string) *ProjectsLocationsConversationsParticipantsListCall {
43289	c.urlParams_.Set("pageToken", pageToken)
43290	return c
43291}
43292
43293// Fields allows partial responses to be retrieved. See
43294// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43295// for more information.
43296func (c *ProjectsLocationsConversationsParticipantsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsListCall {
43297	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43298	return c
43299}
43300
43301// IfNoneMatch sets the optional parameter which makes the operation
43302// fail if the object's ETag matches the given value. This is useful for
43303// getting updates only after the object has changed since the last
43304// request. Use googleapi.IsNotModified to check whether the response
43305// error from Do is the result of In-None-Match.
43306func (c *ProjectsLocationsConversationsParticipantsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationsParticipantsListCall {
43307	c.ifNoneMatch_ = entityTag
43308	return c
43309}
43310
43311// Context sets the context to be used in this call's Do method. Any
43312// pending HTTP request will be aborted if the provided context is
43313// canceled.
43314func (c *ProjectsLocationsConversationsParticipantsListCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsListCall {
43315	c.ctx_ = ctx
43316	return c
43317}
43318
43319// Header returns an http.Header that can be modified by the caller to
43320// add HTTP headers to the request.
43321func (c *ProjectsLocationsConversationsParticipantsListCall) Header() http.Header {
43322	if c.header_ == nil {
43323		c.header_ = make(http.Header)
43324	}
43325	return c.header_
43326}
43327
43328func (c *ProjectsLocationsConversationsParticipantsListCall) doRequest(alt string) (*http.Response, error) {
43329	reqHeaders := make(http.Header)
43330	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
43331	for k, v := range c.header_ {
43332		reqHeaders[k] = v
43333	}
43334	reqHeaders.Set("User-Agent", c.s.userAgent())
43335	if c.ifNoneMatch_ != "" {
43336		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43337	}
43338	var body io.Reader = nil
43339	c.urlParams_.Set("alt", alt)
43340	c.urlParams_.Set("prettyPrint", "false")
43341	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/participants")
43342	urls += "?" + c.urlParams_.Encode()
43343	req, err := http.NewRequest("GET", urls, body)
43344	if err != nil {
43345		return nil, err
43346	}
43347	req.Header = reqHeaders
43348	googleapi.Expand(req.URL, map[string]string{
43349		"parent": c.parent,
43350	})
43351	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43352}
43353
43354// Do executes the "dialogflow.projects.locations.conversations.participants.list" call.
43355// Exactly one of *GoogleCloudDialogflowV2ListParticipantsResponse or
43356// error will be non-nil. Any non-2xx status code is an error. Response
43357// headers are in either
43358// *GoogleCloudDialogflowV2ListParticipantsResponse.ServerResponse.Header
43359//  or (if a response was returned at all) in
43360// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
43361// whether the returned error was because http.StatusNotModified was
43362// returned.
43363func (c *ProjectsLocationsConversationsParticipantsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListParticipantsResponse, error) {
43364	gensupport.SetOptions(c.urlParams_, opts...)
43365	res, err := c.doRequest("json")
43366	if res != nil && res.StatusCode == http.StatusNotModified {
43367		if res.Body != nil {
43368			res.Body.Close()
43369		}
43370		return nil, &googleapi.Error{
43371			Code:   res.StatusCode,
43372			Header: res.Header,
43373		}
43374	}
43375	if err != nil {
43376		return nil, err
43377	}
43378	defer googleapi.CloseBody(res)
43379	if err := googleapi.CheckResponse(res); err != nil {
43380		return nil, err
43381	}
43382	ret := &GoogleCloudDialogflowV2ListParticipantsResponse{
43383		ServerResponse: googleapi.ServerResponse{
43384			Header:         res.Header,
43385			HTTPStatusCode: res.StatusCode,
43386		},
43387	}
43388	target := &ret
43389	if err := gensupport.DecodeResponse(target, res); err != nil {
43390		return nil, err
43391	}
43392	return ret, nil
43393	// {
43394	//   "description": "Returns the list of all participants in the specified conversation.",
43395	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants",
43396	//   "httpMethod": "GET",
43397	//   "id": "dialogflow.projects.locations.conversations.participants.list",
43398	//   "parameterOrder": [
43399	//     "parent"
43400	//   ],
43401	//   "parameters": {
43402	//     "pageSize": {
43403	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
43404	//       "format": "int32",
43405	//       "location": "query",
43406	//       "type": "integer"
43407	//     },
43408	//     "pageToken": {
43409	//       "description": "Optional. The next_page_token value returned from a previous list request.",
43410	//       "location": "query",
43411	//       "type": "string"
43412	//     },
43413	//     "parent": {
43414	//       "description": "Required. The conversation to list all participants from. Format: `projects//locations//conversations/`.",
43415	//       "location": "path",
43416	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+$",
43417	//       "required": true,
43418	//       "type": "string"
43419	//     }
43420	//   },
43421	//   "path": "v2/{+parent}/participants",
43422	//   "response": {
43423	//     "$ref": "GoogleCloudDialogflowV2ListParticipantsResponse"
43424	//   },
43425	//   "scopes": [
43426	//     "https://www.googleapis.com/auth/cloud-platform",
43427	//     "https://www.googleapis.com/auth/dialogflow"
43428	//   ]
43429	// }
43430
43431}
43432
43433// Pages invokes f for each page of results.
43434// A non-nil error returned from f will halt the iteration.
43435// The provided context supersedes any context provided to the Context method.
43436func (c *ProjectsLocationsConversationsParticipantsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListParticipantsResponse) error) error {
43437	c.ctx_ = ctx
43438	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
43439	for {
43440		x, err := c.Do()
43441		if err != nil {
43442			return err
43443		}
43444		if err := f(x); err != nil {
43445			return err
43446		}
43447		if x.NextPageToken == "" {
43448			return nil
43449		}
43450		c.PageToken(x.NextPageToken)
43451	}
43452}
43453
43454// method id "dialogflow.projects.locations.conversations.participants.patch":
43455
43456type ProjectsLocationsConversationsParticipantsPatchCall struct {
43457	s                                  *Service
43458	nameid                             string
43459	googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant
43460	urlParams_                         gensupport.URLParams
43461	ctx_                               context.Context
43462	header_                            http.Header
43463}
43464
43465// Patch: Updates the specified participant.
43466//
43467// - name: Optional. The unique identifier of this participant. Format:
43468//   `projects//locations//conversations//participants/`.
43469func (r *ProjectsLocationsConversationsParticipantsService) Patch(nameid string, googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant) *ProjectsLocationsConversationsParticipantsPatchCall {
43470	c := &ProjectsLocationsConversationsParticipantsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43471	c.nameid = nameid
43472	c.googleclouddialogflowv2participant = googleclouddialogflowv2participant
43473	return c
43474}
43475
43476// UpdateMask sets the optional parameter "updateMask": Required. The
43477// mask to specify which fields to update.
43478func (c *ProjectsLocationsConversationsParticipantsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsConversationsParticipantsPatchCall {
43479	c.urlParams_.Set("updateMask", updateMask)
43480	return c
43481}
43482
43483// Fields allows partial responses to be retrieved. See
43484// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43485// for more information.
43486func (c *ProjectsLocationsConversationsParticipantsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsPatchCall {
43487	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43488	return c
43489}
43490
43491// Context sets the context to be used in this call's Do method. Any
43492// pending HTTP request will be aborted if the provided context is
43493// canceled.
43494func (c *ProjectsLocationsConversationsParticipantsPatchCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsPatchCall {
43495	c.ctx_ = ctx
43496	return c
43497}
43498
43499// Header returns an http.Header that can be modified by the caller to
43500// add HTTP headers to the request.
43501func (c *ProjectsLocationsConversationsParticipantsPatchCall) Header() http.Header {
43502	if c.header_ == nil {
43503		c.header_ = make(http.Header)
43504	}
43505	return c.header_
43506}
43507
43508func (c *ProjectsLocationsConversationsParticipantsPatchCall) doRequest(alt string) (*http.Response, error) {
43509	reqHeaders := make(http.Header)
43510	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
43511	for k, v := range c.header_ {
43512		reqHeaders[k] = v
43513	}
43514	reqHeaders.Set("User-Agent", c.s.userAgent())
43515	var body io.Reader = nil
43516	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2participant)
43517	if err != nil {
43518		return nil, err
43519	}
43520	reqHeaders.Set("Content-Type", "application/json")
43521	c.urlParams_.Set("alt", alt)
43522	c.urlParams_.Set("prettyPrint", "false")
43523	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
43524	urls += "?" + c.urlParams_.Encode()
43525	req, err := http.NewRequest("PATCH", urls, body)
43526	if err != nil {
43527		return nil, err
43528	}
43529	req.Header = reqHeaders
43530	googleapi.Expand(req.URL, map[string]string{
43531		"name": c.nameid,
43532	})
43533	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43534}
43535
43536// Do executes the "dialogflow.projects.locations.conversations.participants.patch" call.
43537// Exactly one of *GoogleCloudDialogflowV2Participant or error will be
43538// non-nil. Any non-2xx status code is an error. Response headers are in
43539// either *GoogleCloudDialogflowV2Participant.ServerResponse.Header or
43540// (if a response was returned at all) in
43541// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
43542// whether the returned error was because http.StatusNotModified was
43543// returned.
43544func (c *ProjectsLocationsConversationsParticipantsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Participant, error) {
43545	gensupport.SetOptions(c.urlParams_, opts...)
43546	res, err := c.doRequest("json")
43547	if res != nil && res.StatusCode == http.StatusNotModified {
43548		if res.Body != nil {
43549			res.Body.Close()
43550		}
43551		return nil, &googleapi.Error{
43552			Code:   res.StatusCode,
43553			Header: res.Header,
43554		}
43555	}
43556	if err != nil {
43557		return nil, err
43558	}
43559	defer googleapi.CloseBody(res)
43560	if err := googleapi.CheckResponse(res); err != nil {
43561		return nil, err
43562	}
43563	ret := &GoogleCloudDialogflowV2Participant{
43564		ServerResponse: googleapi.ServerResponse{
43565			Header:         res.Header,
43566			HTTPStatusCode: res.StatusCode,
43567		},
43568	}
43569	target := &ret
43570	if err := gensupport.DecodeResponse(target, res); err != nil {
43571		return nil, err
43572	}
43573	return ret, nil
43574	// {
43575	//   "description": "Updates the specified participant.",
43576	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants/{participantsId}",
43577	//   "httpMethod": "PATCH",
43578	//   "id": "dialogflow.projects.locations.conversations.participants.patch",
43579	//   "parameterOrder": [
43580	//     "name"
43581	//   ],
43582	//   "parameters": {
43583	//     "name": {
43584	//       "description": "Optional. The unique identifier of this participant. Format: `projects//locations//conversations//participants/`.",
43585	//       "location": "path",
43586	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+/participants/[^/]+$",
43587	//       "required": true,
43588	//       "type": "string"
43589	//     },
43590	//     "updateMask": {
43591	//       "description": "Required. The mask to specify which fields to update.",
43592	//       "format": "google-fieldmask",
43593	//       "location": "query",
43594	//       "type": "string"
43595	//     }
43596	//   },
43597	//   "path": "v2/{+name}",
43598	//   "request": {
43599	//     "$ref": "GoogleCloudDialogflowV2Participant"
43600	//   },
43601	//   "response": {
43602	//     "$ref": "GoogleCloudDialogflowV2Participant"
43603	//   },
43604	//   "scopes": [
43605	//     "https://www.googleapis.com/auth/cloud-platform",
43606	//     "https://www.googleapis.com/auth/dialogflow"
43607	//   ]
43608	// }
43609
43610}
43611
43612// method id "dialogflow.projects.locations.conversations.participants.suggestions.suggestArticles":
43613
43614type ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall struct {
43615	s                                             *Service
43616	parent                                        string
43617	googleclouddialogflowv2suggestarticlesrequest *GoogleCloudDialogflowV2SuggestArticlesRequest
43618	urlParams_                                    gensupport.URLParams
43619	ctx_                                          context.Context
43620	header_                                       http.Header
43621}
43622
43623// SuggestArticles: Gets suggested articles for a participant based on
43624// specific historical messages.
43625//
43626// - parent: The name of the participant to fetch suggestion for.
43627//   Format: `projects//locations//conversations//participants/`.
43628func (r *ProjectsLocationsConversationsParticipantsSuggestionsService) SuggestArticles(parent string, googleclouddialogflowv2suggestarticlesrequest *GoogleCloudDialogflowV2SuggestArticlesRequest) *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall {
43629	c := &ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43630	c.parent = parent
43631	c.googleclouddialogflowv2suggestarticlesrequest = googleclouddialogflowv2suggestarticlesrequest
43632	return c
43633}
43634
43635// Fields allows partial responses to be retrieved. See
43636// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43637// for more information.
43638func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall {
43639	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43640	return c
43641}
43642
43643// Context sets the context to be used in this call's Do method. Any
43644// pending HTTP request will be aborted if the provided context is
43645// canceled.
43646func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall {
43647	c.ctx_ = ctx
43648	return c
43649}
43650
43651// Header returns an http.Header that can be modified by the caller to
43652// add HTTP headers to the request.
43653func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall) Header() http.Header {
43654	if c.header_ == nil {
43655		c.header_ = make(http.Header)
43656	}
43657	return c.header_
43658}
43659
43660func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall) doRequest(alt string) (*http.Response, error) {
43661	reqHeaders := make(http.Header)
43662	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
43663	for k, v := range c.header_ {
43664		reqHeaders[k] = v
43665	}
43666	reqHeaders.Set("User-Agent", c.s.userAgent())
43667	var body io.Reader = nil
43668	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2suggestarticlesrequest)
43669	if err != nil {
43670		return nil, err
43671	}
43672	reqHeaders.Set("Content-Type", "application/json")
43673	c.urlParams_.Set("alt", alt)
43674	c.urlParams_.Set("prettyPrint", "false")
43675	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/suggestions:suggestArticles")
43676	urls += "?" + c.urlParams_.Encode()
43677	req, err := http.NewRequest("POST", urls, body)
43678	if err != nil {
43679		return nil, err
43680	}
43681	req.Header = reqHeaders
43682	googleapi.Expand(req.URL, map[string]string{
43683		"parent": c.parent,
43684	})
43685	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43686}
43687
43688// Do executes the "dialogflow.projects.locations.conversations.participants.suggestions.suggestArticles" call.
43689// Exactly one of *GoogleCloudDialogflowV2SuggestArticlesResponse or
43690// error will be non-nil. Any non-2xx status code is an error. Response
43691// headers are in either
43692// *GoogleCloudDialogflowV2SuggestArticlesResponse.ServerResponse.Header
43693// or (if a response was returned at all) in
43694// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
43695// whether the returned error was because http.StatusNotModified was
43696// returned.
43697func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SuggestArticlesResponse, error) {
43698	gensupport.SetOptions(c.urlParams_, opts...)
43699	res, err := c.doRequest("json")
43700	if res != nil && res.StatusCode == http.StatusNotModified {
43701		if res.Body != nil {
43702			res.Body.Close()
43703		}
43704		return nil, &googleapi.Error{
43705			Code:   res.StatusCode,
43706			Header: res.Header,
43707		}
43708	}
43709	if err != nil {
43710		return nil, err
43711	}
43712	defer googleapi.CloseBody(res)
43713	if err := googleapi.CheckResponse(res); err != nil {
43714		return nil, err
43715	}
43716	ret := &GoogleCloudDialogflowV2SuggestArticlesResponse{
43717		ServerResponse: googleapi.ServerResponse{
43718			Header:         res.Header,
43719			HTTPStatusCode: res.StatusCode,
43720		},
43721	}
43722	target := &ret
43723	if err := gensupport.DecodeResponse(target, res); err != nil {
43724		return nil, err
43725	}
43726	return ret, nil
43727	// {
43728	//   "description": "Gets suggested articles for a participant based on specific historical messages.",
43729	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants/{participantsId}/suggestions:suggestArticles",
43730	//   "httpMethod": "POST",
43731	//   "id": "dialogflow.projects.locations.conversations.participants.suggestions.suggestArticles",
43732	//   "parameterOrder": [
43733	//     "parent"
43734	//   ],
43735	//   "parameters": {
43736	//     "parent": {
43737	//       "description": "Required. The name of the participant to fetch suggestion for. Format: `projects//locations//conversations//participants/`.",
43738	//       "location": "path",
43739	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+/participants/[^/]+$",
43740	//       "required": true,
43741	//       "type": "string"
43742	//     }
43743	//   },
43744	//   "path": "v2/{+parent}/suggestions:suggestArticles",
43745	//   "request": {
43746	//     "$ref": "GoogleCloudDialogflowV2SuggestArticlesRequest"
43747	//   },
43748	//   "response": {
43749	//     "$ref": "GoogleCloudDialogflowV2SuggestArticlesResponse"
43750	//   },
43751	//   "scopes": [
43752	//     "https://www.googleapis.com/auth/cloud-platform",
43753	//     "https://www.googleapis.com/auth/dialogflow"
43754	//   ]
43755	// }
43756
43757}
43758
43759// method id "dialogflow.projects.locations.conversations.participants.suggestions.suggestFaqAnswers":
43760
43761type ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall struct {
43762	s                                               *Service
43763	parent                                          string
43764	googleclouddialogflowv2suggestfaqanswersrequest *GoogleCloudDialogflowV2SuggestFaqAnswersRequest
43765	urlParams_                                      gensupport.URLParams
43766	ctx_                                            context.Context
43767	header_                                         http.Header
43768}
43769
43770// SuggestFaqAnswers: Gets suggested faq answers for a participant based
43771// on specific historical messages.
43772//
43773// - parent: The name of the participant to fetch suggestion for.
43774//   Format: `projects//locations//conversations//participants/`.
43775func (r *ProjectsLocationsConversationsParticipantsSuggestionsService) SuggestFaqAnswers(parent string, googleclouddialogflowv2suggestfaqanswersrequest *GoogleCloudDialogflowV2SuggestFaqAnswersRequest) *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall {
43776	c := &ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43777	c.parent = parent
43778	c.googleclouddialogflowv2suggestfaqanswersrequest = googleclouddialogflowv2suggestfaqanswersrequest
43779	return c
43780}
43781
43782// Fields allows partial responses to be retrieved. See
43783// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43784// for more information.
43785func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall {
43786	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43787	return c
43788}
43789
43790// Context sets the context to be used in this call's Do method. Any
43791// pending HTTP request will be aborted if the provided context is
43792// canceled.
43793func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall {
43794	c.ctx_ = ctx
43795	return c
43796}
43797
43798// Header returns an http.Header that can be modified by the caller to
43799// add HTTP headers to the request.
43800func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Header() http.Header {
43801	if c.header_ == nil {
43802		c.header_ = make(http.Header)
43803	}
43804	return c.header_
43805}
43806
43807func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) doRequest(alt string) (*http.Response, error) {
43808	reqHeaders := make(http.Header)
43809	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
43810	for k, v := range c.header_ {
43811		reqHeaders[k] = v
43812	}
43813	reqHeaders.Set("User-Agent", c.s.userAgent())
43814	var body io.Reader = nil
43815	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2suggestfaqanswersrequest)
43816	if err != nil {
43817		return nil, err
43818	}
43819	reqHeaders.Set("Content-Type", "application/json")
43820	c.urlParams_.Set("alt", alt)
43821	c.urlParams_.Set("prettyPrint", "false")
43822	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/suggestions:suggestFaqAnswers")
43823	urls += "?" + c.urlParams_.Encode()
43824	req, err := http.NewRequest("POST", urls, body)
43825	if err != nil {
43826		return nil, err
43827	}
43828	req.Header = reqHeaders
43829	googleapi.Expand(req.URL, map[string]string{
43830		"parent": c.parent,
43831	})
43832	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43833}
43834
43835// Do executes the "dialogflow.projects.locations.conversations.participants.suggestions.suggestFaqAnswers" call.
43836// Exactly one of *GoogleCloudDialogflowV2SuggestFaqAnswersResponse or
43837// error will be non-nil. Any non-2xx status code is an error. Response
43838// headers are in either
43839// *GoogleCloudDialogflowV2SuggestFaqAnswersResponse.ServerResponse.Heade
43840// r or (if a response was returned at all) in
43841// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
43842// whether the returned error was because http.StatusNotModified was
43843// returned.
43844func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SuggestFaqAnswersResponse, error) {
43845	gensupport.SetOptions(c.urlParams_, opts...)
43846	res, err := c.doRequest("json")
43847	if res != nil && res.StatusCode == http.StatusNotModified {
43848		if res.Body != nil {
43849			res.Body.Close()
43850		}
43851		return nil, &googleapi.Error{
43852			Code:   res.StatusCode,
43853			Header: res.Header,
43854		}
43855	}
43856	if err != nil {
43857		return nil, err
43858	}
43859	defer googleapi.CloseBody(res)
43860	if err := googleapi.CheckResponse(res); err != nil {
43861		return nil, err
43862	}
43863	ret := &GoogleCloudDialogflowV2SuggestFaqAnswersResponse{
43864		ServerResponse: googleapi.ServerResponse{
43865			Header:         res.Header,
43866			HTTPStatusCode: res.StatusCode,
43867		},
43868	}
43869	target := &ret
43870	if err := gensupport.DecodeResponse(target, res); err != nil {
43871		return nil, err
43872	}
43873	return ret, nil
43874	// {
43875	//   "description": "Gets suggested faq answers for a participant based on specific historical messages.",
43876	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants/{participantsId}/suggestions:suggestFaqAnswers",
43877	//   "httpMethod": "POST",
43878	//   "id": "dialogflow.projects.locations.conversations.participants.suggestions.suggestFaqAnswers",
43879	//   "parameterOrder": [
43880	//     "parent"
43881	//   ],
43882	//   "parameters": {
43883	//     "parent": {
43884	//       "description": "Required. The name of the participant to fetch suggestion for. Format: `projects//locations//conversations//participants/`.",
43885	//       "location": "path",
43886	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+/participants/[^/]+$",
43887	//       "required": true,
43888	//       "type": "string"
43889	//     }
43890	//   },
43891	//   "path": "v2/{+parent}/suggestions:suggestFaqAnswers",
43892	//   "request": {
43893	//     "$ref": "GoogleCloudDialogflowV2SuggestFaqAnswersRequest"
43894	//   },
43895	//   "response": {
43896	//     "$ref": "GoogleCloudDialogflowV2SuggestFaqAnswersResponse"
43897	//   },
43898	//   "scopes": [
43899	//     "https://www.googleapis.com/auth/cloud-platform",
43900	//     "https://www.googleapis.com/auth/dialogflow"
43901	//   ]
43902	// }
43903
43904}
43905
43906// method id "dialogflow.projects.locations.knowledgeBases.create":
43907
43908type ProjectsLocationsKnowledgeBasesCreateCall struct {
43909	s                                    *Service
43910	parent                               string
43911	googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase
43912	urlParams_                           gensupport.URLParams
43913	ctx_                                 context.Context
43914	header_                              http.Header
43915}
43916
43917// Create: Creates a knowledge base.
43918//
43919// - parent: The project to create a knowledge base for. Format:
43920//   `projects//locations/`.
43921func (r *ProjectsLocationsKnowledgeBasesService) Create(parent string, googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase) *ProjectsLocationsKnowledgeBasesCreateCall {
43922	c := &ProjectsLocationsKnowledgeBasesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43923	c.parent = parent
43924	c.googleclouddialogflowv2knowledgebase = googleclouddialogflowv2knowledgebase
43925	return c
43926}
43927
43928// Fields allows partial responses to be retrieved. See
43929// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43930// for more information.
43931func (c *ProjectsLocationsKnowledgeBasesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesCreateCall {
43932	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43933	return c
43934}
43935
43936// Context sets the context to be used in this call's Do method. Any
43937// pending HTTP request will be aborted if the provided context is
43938// canceled.
43939func (c *ProjectsLocationsKnowledgeBasesCreateCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesCreateCall {
43940	c.ctx_ = ctx
43941	return c
43942}
43943
43944// Header returns an http.Header that can be modified by the caller to
43945// add HTTP headers to the request.
43946func (c *ProjectsLocationsKnowledgeBasesCreateCall) Header() http.Header {
43947	if c.header_ == nil {
43948		c.header_ = make(http.Header)
43949	}
43950	return c.header_
43951}
43952
43953func (c *ProjectsLocationsKnowledgeBasesCreateCall) doRequest(alt string) (*http.Response, error) {
43954	reqHeaders := make(http.Header)
43955	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
43956	for k, v := range c.header_ {
43957		reqHeaders[k] = v
43958	}
43959	reqHeaders.Set("User-Agent", c.s.userAgent())
43960	var body io.Reader = nil
43961	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2knowledgebase)
43962	if err != nil {
43963		return nil, err
43964	}
43965	reqHeaders.Set("Content-Type", "application/json")
43966	c.urlParams_.Set("alt", alt)
43967	c.urlParams_.Set("prettyPrint", "false")
43968	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/knowledgeBases")
43969	urls += "?" + c.urlParams_.Encode()
43970	req, err := http.NewRequest("POST", urls, body)
43971	if err != nil {
43972		return nil, err
43973	}
43974	req.Header = reqHeaders
43975	googleapi.Expand(req.URL, map[string]string{
43976		"parent": c.parent,
43977	})
43978	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43979}
43980
43981// Do executes the "dialogflow.projects.locations.knowledgeBases.create" call.
43982// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
43983// non-nil. Any non-2xx status code is an error. Response headers are in
43984// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
43985// (if a response was returned at all) in
43986// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
43987// whether the returned error was because http.StatusNotModified was
43988// returned.
43989func (c *ProjectsLocationsKnowledgeBasesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
43990	gensupport.SetOptions(c.urlParams_, opts...)
43991	res, err := c.doRequest("json")
43992	if res != nil && res.StatusCode == http.StatusNotModified {
43993		if res.Body != nil {
43994			res.Body.Close()
43995		}
43996		return nil, &googleapi.Error{
43997			Code:   res.StatusCode,
43998			Header: res.Header,
43999		}
44000	}
44001	if err != nil {
44002		return nil, err
44003	}
44004	defer googleapi.CloseBody(res)
44005	if err := googleapi.CheckResponse(res); err != nil {
44006		return nil, err
44007	}
44008	ret := &GoogleCloudDialogflowV2KnowledgeBase{
44009		ServerResponse: googleapi.ServerResponse{
44010			Header:         res.Header,
44011			HTTPStatusCode: res.StatusCode,
44012		},
44013	}
44014	target := &ret
44015	if err := gensupport.DecodeResponse(target, res); err != nil {
44016		return nil, err
44017	}
44018	return ret, nil
44019	// {
44020	//   "description": "Creates a knowledge base.",
44021	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases",
44022	//   "httpMethod": "POST",
44023	//   "id": "dialogflow.projects.locations.knowledgeBases.create",
44024	//   "parameterOrder": [
44025	//     "parent"
44026	//   ],
44027	//   "parameters": {
44028	//     "parent": {
44029	//       "description": "Required. The project to create a knowledge base for. Format: `projects//locations/`.",
44030	//       "location": "path",
44031	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
44032	//       "required": true,
44033	//       "type": "string"
44034	//     }
44035	//   },
44036	//   "path": "v2/{+parent}/knowledgeBases",
44037	//   "request": {
44038	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
44039	//   },
44040	//   "response": {
44041	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
44042	//   },
44043	//   "scopes": [
44044	//     "https://www.googleapis.com/auth/cloud-platform",
44045	//     "https://www.googleapis.com/auth/dialogflow"
44046	//   ]
44047	// }
44048
44049}
44050
44051// method id "dialogflow.projects.locations.knowledgeBases.delete":
44052
44053type ProjectsLocationsKnowledgeBasesDeleteCall struct {
44054	s          *Service
44055	name       string
44056	urlParams_ gensupport.URLParams
44057	ctx_       context.Context
44058	header_    http.Header
44059}
44060
44061// Delete: Deletes the specified knowledge base.
44062//
44063// - name: The name of the knowledge base to delete. Format:
44064//   `projects//locations//knowledgeBases/`.
44065func (r *ProjectsLocationsKnowledgeBasesService) Delete(name string) *ProjectsLocationsKnowledgeBasesDeleteCall {
44066	c := &ProjectsLocationsKnowledgeBasesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44067	c.name = name
44068	return c
44069}
44070
44071// Force sets the optional parameter "force": Force deletes the
44072// knowledge base. When set to true, any documents in the knowledge base
44073// are also deleted.
44074func (c *ProjectsLocationsKnowledgeBasesDeleteCall) Force(force bool) *ProjectsLocationsKnowledgeBasesDeleteCall {
44075	c.urlParams_.Set("force", fmt.Sprint(force))
44076	return c
44077}
44078
44079// Fields allows partial responses to be retrieved. See
44080// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44081// for more information.
44082func (c *ProjectsLocationsKnowledgeBasesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDeleteCall {
44083	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44084	return c
44085}
44086
44087// Context sets the context to be used in this call's Do method. Any
44088// pending HTTP request will be aborted if the provided context is
44089// canceled.
44090func (c *ProjectsLocationsKnowledgeBasesDeleteCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDeleteCall {
44091	c.ctx_ = ctx
44092	return c
44093}
44094
44095// Header returns an http.Header that can be modified by the caller to
44096// add HTTP headers to the request.
44097func (c *ProjectsLocationsKnowledgeBasesDeleteCall) Header() http.Header {
44098	if c.header_ == nil {
44099		c.header_ = make(http.Header)
44100	}
44101	return c.header_
44102}
44103
44104func (c *ProjectsLocationsKnowledgeBasesDeleteCall) doRequest(alt string) (*http.Response, error) {
44105	reqHeaders := make(http.Header)
44106	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
44107	for k, v := range c.header_ {
44108		reqHeaders[k] = v
44109	}
44110	reqHeaders.Set("User-Agent", c.s.userAgent())
44111	var body io.Reader = nil
44112	c.urlParams_.Set("alt", alt)
44113	c.urlParams_.Set("prettyPrint", "false")
44114	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
44115	urls += "?" + c.urlParams_.Encode()
44116	req, err := http.NewRequest("DELETE", urls, body)
44117	if err != nil {
44118		return nil, err
44119	}
44120	req.Header = reqHeaders
44121	googleapi.Expand(req.URL, map[string]string{
44122		"name": c.name,
44123	})
44124	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44125}
44126
44127// Do executes the "dialogflow.projects.locations.knowledgeBases.delete" call.
44128// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
44129// non-2xx status code is an error. Response headers are in either
44130// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
44131// returned at all) in error.(*googleapi.Error).Header. Use
44132// googleapi.IsNotModified to check whether the returned error was
44133// because http.StatusNotModified was returned.
44134func (c *ProjectsLocationsKnowledgeBasesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
44135	gensupport.SetOptions(c.urlParams_, opts...)
44136	res, err := c.doRequest("json")
44137	if res != nil && res.StatusCode == http.StatusNotModified {
44138		if res.Body != nil {
44139			res.Body.Close()
44140		}
44141		return nil, &googleapi.Error{
44142			Code:   res.StatusCode,
44143			Header: res.Header,
44144		}
44145	}
44146	if err != nil {
44147		return nil, err
44148	}
44149	defer googleapi.CloseBody(res)
44150	if err := googleapi.CheckResponse(res); err != nil {
44151		return nil, err
44152	}
44153	ret := &GoogleProtobufEmpty{
44154		ServerResponse: googleapi.ServerResponse{
44155			Header:         res.Header,
44156			HTTPStatusCode: res.StatusCode,
44157		},
44158	}
44159	target := &ret
44160	if err := gensupport.DecodeResponse(target, res); err != nil {
44161		return nil, err
44162	}
44163	return ret, nil
44164	// {
44165	//   "description": "Deletes the specified knowledge base.",
44166	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}",
44167	//   "httpMethod": "DELETE",
44168	//   "id": "dialogflow.projects.locations.knowledgeBases.delete",
44169	//   "parameterOrder": [
44170	//     "name"
44171	//   ],
44172	//   "parameters": {
44173	//     "force": {
44174	//       "description": "Optional. Force deletes the knowledge base. When set to true, any documents in the knowledge base are also deleted.",
44175	//       "location": "query",
44176	//       "type": "boolean"
44177	//     },
44178	//     "name": {
44179	//       "description": "Required. The name of the knowledge base to delete. Format: `projects//locations//knowledgeBases/`.",
44180	//       "location": "path",
44181	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+$",
44182	//       "required": true,
44183	//       "type": "string"
44184	//     }
44185	//   },
44186	//   "path": "v2/{+name}",
44187	//   "response": {
44188	//     "$ref": "GoogleProtobufEmpty"
44189	//   },
44190	//   "scopes": [
44191	//     "https://www.googleapis.com/auth/cloud-platform",
44192	//     "https://www.googleapis.com/auth/dialogflow"
44193	//   ]
44194	// }
44195
44196}
44197
44198// method id "dialogflow.projects.locations.knowledgeBases.get":
44199
44200type ProjectsLocationsKnowledgeBasesGetCall struct {
44201	s            *Service
44202	name         string
44203	urlParams_   gensupport.URLParams
44204	ifNoneMatch_ string
44205	ctx_         context.Context
44206	header_      http.Header
44207}
44208
44209// Get: Retrieves the specified knowledge base.
44210//
44211// - name: The name of the knowledge base to retrieve. Format
44212//   `projects//locations//knowledgeBases/`.
44213func (r *ProjectsLocationsKnowledgeBasesService) Get(name string) *ProjectsLocationsKnowledgeBasesGetCall {
44214	c := &ProjectsLocationsKnowledgeBasesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44215	c.name = name
44216	return c
44217}
44218
44219// Fields allows partial responses to be retrieved. See
44220// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44221// for more information.
44222func (c *ProjectsLocationsKnowledgeBasesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesGetCall {
44223	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44224	return c
44225}
44226
44227// IfNoneMatch sets the optional parameter which makes the operation
44228// fail if the object's ETag matches the given value. This is useful for
44229// getting updates only after the object has changed since the last
44230// request. Use googleapi.IsNotModified to check whether the response
44231// error from Do is the result of In-None-Match.
44232func (c *ProjectsLocationsKnowledgeBasesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsKnowledgeBasesGetCall {
44233	c.ifNoneMatch_ = entityTag
44234	return c
44235}
44236
44237// Context sets the context to be used in this call's Do method. Any
44238// pending HTTP request will be aborted if the provided context is
44239// canceled.
44240func (c *ProjectsLocationsKnowledgeBasesGetCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesGetCall {
44241	c.ctx_ = ctx
44242	return c
44243}
44244
44245// Header returns an http.Header that can be modified by the caller to
44246// add HTTP headers to the request.
44247func (c *ProjectsLocationsKnowledgeBasesGetCall) Header() http.Header {
44248	if c.header_ == nil {
44249		c.header_ = make(http.Header)
44250	}
44251	return c.header_
44252}
44253
44254func (c *ProjectsLocationsKnowledgeBasesGetCall) doRequest(alt string) (*http.Response, error) {
44255	reqHeaders := make(http.Header)
44256	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
44257	for k, v := range c.header_ {
44258		reqHeaders[k] = v
44259	}
44260	reqHeaders.Set("User-Agent", c.s.userAgent())
44261	if c.ifNoneMatch_ != "" {
44262		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44263	}
44264	var body io.Reader = nil
44265	c.urlParams_.Set("alt", alt)
44266	c.urlParams_.Set("prettyPrint", "false")
44267	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
44268	urls += "?" + c.urlParams_.Encode()
44269	req, err := http.NewRequest("GET", urls, body)
44270	if err != nil {
44271		return nil, err
44272	}
44273	req.Header = reqHeaders
44274	googleapi.Expand(req.URL, map[string]string{
44275		"name": c.name,
44276	})
44277	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44278}
44279
44280// Do executes the "dialogflow.projects.locations.knowledgeBases.get" call.
44281// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
44282// non-nil. Any non-2xx status code is an error. Response headers are in
44283// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
44284// (if a response was returned at all) in
44285// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
44286// whether the returned error was because http.StatusNotModified was
44287// returned.
44288func (c *ProjectsLocationsKnowledgeBasesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
44289	gensupport.SetOptions(c.urlParams_, opts...)
44290	res, err := c.doRequest("json")
44291	if res != nil && res.StatusCode == http.StatusNotModified {
44292		if res.Body != nil {
44293			res.Body.Close()
44294		}
44295		return nil, &googleapi.Error{
44296			Code:   res.StatusCode,
44297			Header: res.Header,
44298		}
44299	}
44300	if err != nil {
44301		return nil, err
44302	}
44303	defer googleapi.CloseBody(res)
44304	if err := googleapi.CheckResponse(res); err != nil {
44305		return nil, err
44306	}
44307	ret := &GoogleCloudDialogflowV2KnowledgeBase{
44308		ServerResponse: googleapi.ServerResponse{
44309			Header:         res.Header,
44310			HTTPStatusCode: res.StatusCode,
44311		},
44312	}
44313	target := &ret
44314	if err := gensupport.DecodeResponse(target, res); err != nil {
44315		return nil, err
44316	}
44317	return ret, nil
44318	// {
44319	//   "description": "Retrieves the specified knowledge base.",
44320	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}",
44321	//   "httpMethod": "GET",
44322	//   "id": "dialogflow.projects.locations.knowledgeBases.get",
44323	//   "parameterOrder": [
44324	//     "name"
44325	//   ],
44326	//   "parameters": {
44327	//     "name": {
44328	//       "description": "Required. The name of the knowledge base to retrieve. Format `projects//locations//knowledgeBases/`.",
44329	//       "location": "path",
44330	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+$",
44331	//       "required": true,
44332	//       "type": "string"
44333	//     }
44334	//   },
44335	//   "path": "v2/{+name}",
44336	//   "response": {
44337	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
44338	//   },
44339	//   "scopes": [
44340	//     "https://www.googleapis.com/auth/cloud-platform",
44341	//     "https://www.googleapis.com/auth/dialogflow"
44342	//   ]
44343	// }
44344
44345}
44346
44347// method id "dialogflow.projects.locations.knowledgeBases.list":
44348
44349type ProjectsLocationsKnowledgeBasesListCall struct {
44350	s            *Service
44351	parent       string
44352	urlParams_   gensupport.URLParams
44353	ifNoneMatch_ string
44354	ctx_         context.Context
44355	header_      http.Header
44356}
44357
44358// List: Returns the list of all knowledge bases of the specified agent.
44359//
44360// - parent: The project to list of knowledge bases for. Format:
44361//   `projects//locations/`.
44362func (r *ProjectsLocationsKnowledgeBasesService) List(parent string) *ProjectsLocationsKnowledgeBasesListCall {
44363	c := &ProjectsLocationsKnowledgeBasesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44364	c.parent = parent
44365	return c
44366}
44367
44368// PageSize sets the optional parameter "pageSize": The maximum number
44369// of items to return in a single page. By default 10 and at most 100.
44370func (c *ProjectsLocationsKnowledgeBasesListCall) PageSize(pageSize int64) *ProjectsLocationsKnowledgeBasesListCall {
44371	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
44372	return c
44373}
44374
44375// PageToken sets the optional parameter "pageToken": The
44376// next_page_token value returned from a previous list request.
44377func (c *ProjectsLocationsKnowledgeBasesListCall) PageToken(pageToken string) *ProjectsLocationsKnowledgeBasesListCall {
44378	c.urlParams_.Set("pageToken", pageToken)
44379	return c
44380}
44381
44382// Fields allows partial responses to be retrieved. See
44383// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44384// for more information.
44385func (c *ProjectsLocationsKnowledgeBasesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesListCall {
44386	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44387	return c
44388}
44389
44390// IfNoneMatch sets the optional parameter which makes the operation
44391// fail if the object's ETag matches the given value. This is useful for
44392// getting updates only after the object has changed since the last
44393// request. Use googleapi.IsNotModified to check whether the response
44394// error from Do is the result of In-None-Match.
44395func (c *ProjectsLocationsKnowledgeBasesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsKnowledgeBasesListCall {
44396	c.ifNoneMatch_ = entityTag
44397	return c
44398}
44399
44400// Context sets the context to be used in this call's Do method. Any
44401// pending HTTP request will be aborted if the provided context is
44402// canceled.
44403func (c *ProjectsLocationsKnowledgeBasesListCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesListCall {
44404	c.ctx_ = ctx
44405	return c
44406}
44407
44408// Header returns an http.Header that can be modified by the caller to
44409// add HTTP headers to the request.
44410func (c *ProjectsLocationsKnowledgeBasesListCall) Header() http.Header {
44411	if c.header_ == nil {
44412		c.header_ = make(http.Header)
44413	}
44414	return c.header_
44415}
44416
44417func (c *ProjectsLocationsKnowledgeBasesListCall) doRequest(alt string) (*http.Response, error) {
44418	reqHeaders := make(http.Header)
44419	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
44420	for k, v := range c.header_ {
44421		reqHeaders[k] = v
44422	}
44423	reqHeaders.Set("User-Agent", c.s.userAgent())
44424	if c.ifNoneMatch_ != "" {
44425		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44426	}
44427	var body io.Reader = nil
44428	c.urlParams_.Set("alt", alt)
44429	c.urlParams_.Set("prettyPrint", "false")
44430	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/knowledgeBases")
44431	urls += "?" + c.urlParams_.Encode()
44432	req, err := http.NewRequest("GET", urls, body)
44433	if err != nil {
44434		return nil, err
44435	}
44436	req.Header = reqHeaders
44437	googleapi.Expand(req.URL, map[string]string{
44438		"parent": c.parent,
44439	})
44440	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44441}
44442
44443// Do executes the "dialogflow.projects.locations.knowledgeBases.list" call.
44444// Exactly one of *GoogleCloudDialogflowV2ListKnowledgeBasesResponse or
44445// error will be non-nil. Any non-2xx status code is an error. Response
44446// headers are in either
44447// *GoogleCloudDialogflowV2ListKnowledgeBasesResponse.ServerResponse.Head
44448// er or (if a response was returned at all) in
44449// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
44450// whether the returned error was because http.StatusNotModified was
44451// returned.
44452func (c *ProjectsLocationsKnowledgeBasesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListKnowledgeBasesResponse, error) {
44453	gensupport.SetOptions(c.urlParams_, opts...)
44454	res, err := c.doRequest("json")
44455	if res != nil && res.StatusCode == http.StatusNotModified {
44456		if res.Body != nil {
44457			res.Body.Close()
44458		}
44459		return nil, &googleapi.Error{
44460			Code:   res.StatusCode,
44461			Header: res.Header,
44462		}
44463	}
44464	if err != nil {
44465		return nil, err
44466	}
44467	defer googleapi.CloseBody(res)
44468	if err := googleapi.CheckResponse(res); err != nil {
44469		return nil, err
44470	}
44471	ret := &GoogleCloudDialogflowV2ListKnowledgeBasesResponse{
44472		ServerResponse: googleapi.ServerResponse{
44473			Header:         res.Header,
44474			HTTPStatusCode: res.StatusCode,
44475		},
44476	}
44477	target := &ret
44478	if err := gensupport.DecodeResponse(target, res); err != nil {
44479		return nil, err
44480	}
44481	return ret, nil
44482	// {
44483	//   "description": "Returns the list of all knowledge bases of the specified agent.",
44484	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases",
44485	//   "httpMethod": "GET",
44486	//   "id": "dialogflow.projects.locations.knowledgeBases.list",
44487	//   "parameterOrder": [
44488	//     "parent"
44489	//   ],
44490	//   "parameters": {
44491	//     "pageSize": {
44492	//       "description": "The maximum number of items to return in a single page. By default 10 and at most 100.",
44493	//       "format": "int32",
44494	//       "location": "query",
44495	//       "type": "integer"
44496	//     },
44497	//     "pageToken": {
44498	//       "description": "The next_page_token value returned from a previous list request.",
44499	//       "location": "query",
44500	//       "type": "string"
44501	//     },
44502	//     "parent": {
44503	//       "description": "Required. The project to list of knowledge bases for. Format: `projects//locations/`.",
44504	//       "location": "path",
44505	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
44506	//       "required": true,
44507	//       "type": "string"
44508	//     }
44509	//   },
44510	//   "path": "v2/{+parent}/knowledgeBases",
44511	//   "response": {
44512	//     "$ref": "GoogleCloudDialogflowV2ListKnowledgeBasesResponse"
44513	//   },
44514	//   "scopes": [
44515	//     "https://www.googleapis.com/auth/cloud-platform",
44516	//     "https://www.googleapis.com/auth/dialogflow"
44517	//   ]
44518	// }
44519
44520}
44521
44522// Pages invokes f for each page of results.
44523// A non-nil error returned from f will halt the iteration.
44524// The provided context supersedes any context provided to the Context method.
44525func (c *ProjectsLocationsKnowledgeBasesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListKnowledgeBasesResponse) error) error {
44526	c.ctx_ = ctx
44527	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
44528	for {
44529		x, err := c.Do()
44530		if err != nil {
44531			return err
44532		}
44533		if err := f(x); err != nil {
44534			return err
44535		}
44536		if x.NextPageToken == "" {
44537			return nil
44538		}
44539		c.PageToken(x.NextPageToken)
44540	}
44541}
44542
44543// method id "dialogflow.projects.locations.knowledgeBases.patch":
44544
44545type ProjectsLocationsKnowledgeBasesPatchCall struct {
44546	s                                    *Service
44547	name                                 string
44548	googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase
44549	urlParams_                           gensupport.URLParams
44550	ctx_                                 context.Context
44551	header_                              http.Header
44552}
44553
44554// Patch: Updates the specified knowledge base.
44555//
44556// - name: The knowledge base resource name. The name must be empty when
44557//   creating a knowledge base. Format:
44558//   `projects//locations//knowledgeBases/`.
44559func (r *ProjectsLocationsKnowledgeBasesService) Patch(name string, googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase) *ProjectsLocationsKnowledgeBasesPatchCall {
44560	c := &ProjectsLocationsKnowledgeBasesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44561	c.name = name
44562	c.googleclouddialogflowv2knowledgebase = googleclouddialogflowv2knowledgebase
44563	return c
44564}
44565
44566// UpdateMask sets the optional parameter "updateMask": Not specified
44567// means `update all`. Currently, only `display_name` can be updated, an
44568// InvalidArgument will be returned for attempting to update other
44569// fields.
44570func (c *ProjectsLocationsKnowledgeBasesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsKnowledgeBasesPatchCall {
44571	c.urlParams_.Set("updateMask", updateMask)
44572	return c
44573}
44574
44575// Fields allows partial responses to be retrieved. See
44576// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44577// for more information.
44578func (c *ProjectsLocationsKnowledgeBasesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesPatchCall {
44579	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44580	return c
44581}
44582
44583// Context sets the context to be used in this call's Do method. Any
44584// pending HTTP request will be aborted if the provided context is
44585// canceled.
44586func (c *ProjectsLocationsKnowledgeBasesPatchCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesPatchCall {
44587	c.ctx_ = ctx
44588	return c
44589}
44590
44591// Header returns an http.Header that can be modified by the caller to
44592// add HTTP headers to the request.
44593func (c *ProjectsLocationsKnowledgeBasesPatchCall) Header() http.Header {
44594	if c.header_ == nil {
44595		c.header_ = make(http.Header)
44596	}
44597	return c.header_
44598}
44599
44600func (c *ProjectsLocationsKnowledgeBasesPatchCall) doRequest(alt string) (*http.Response, error) {
44601	reqHeaders := make(http.Header)
44602	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
44603	for k, v := range c.header_ {
44604		reqHeaders[k] = v
44605	}
44606	reqHeaders.Set("User-Agent", c.s.userAgent())
44607	var body io.Reader = nil
44608	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2knowledgebase)
44609	if err != nil {
44610		return nil, err
44611	}
44612	reqHeaders.Set("Content-Type", "application/json")
44613	c.urlParams_.Set("alt", alt)
44614	c.urlParams_.Set("prettyPrint", "false")
44615	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
44616	urls += "?" + c.urlParams_.Encode()
44617	req, err := http.NewRequest("PATCH", urls, body)
44618	if err != nil {
44619		return nil, err
44620	}
44621	req.Header = reqHeaders
44622	googleapi.Expand(req.URL, map[string]string{
44623		"name": c.name,
44624	})
44625	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44626}
44627
44628// Do executes the "dialogflow.projects.locations.knowledgeBases.patch" call.
44629// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
44630// non-nil. Any non-2xx status code is an error. Response headers are in
44631// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
44632// (if a response was returned at all) in
44633// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
44634// whether the returned error was because http.StatusNotModified was
44635// returned.
44636func (c *ProjectsLocationsKnowledgeBasesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
44637	gensupport.SetOptions(c.urlParams_, opts...)
44638	res, err := c.doRequest("json")
44639	if res != nil && res.StatusCode == http.StatusNotModified {
44640		if res.Body != nil {
44641			res.Body.Close()
44642		}
44643		return nil, &googleapi.Error{
44644			Code:   res.StatusCode,
44645			Header: res.Header,
44646		}
44647	}
44648	if err != nil {
44649		return nil, err
44650	}
44651	defer googleapi.CloseBody(res)
44652	if err := googleapi.CheckResponse(res); err != nil {
44653		return nil, err
44654	}
44655	ret := &GoogleCloudDialogflowV2KnowledgeBase{
44656		ServerResponse: googleapi.ServerResponse{
44657			Header:         res.Header,
44658			HTTPStatusCode: res.StatusCode,
44659		},
44660	}
44661	target := &ret
44662	if err := gensupport.DecodeResponse(target, res); err != nil {
44663		return nil, err
44664	}
44665	return ret, nil
44666	// {
44667	//   "description": "Updates the specified knowledge base.",
44668	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}",
44669	//   "httpMethod": "PATCH",
44670	//   "id": "dialogflow.projects.locations.knowledgeBases.patch",
44671	//   "parameterOrder": [
44672	//     "name"
44673	//   ],
44674	//   "parameters": {
44675	//     "name": {
44676	//       "description": "The knowledge base resource name. The name must be empty when creating a knowledge base. Format: `projects//locations//knowledgeBases/`.",
44677	//       "location": "path",
44678	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+$",
44679	//       "required": true,
44680	//       "type": "string"
44681	//     },
44682	//     "updateMask": {
44683	//       "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.",
44684	//       "format": "google-fieldmask",
44685	//       "location": "query",
44686	//       "type": "string"
44687	//     }
44688	//   },
44689	//   "path": "v2/{+name}",
44690	//   "request": {
44691	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
44692	//   },
44693	//   "response": {
44694	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
44695	//   },
44696	//   "scopes": [
44697	//     "https://www.googleapis.com/auth/cloud-platform",
44698	//     "https://www.googleapis.com/auth/dialogflow"
44699	//   ]
44700	// }
44701
44702}
44703
44704// method id "dialogflow.projects.locations.knowledgeBases.documents.create":
44705
44706type ProjectsLocationsKnowledgeBasesDocumentsCreateCall struct {
44707	s                               *Service
44708	parent                          string
44709	googleclouddialogflowv2document *GoogleCloudDialogflowV2Document
44710	urlParams_                      gensupport.URLParams
44711	ctx_                            context.Context
44712	header_                         http.Header
44713}
44714
44715// Create: Creates a new document. Operation
44716//
44717// - parent: The knowledge base to create a document for. Format:
44718//   `projects//locations//knowledgeBases/`.
44719func (r *ProjectsLocationsKnowledgeBasesDocumentsService) Create(parent string, googleclouddialogflowv2document *GoogleCloudDialogflowV2Document) *ProjectsLocationsKnowledgeBasesDocumentsCreateCall {
44720	c := &ProjectsLocationsKnowledgeBasesDocumentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44721	c.parent = parent
44722	c.googleclouddialogflowv2document = googleclouddialogflowv2document
44723	return c
44724}
44725
44726// Fields allows partial responses to be retrieved. See
44727// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44728// for more information.
44729func (c *ProjectsLocationsKnowledgeBasesDocumentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDocumentsCreateCall {
44730	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44731	return c
44732}
44733
44734// Context sets the context to be used in this call's Do method. Any
44735// pending HTTP request will be aborted if the provided context is
44736// canceled.
44737func (c *ProjectsLocationsKnowledgeBasesDocumentsCreateCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDocumentsCreateCall {
44738	c.ctx_ = ctx
44739	return c
44740}
44741
44742// Header returns an http.Header that can be modified by the caller to
44743// add HTTP headers to the request.
44744func (c *ProjectsLocationsKnowledgeBasesDocumentsCreateCall) Header() http.Header {
44745	if c.header_ == nil {
44746		c.header_ = make(http.Header)
44747	}
44748	return c.header_
44749}
44750
44751func (c *ProjectsLocationsKnowledgeBasesDocumentsCreateCall) doRequest(alt string) (*http.Response, error) {
44752	reqHeaders := make(http.Header)
44753	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
44754	for k, v := range c.header_ {
44755		reqHeaders[k] = v
44756	}
44757	reqHeaders.Set("User-Agent", c.s.userAgent())
44758	var body io.Reader = nil
44759	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2document)
44760	if err != nil {
44761		return nil, err
44762	}
44763	reqHeaders.Set("Content-Type", "application/json")
44764	c.urlParams_.Set("alt", alt)
44765	c.urlParams_.Set("prettyPrint", "false")
44766	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/documents")
44767	urls += "?" + c.urlParams_.Encode()
44768	req, err := http.NewRequest("POST", urls, body)
44769	if err != nil {
44770		return nil, err
44771	}
44772	req.Header = reqHeaders
44773	googleapi.Expand(req.URL, map[string]string{
44774		"parent": c.parent,
44775	})
44776	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44777}
44778
44779// Do executes the "dialogflow.projects.locations.knowledgeBases.documents.create" call.
44780// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
44781// Any non-2xx status code is an error. Response headers are in either
44782// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
44783// was returned at all) in error.(*googleapi.Error).Header. Use
44784// googleapi.IsNotModified to check whether the returned error was
44785// because http.StatusNotModified was returned.
44786func (c *ProjectsLocationsKnowledgeBasesDocumentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
44787	gensupport.SetOptions(c.urlParams_, opts...)
44788	res, err := c.doRequest("json")
44789	if res != nil && res.StatusCode == http.StatusNotModified {
44790		if res.Body != nil {
44791			res.Body.Close()
44792		}
44793		return nil, &googleapi.Error{
44794			Code:   res.StatusCode,
44795			Header: res.Header,
44796		}
44797	}
44798	if err != nil {
44799		return nil, err
44800	}
44801	defer googleapi.CloseBody(res)
44802	if err := googleapi.CheckResponse(res); err != nil {
44803		return nil, err
44804	}
44805	ret := &GoogleLongrunningOperation{
44806		ServerResponse: googleapi.ServerResponse{
44807			Header:         res.Header,
44808			HTTPStatusCode: res.StatusCode,
44809		},
44810	}
44811	target := &ret
44812	if err := gensupport.DecodeResponse(target, res); err != nil {
44813		return nil, err
44814	}
44815	return ret, nil
44816	// {
44817	//   "description": "Creates a new document. Operation ",
44818	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}/documents",
44819	//   "httpMethod": "POST",
44820	//   "id": "dialogflow.projects.locations.knowledgeBases.documents.create",
44821	//   "parameterOrder": [
44822	//     "parent"
44823	//   ],
44824	//   "parameters": {
44825	//     "parent": {
44826	//       "description": "Required. The knowledge base to create a document for. Format: `projects//locations//knowledgeBases/`.",
44827	//       "location": "path",
44828	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+$",
44829	//       "required": true,
44830	//       "type": "string"
44831	//     }
44832	//   },
44833	//   "path": "v2/{+parent}/documents",
44834	//   "request": {
44835	//     "$ref": "GoogleCloudDialogflowV2Document"
44836	//   },
44837	//   "response": {
44838	//     "$ref": "GoogleLongrunningOperation"
44839	//   },
44840	//   "scopes": [
44841	//     "https://www.googleapis.com/auth/cloud-platform",
44842	//     "https://www.googleapis.com/auth/dialogflow"
44843	//   ]
44844	// }
44845
44846}
44847
44848// method id "dialogflow.projects.locations.knowledgeBases.documents.delete":
44849
44850type ProjectsLocationsKnowledgeBasesDocumentsDeleteCall struct {
44851	s          *Service
44852	name       string
44853	urlParams_ gensupport.URLParams
44854	ctx_       context.Context
44855	header_    http.Header
44856}
44857
44858// Delete: Deletes the specified document. Operation
44859//
44860// - name: The name of the document to delete. Format:
44861//   `projects//locations//knowledgeBases//documents/`.
44862func (r *ProjectsLocationsKnowledgeBasesDocumentsService) Delete(name string) *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall {
44863	c := &ProjectsLocationsKnowledgeBasesDocumentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44864	c.name = name
44865	return c
44866}
44867
44868// Fields allows partial responses to be retrieved. See
44869// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44870// for more information.
44871func (c *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall {
44872	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44873	return c
44874}
44875
44876// Context sets the context to be used in this call's Do method. Any
44877// pending HTTP request will be aborted if the provided context is
44878// canceled.
44879func (c *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall {
44880	c.ctx_ = ctx
44881	return c
44882}
44883
44884// Header returns an http.Header that can be modified by the caller to
44885// add HTTP headers to the request.
44886func (c *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall) Header() http.Header {
44887	if c.header_ == nil {
44888		c.header_ = make(http.Header)
44889	}
44890	return c.header_
44891}
44892
44893func (c *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall) doRequest(alt string) (*http.Response, error) {
44894	reqHeaders := make(http.Header)
44895	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
44896	for k, v := range c.header_ {
44897		reqHeaders[k] = v
44898	}
44899	reqHeaders.Set("User-Agent", c.s.userAgent())
44900	var body io.Reader = nil
44901	c.urlParams_.Set("alt", alt)
44902	c.urlParams_.Set("prettyPrint", "false")
44903	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
44904	urls += "?" + c.urlParams_.Encode()
44905	req, err := http.NewRequest("DELETE", urls, body)
44906	if err != nil {
44907		return nil, err
44908	}
44909	req.Header = reqHeaders
44910	googleapi.Expand(req.URL, map[string]string{
44911		"name": c.name,
44912	})
44913	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44914}
44915
44916// Do executes the "dialogflow.projects.locations.knowledgeBases.documents.delete" call.
44917// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
44918// Any non-2xx status code is an error. Response headers are in either
44919// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
44920// was returned at all) in error.(*googleapi.Error).Header. Use
44921// googleapi.IsNotModified to check whether the returned error was
44922// because http.StatusNotModified was returned.
44923func (c *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
44924	gensupport.SetOptions(c.urlParams_, opts...)
44925	res, err := c.doRequest("json")
44926	if res != nil && res.StatusCode == http.StatusNotModified {
44927		if res.Body != nil {
44928			res.Body.Close()
44929		}
44930		return nil, &googleapi.Error{
44931			Code:   res.StatusCode,
44932			Header: res.Header,
44933		}
44934	}
44935	if err != nil {
44936		return nil, err
44937	}
44938	defer googleapi.CloseBody(res)
44939	if err := googleapi.CheckResponse(res); err != nil {
44940		return nil, err
44941	}
44942	ret := &GoogleLongrunningOperation{
44943		ServerResponse: googleapi.ServerResponse{
44944			Header:         res.Header,
44945			HTTPStatusCode: res.StatusCode,
44946		},
44947	}
44948	target := &ret
44949	if err := gensupport.DecodeResponse(target, res); err != nil {
44950		return nil, err
44951	}
44952	return ret, nil
44953	// {
44954	//   "description": "Deletes the specified document. Operation ",
44955	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
44956	//   "httpMethod": "DELETE",
44957	//   "id": "dialogflow.projects.locations.knowledgeBases.documents.delete",
44958	//   "parameterOrder": [
44959	//     "name"
44960	//   ],
44961	//   "parameters": {
44962	//     "name": {
44963	//       "description": "Required. The name of the document to delete. Format: `projects//locations//knowledgeBases//documents/`.",
44964	//       "location": "path",
44965	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
44966	//       "required": true,
44967	//       "type": "string"
44968	//     }
44969	//   },
44970	//   "path": "v2/{+name}",
44971	//   "response": {
44972	//     "$ref": "GoogleLongrunningOperation"
44973	//   },
44974	//   "scopes": [
44975	//     "https://www.googleapis.com/auth/cloud-platform",
44976	//     "https://www.googleapis.com/auth/dialogflow"
44977	//   ]
44978	// }
44979
44980}
44981
44982// method id "dialogflow.projects.locations.knowledgeBases.documents.get":
44983
44984type ProjectsLocationsKnowledgeBasesDocumentsGetCall struct {
44985	s            *Service
44986	name         string
44987	urlParams_   gensupport.URLParams
44988	ifNoneMatch_ string
44989	ctx_         context.Context
44990	header_      http.Header
44991}
44992
44993// Get: Retrieves the specified document.
44994//
44995// - name: The name of the document to retrieve. Format
44996//   `projects//locations//knowledgeBases//documents/`.
44997func (r *ProjectsLocationsKnowledgeBasesDocumentsService) Get(name string) *ProjectsLocationsKnowledgeBasesDocumentsGetCall {
44998	c := &ProjectsLocationsKnowledgeBasesDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44999	c.name = name
45000	return c
45001}
45002
45003// Fields allows partial responses to be retrieved. See
45004// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45005// for more information.
45006func (c *ProjectsLocationsKnowledgeBasesDocumentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDocumentsGetCall {
45007	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45008	return c
45009}
45010
45011// IfNoneMatch sets the optional parameter which makes the operation
45012// fail if the object's ETag matches the given value. This is useful for
45013// getting updates only after the object has changed since the last
45014// request. Use googleapi.IsNotModified to check whether the response
45015// error from Do is the result of In-None-Match.
45016func (c *ProjectsLocationsKnowledgeBasesDocumentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsKnowledgeBasesDocumentsGetCall {
45017	c.ifNoneMatch_ = entityTag
45018	return c
45019}
45020
45021// Context sets the context to be used in this call's Do method. Any
45022// pending HTTP request will be aborted if the provided context is
45023// canceled.
45024func (c *ProjectsLocationsKnowledgeBasesDocumentsGetCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDocumentsGetCall {
45025	c.ctx_ = ctx
45026	return c
45027}
45028
45029// Header returns an http.Header that can be modified by the caller to
45030// add HTTP headers to the request.
45031func (c *ProjectsLocationsKnowledgeBasesDocumentsGetCall) Header() http.Header {
45032	if c.header_ == nil {
45033		c.header_ = make(http.Header)
45034	}
45035	return c.header_
45036}
45037
45038func (c *ProjectsLocationsKnowledgeBasesDocumentsGetCall) doRequest(alt string) (*http.Response, error) {
45039	reqHeaders := make(http.Header)
45040	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
45041	for k, v := range c.header_ {
45042		reqHeaders[k] = v
45043	}
45044	reqHeaders.Set("User-Agent", c.s.userAgent())
45045	if c.ifNoneMatch_ != "" {
45046		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45047	}
45048	var body io.Reader = nil
45049	c.urlParams_.Set("alt", alt)
45050	c.urlParams_.Set("prettyPrint", "false")
45051	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
45052	urls += "?" + c.urlParams_.Encode()
45053	req, err := http.NewRequest("GET", urls, body)
45054	if err != nil {
45055		return nil, err
45056	}
45057	req.Header = reqHeaders
45058	googleapi.Expand(req.URL, map[string]string{
45059		"name": c.name,
45060	})
45061	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45062}
45063
45064// Do executes the "dialogflow.projects.locations.knowledgeBases.documents.get" call.
45065// Exactly one of *GoogleCloudDialogflowV2Document or error will be
45066// non-nil. Any non-2xx status code is an error. Response headers are in
45067// either *GoogleCloudDialogflowV2Document.ServerResponse.Header or (if
45068// a response was returned at all) in error.(*googleapi.Error).Header.
45069// Use googleapi.IsNotModified to check whether the returned error was
45070// because http.StatusNotModified was returned.
45071func (c *ProjectsLocationsKnowledgeBasesDocumentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Document, error) {
45072	gensupport.SetOptions(c.urlParams_, opts...)
45073	res, err := c.doRequest("json")
45074	if res != nil && res.StatusCode == http.StatusNotModified {
45075		if res.Body != nil {
45076			res.Body.Close()
45077		}
45078		return nil, &googleapi.Error{
45079			Code:   res.StatusCode,
45080			Header: res.Header,
45081		}
45082	}
45083	if err != nil {
45084		return nil, err
45085	}
45086	defer googleapi.CloseBody(res)
45087	if err := googleapi.CheckResponse(res); err != nil {
45088		return nil, err
45089	}
45090	ret := &GoogleCloudDialogflowV2Document{
45091		ServerResponse: googleapi.ServerResponse{
45092			Header:         res.Header,
45093			HTTPStatusCode: res.StatusCode,
45094		},
45095	}
45096	target := &ret
45097	if err := gensupport.DecodeResponse(target, res); err != nil {
45098		return nil, err
45099	}
45100	return ret, nil
45101	// {
45102	//   "description": "Retrieves the specified document.",
45103	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
45104	//   "httpMethod": "GET",
45105	//   "id": "dialogflow.projects.locations.knowledgeBases.documents.get",
45106	//   "parameterOrder": [
45107	//     "name"
45108	//   ],
45109	//   "parameters": {
45110	//     "name": {
45111	//       "description": "Required. The name of the document to retrieve. Format `projects//locations//knowledgeBases//documents/`.",
45112	//       "location": "path",
45113	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
45114	//       "required": true,
45115	//       "type": "string"
45116	//     }
45117	//   },
45118	//   "path": "v2/{+name}",
45119	//   "response": {
45120	//     "$ref": "GoogleCloudDialogflowV2Document"
45121	//   },
45122	//   "scopes": [
45123	//     "https://www.googleapis.com/auth/cloud-platform",
45124	//     "https://www.googleapis.com/auth/dialogflow"
45125	//   ]
45126	// }
45127
45128}
45129
45130// method id "dialogflow.projects.locations.knowledgeBases.documents.list":
45131
45132type ProjectsLocationsKnowledgeBasesDocumentsListCall struct {
45133	s            *Service
45134	parent       string
45135	urlParams_   gensupport.URLParams
45136	ifNoneMatch_ string
45137	ctx_         context.Context
45138	header_      http.Header
45139}
45140
45141// List: Returns the list of all documents of the knowledge base.
45142//
45143// - parent: The knowledge base to list all documents for. Format:
45144//   `projects//locations//knowledgeBases/`.
45145func (r *ProjectsLocationsKnowledgeBasesDocumentsService) List(parent string) *ProjectsLocationsKnowledgeBasesDocumentsListCall {
45146	c := &ProjectsLocationsKnowledgeBasesDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45147	c.parent = parent
45148	return c
45149}
45150
45151// PageSize sets the optional parameter "pageSize": The maximum number
45152// of items to return in a single page. By default 10 and at most 100.
45153func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) PageSize(pageSize int64) *ProjectsLocationsKnowledgeBasesDocumentsListCall {
45154	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
45155	return c
45156}
45157
45158// PageToken sets the optional parameter "pageToken": The
45159// next_page_token value returned from a previous list request.
45160func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) PageToken(pageToken string) *ProjectsLocationsKnowledgeBasesDocumentsListCall {
45161	c.urlParams_.Set("pageToken", pageToken)
45162	return c
45163}
45164
45165// Fields allows partial responses to be retrieved. See
45166// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45167// for more information.
45168func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDocumentsListCall {
45169	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45170	return c
45171}
45172
45173// IfNoneMatch sets the optional parameter which makes the operation
45174// fail if the object's ETag matches the given value. This is useful for
45175// getting updates only after the object has changed since the last
45176// request. Use googleapi.IsNotModified to check whether the response
45177// error from Do is the result of In-None-Match.
45178func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsKnowledgeBasesDocumentsListCall {
45179	c.ifNoneMatch_ = entityTag
45180	return c
45181}
45182
45183// Context sets the context to be used in this call's Do method. Any
45184// pending HTTP request will be aborted if the provided context is
45185// canceled.
45186func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDocumentsListCall {
45187	c.ctx_ = ctx
45188	return c
45189}
45190
45191// Header returns an http.Header that can be modified by the caller to
45192// add HTTP headers to the request.
45193func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) Header() http.Header {
45194	if c.header_ == nil {
45195		c.header_ = make(http.Header)
45196	}
45197	return c.header_
45198}
45199
45200func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) doRequest(alt string) (*http.Response, error) {
45201	reqHeaders := make(http.Header)
45202	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
45203	for k, v := range c.header_ {
45204		reqHeaders[k] = v
45205	}
45206	reqHeaders.Set("User-Agent", c.s.userAgent())
45207	if c.ifNoneMatch_ != "" {
45208		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45209	}
45210	var body io.Reader = nil
45211	c.urlParams_.Set("alt", alt)
45212	c.urlParams_.Set("prettyPrint", "false")
45213	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/documents")
45214	urls += "?" + c.urlParams_.Encode()
45215	req, err := http.NewRequest("GET", urls, body)
45216	if err != nil {
45217		return nil, err
45218	}
45219	req.Header = reqHeaders
45220	googleapi.Expand(req.URL, map[string]string{
45221		"parent": c.parent,
45222	})
45223	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45224}
45225
45226// Do executes the "dialogflow.projects.locations.knowledgeBases.documents.list" call.
45227// Exactly one of *GoogleCloudDialogflowV2ListDocumentsResponse or error
45228// will be non-nil. Any non-2xx status code is an error. Response
45229// headers are in either
45230// *GoogleCloudDialogflowV2ListDocumentsResponse.ServerResponse.Header
45231// or (if a response was returned at all) in
45232// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
45233// whether the returned error was because http.StatusNotModified was
45234// returned.
45235func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListDocumentsResponse, error) {
45236	gensupport.SetOptions(c.urlParams_, opts...)
45237	res, err := c.doRequest("json")
45238	if res != nil && res.StatusCode == http.StatusNotModified {
45239		if res.Body != nil {
45240			res.Body.Close()
45241		}
45242		return nil, &googleapi.Error{
45243			Code:   res.StatusCode,
45244			Header: res.Header,
45245		}
45246	}
45247	if err != nil {
45248		return nil, err
45249	}
45250	defer googleapi.CloseBody(res)
45251	if err := googleapi.CheckResponse(res); err != nil {
45252		return nil, err
45253	}
45254	ret := &GoogleCloudDialogflowV2ListDocumentsResponse{
45255		ServerResponse: googleapi.ServerResponse{
45256			Header:         res.Header,
45257			HTTPStatusCode: res.StatusCode,
45258		},
45259	}
45260	target := &ret
45261	if err := gensupport.DecodeResponse(target, res); err != nil {
45262		return nil, err
45263	}
45264	return ret, nil
45265	// {
45266	//   "description": "Returns the list of all documents of the knowledge base.",
45267	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}/documents",
45268	//   "httpMethod": "GET",
45269	//   "id": "dialogflow.projects.locations.knowledgeBases.documents.list",
45270	//   "parameterOrder": [
45271	//     "parent"
45272	//   ],
45273	//   "parameters": {
45274	//     "pageSize": {
45275	//       "description": "The maximum number of items to return in a single page. By default 10 and at most 100.",
45276	//       "format": "int32",
45277	//       "location": "query",
45278	//       "type": "integer"
45279	//     },
45280	//     "pageToken": {
45281	//       "description": "The next_page_token value returned from a previous list request.",
45282	//       "location": "query",
45283	//       "type": "string"
45284	//     },
45285	//     "parent": {
45286	//       "description": "Required. The knowledge base to list all documents for. Format: `projects//locations//knowledgeBases/`.",
45287	//       "location": "path",
45288	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+$",
45289	//       "required": true,
45290	//       "type": "string"
45291	//     }
45292	//   },
45293	//   "path": "v2/{+parent}/documents",
45294	//   "response": {
45295	//     "$ref": "GoogleCloudDialogflowV2ListDocumentsResponse"
45296	//   },
45297	//   "scopes": [
45298	//     "https://www.googleapis.com/auth/cloud-platform",
45299	//     "https://www.googleapis.com/auth/dialogflow"
45300	//   ]
45301	// }
45302
45303}
45304
45305// Pages invokes f for each page of results.
45306// A non-nil error returned from f will halt the iteration.
45307// The provided context supersedes any context provided to the Context method.
45308func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListDocumentsResponse) error) error {
45309	c.ctx_ = ctx
45310	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
45311	for {
45312		x, err := c.Do()
45313		if err != nil {
45314			return err
45315		}
45316		if err := f(x); err != nil {
45317			return err
45318		}
45319		if x.NextPageToken == "" {
45320			return nil
45321		}
45322		c.PageToken(x.NextPageToken)
45323	}
45324}
45325
45326// method id "dialogflow.projects.locations.knowledgeBases.documents.patch":
45327
45328type ProjectsLocationsKnowledgeBasesDocumentsPatchCall struct {
45329	s                               *Service
45330	name                            string
45331	googleclouddialogflowv2document *GoogleCloudDialogflowV2Document
45332	urlParams_                      gensupport.URLParams
45333	ctx_                            context.Context
45334	header_                         http.Header
45335}
45336
45337// Patch: Updates the specified document. Operation
45338//
45339// - name: Optional. The document resource name. The name must be empty
45340//   when creating a document. Format:
45341//   `projects//locations//knowledgeBases//documents/`.
45342func (r *ProjectsLocationsKnowledgeBasesDocumentsService) Patch(name string, googleclouddialogflowv2document *GoogleCloudDialogflowV2Document) *ProjectsLocationsKnowledgeBasesDocumentsPatchCall {
45343	c := &ProjectsLocationsKnowledgeBasesDocumentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45344	c.name = name
45345	c.googleclouddialogflowv2document = googleclouddialogflowv2document
45346	return c
45347}
45348
45349// UpdateMask sets the optional parameter "updateMask": Not specified
45350// means `update all`. Currently, only `display_name` can be updated, an
45351// InvalidArgument will be returned for attempting to update other
45352// fields.
45353func (c *ProjectsLocationsKnowledgeBasesDocumentsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsKnowledgeBasesDocumentsPatchCall {
45354	c.urlParams_.Set("updateMask", updateMask)
45355	return c
45356}
45357
45358// Fields allows partial responses to be retrieved. See
45359// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45360// for more information.
45361func (c *ProjectsLocationsKnowledgeBasesDocumentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDocumentsPatchCall {
45362	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45363	return c
45364}
45365
45366// Context sets the context to be used in this call's Do method. Any
45367// pending HTTP request will be aborted if the provided context is
45368// canceled.
45369func (c *ProjectsLocationsKnowledgeBasesDocumentsPatchCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDocumentsPatchCall {
45370	c.ctx_ = ctx
45371	return c
45372}
45373
45374// Header returns an http.Header that can be modified by the caller to
45375// add HTTP headers to the request.
45376func (c *ProjectsLocationsKnowledgeBasesDocumentsPatchCall) Header() http.Header {
45377	if c.header_ == nil {
45378		c.header_ = make(http.Header)
45379	}
45380	return c.header_
45381}
45382
45383func (c *ProjectsLocationsKnowledgeBasesDocumentsPatchCall) doRequest(alt string) (*http.Response, error) {
45384	reqHeaders := make(http.Header)
45385	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
45386	for k, v := range c.header_ {
45387		reqHeaders[k] = v
45388	}
45389	reqHeaders.Set("User-Agent", c.s.userAgent())
45390	var body io.Reader = nil
45391	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2document)
45392	if err != nil {
45393		return nil, err
45394	}
45395	reqHeaders.Set("Content-Type", "application/json")
45396	c.urlParams_.Set("alt", alt)
45397	c.urlParams_.Set("prettyPrint", "false")
45398	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
45399	urls += "?" + c.urlParams_.Encode()
45400	req, err := http.NewRequest("PATCH", urls, body)
45401	if err != nil {
45402		return nil, err
45403	}
45404	req.Header = reqHeaders
45405	googleapi.Expand(req.URL, map[string]string{
45406		"name": c.name,
45407	})
45408	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45409}
45410
45411// Do executes the "dialogflow.projects.locations.knowledgeBases.documents.patch" call.
45412// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
45413// Any non-2xx status code is an error. Response headers are in either
45414// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
45415// was returned at all) in error.(*googleapi.Error).Header. Use
45416// googleapi.IsNotModified to check whether the returned error was
45417// because http.StatusNotModified was returned.
45418func (c *ProjectsLocationsKnowledgeBasesDocumentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
45419	gensupport.SetOptions(c.urlParams_, opts...)
45420	res, err := c.doRequest("json")
45421	if res != nil && res.StatusCode == http.StatusNotModified {
45422		if res.Body != nil {
45423			res.Body.Close()
45424		}
45425		return nil, &googleapi.Error{
45426			Code:   res.StatusCode,
45427			Header: res.Header,
45428		}
45429	}
45430	if err != nil {
45431		return nil, err
45432	}
45433	defer googleapi.CloseBody(res)
45434	if err := googleapi.CheckResponse(res); err != nil {
45435		return nil, err
45436	}
45437	ret := &GoogleLongrunningOperation{
45438		ServerResponse: googleapi.ServerResponse{
45439			Header:         res.Header,
45440			HTTPStatusCode: res.StatusCode,
45441		},
45442	}
45443	target := &ret
45444	if err := gensupport.DecodeResponse(target, res); err != nil {
45445		return nil, err
45446	}
45447	return ret, nil
45448	// {
45449	//   "description": "Updates the specified document. Operation ",
45450	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
45451	//   "httpMethod": "PATCH",
45452	//   "id": "dialogflow.projects.locations.knowledgeBases.documents.patch",
45453	//   "parameterOrder": [
45454	//     "name"
45455	//   ],
45456	//   "parameters": {
45457	//     "name": {
45458	//       "description": "Optional. The document resource name. The name must be empty when creating a document. Format: `projects//locations//knowledgeBases//documents/`.",
45459	//       "location": "path",
45460	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
45461	//       "required": true,
45462	//       "type": "string"
45463	//     },
45464	//     "updateMask": {
45465	//       "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.",
45466	//       "format": "google-fieldmask",
45467	//       "location": "query",
45468	//       "type": "string"
45469	//     }
45470	//   },
45471	//   "path": "v2/{+name}",
45472	//   "request": {
45473	//     "$ref": "GoogleCloudDialogflowV2Document"
45474	//   },
45475	//   "response": {
45476	//     "$ref": "GoogleLongrunningOperation"
45477	//   },
45478	//   "scopes": [
45479	//     "https://www.googleapis.com/auth/cloud-platform",
45480	//     "https://www.googleapis.com/auth/dialogflow"
45481	//   ]
45482	// }
45483
45484}
45485
45486// method id "dialogflow.projects.locations.knowledgeBases.documents.reload":
45487
45488type ProjectsLocationsKnowledgeBasesDocumentsReloadCall struct {
45489	s                                            *Service
45490	name                                         string
45491	googleclouddialogflowv2reloaddocumentrequest *GoogleCloudDialogflowV2ReloadDocumentRequest
45492	urlParams_                                   gensupport.URLParams
45493	ctx_                                         context.Context
45494	header_                                      http.Header
45495}
45496
45497// Reload: Reloads the specified document from its specified source,
45498// content_uri or content. The previously loaded content of the document
45499// will be deleted. Note: Even when the content of the document has not
45500// changed, there still may be side effects because of internal
45501// implementation changes. Note: The
45502// `projects.agent.knowledgeBases.documents` resource is deprecated;
45503// only use `projects.knowledgeBases.documents`. Operation
45504//
45505// - name: The name of the document to reload. Format:
45506//   `projects//locations//knowledgeBases//documents/`.
45507func (r *ProjectsLocationsKnowledgeBasesDocumentsService) Reload(name string, googleclouddialogflowv2reloaddocumentrequest *GoogleCloudDialogflowV2ReloadDocumentRequest) *ProjectsLocationsKnowledgeBasesDocumentsReloadCall {
45508	c := &ProjectsLocationsKnowledgeBasesDocumentsReloadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45509	c.name = name
45510	c.googleclouddialogflowv2reloaddocumentrequest = googleclouddialogflowv2reloaddocumentrequest
45511	return c
45512}
45513
45514// Fields allows partial responses to be retrieved. See
45515// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45516// for more information.
45517func (c *ProjectsLocationsKnowledgeBasesDocumentsReloadCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDocumentsReloadCall {
45518	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45519	return c
45520}
45521
45522// Context sets the context to be used in this call's Do method. Any
45523// pending HTTP request will be aborted if the provided context is
45524// canceled.
45525func (c *ProjectsLocationsKnowledgeBasesDocumentsReloadCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDocumentsReloadCall {
45526	c.ctx_ = ctx
45527	return c
45528}
45529
45530// Header returns an http.Header that can be modified by the caller to
45531// add HTTP headers to the request.
45532func (c *ProjectsLocationsKnowledgeBasesDocumentsReloadCall) Header() http.Header {
45533	if c.header_ == nil {
45534		c.header_ = make(http.Header)
45535	}
45536	return c.header_
45537}
45538
45539func (c *ProjectsLocationsKnowledgeBasesDocumentsReloadCall) doRequest(alt string) (*http.Response, error) {
45540	reqHeaders := make(http.Header)
45541	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
45542	for k, v := range c.header_ {
45543		reqHeaders[k] = v
45544	}
45545	reqHeaders.Set("User-Agent", c.s.userAgent())
45546	var body io.Reader = nil
45547	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2reloaddocumentrequest)
45548	if err != nil {
45549		return nil, err
45550	}
45551	reqHeaders.Set("Content-Type", "application/json")
45552	c.urlParams_.Set("alt", alt)
45553	c.urlParams_.Set("prettyPrint", "false")
45554	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:reload")
45555	urls += "?" + c.urlParams_.Encode()
45556	req, err := http.NewRequest("POST", urls, body)
45557	if err != nil {
45558		return nil, err
45559	}
45560	req.Header = reqHeaders
45561	googleapi.Expand(req.URL, map[string]string{
45562		"name": c.name,
45563	})
45564	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45565}
45566
45567// Do executes the "dialogflow.projects.locations.knowledgeBases.documents.reload" call.
45568// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
45569// Any non-2xx status code is an error. Response headers are in either
45570// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
45571// was returned at all) in error.(*googleapi.Error).Header. Use
45572// googleapi.IsNotModified to check whether the returned error was
45573// because http.StatusNotModified was returned.
45574func (c *ProjectsLocationsKnowledgeBasesDocumentsReloadCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
45575	gensupport.SetOptions(c.urlParams_, opts...)
45576	res, err := c.doRequest("json")
45577	if res != nil && res.StatusCode == http.StatusNotModified {
45578		if res.Body != nil {
45579			res.Body.Close()
45580		}
45581		return nil, &googleapi.Error{
45582			Code:   res.StatusCode,
45583			Header: res.Header,
45584		}
45585	}
45586	if err != nil {
45587		return nil, err
45588	}
45589	defer googleapi.CloseBody(res)
45590	if err := googleapi.CheckResponse(res); err != nil {
45591		return nil, err
45592	}
45593	ret := &GoogleLongrunningOperation{
45594		ServerResponse: googleapi.ServerResponse{
45595			Header:         res.Header,
45596			HTTPStatusCode: res.StatusCode,
45597		},
45598	}
45599	target := &ret
45600	if err := gensupport.DecodeResponse(target, res); err != nil {
45601		return nil, err
45602	}
45603	return ret, nil
45604	// {
45605	//   "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. Note: The `projects.agent.knowledgeBases.documents` resource is deprecated; only use `projects.knowledgeBases.documents`. Operation ",
45606	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}:reload",
45607	//   "httpMethod": "POST",
45608	//   "id": "dialogflow.projects.locations.knowledgeBases.documents.reload",
45609	//   "parameterOrder": [
45610	//     "name"
45611	//   ],
45612	//   "parameters": {
45613	//     "name": {
45614	//       "description": "Required. The name of the document to reload. Format: `projects//locations//knowledgeBases//documents/`",
45615	//       "location": "path",
45616	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
45617	//       "required": true,
45618	//       "type": "string"
45619	//     }
45620	//   },
45621	//   "path": "v2/{+name}:reload",
45622	//   "request": {
45623	//     "$ref": "GoogleCloudDialogflowV2ReloadDocumentRequest"
45624	//   },
45625	//   "response": {
45626	//     "$ref": "GoogleLongrunningOperation"
45627	//   },
45628	//   "scopes": [
45629	//     "https://www.googleapis.com/auth/cloud-platform",
45630	//     "https://www.googleapis.com/auth/dialogflow"
45631	//   ]
45632	// }
45633
45634}
45635
45636// method id "dialogflow.projects.locations.operations.cancel":
45637
45638type ProjectsLocationsOperationsCancelCall struct {
45639	s          *Service
45640	name       string
45641	urlParams_ gensupport.URLParams
45642	ctx_       context.Context
45643	header_    http.Header
45644}
45645
45646// Cancel: Starts asynchronous cancellation on a long-running operation.
45647// The server makes a best effort to cancel the operation, but success
45648// is not guaranteed. If the server doesn't support this method, it
45649// returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use
45650// Operations.GetOperation or other methods to check whether the
45651// cancellation succeeded or whether the operation completed despite
45652// cancellation. On successful cancellation, the operation is not
45653// deleted; instead, it becomes an operation with an Operation.error
45654// value with a google.rpc.Status.code of 1, corresponding to
45655// `Code.CANCELLED`.
45656//
45657// - name: The name of the operation resource to be cancelled.
45658func (r *ProjectsLocationsOperationsService) Cancel(name string) *ProjectsLocationsOperationsCancelCall {
45659	c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45660	c.name = name
45661	return c
45662}
45663
45664// Fields allows partial responses to be retrieved. See
45665// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45666// for more information.
45667func (c *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall {
45668	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45669	return c
45670}
45671
45672// Context sets the context to be used in this call's Do method. Any
45673// pending HTTP request will be aborted if the provided context is
45674// canceled.
45675func (c *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall {
45676	c.ctx_ = ctx
45677	return c
45678}
45679
45680// Header returns an http.Header that can be modified by the caller to
45681// add HTTP headers to the request.
45682func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header {
45683	if c.header_ == nil {
45684		c.header_ = make(http.Header)
45685	}
45686	return c.header_
45687}
45688
45689func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) {
45690	reqHeaders := make(http.Header)
45691	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
45692	for k, v := range c.header_ {
45693		reqHeaders[k] = v
45694	}
45695	reqHeaders.Set("User-Agent", c.s.userAgent())
45696	var body io.Reader = nil
45697	c.urlParams_.Set("alt", alt)
45698	c.urlParams_.Set("prettyPrint", "false")
45699	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:cancel")
45700	urls += "?" + c.urlParams_.Encode()
45701	req, err := http.NewRequest("POST", urls, body)
45702	if err != nil {
45703		return nil, err
45704	}
45705	req.Header = reqHeaders
45706	googleapi.Expand(req.URL, map[string]string{
45707		"name": c.name,
45708	})
45709	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45710}
45711
45712// Do executes the "dialogflow.projects.locations.operations.cancel" call.
45713// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
45714// non-2xx status code is an error. Response headers are in either
45715// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
45716// returned at all) in error.(*googleapi.Error).Header. Use
45717// googleapi.IsNotModified to check whether the returned error was
45718// because http.StatusNotModified was returned.
45719func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
45720	gensupport.SetOptions(c.urlParams_, opts...)
45721	res, err := c.doRequest("json")
45722	if res != nil && res.StatusCode == http.StatusNotModified {
45723		if res.Body != nil {
45724			res.Body.Close()
45725		}
45726		return nil, &googleapi.Error{
45727			Code:   res.StatusCode,
45728			Header: res.Header,
45729		}
45730	}
45731	if err != nil {
45732		return nil, err
45733	}
45734	defer googleapi.CloseBody(res)
45735	if err := googleapi.CheckResponse(res); err != nil {
45736		return nil, err
45737	}
45738	ret := &GoogleProtobufEmpty{
45739		ServerResponse: googleapi.ServerResponse{
45740			Header:         res.Header,
45741			HTTPStatusCode: res.StatusCode,
45742		},
45743	}
45744	target := &ret
45745	if err := gensupport.DecodeResponse(target, res); err != nil {
45746		return nil, err
45747	}
45748	return ret, nil
45749	// {
45750	//   "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`.",
45751	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel",
45752	//   "httpMethod": "POST",
45753	//   "id": "dialogflow.projects.locations.operations.cancel",
45754	//   "parameterOrder": [
45755	//     "name"
45756	//   ],
45757	//   "parameters": {
45758	//     "name": {
45759	//       "description": "The name of the operation resource to be cancelled.",
45760	//       "location": "path",
45761	//       "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$",
45762	//       "required": true,
45763	//       "type": "string"
45764	//     }
45765	//   },
45766	//   "path": "v2/{+name}:cancel",
45767	//   "response": {
45768	//     "$ref": "GoogleProtobufEmpty"
45769	//   },
45770	//   "scopes": [
45771	//     "https://www.googleapis.com/auth/cloud-platform",
45772	//     "https://www.googleapis.com/auth/dialogflow"
45773	//   ]
45774	// }
45775
45776}
45777
45778// method id "dialogflow.projects.locations.operations.get":
45779
45780type ProjectsLocationsOperationsGetCall struct {
45781	s            *Service
45782	name         string
45783	urlParams_   gensupport.URLParams
45784	ifNoneMatch_ string
45785	ctx_         context.Context
45786	header_      http.Header
45787}
45788
45789// Get: Gets the latest state of a long-running operation. Clients can
45790// use this method to poll the operation result at intervals as
45791// recommended by the API service.
45792//
45793// - name: The name of the operation resource.
45794func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall {
45795	c := &ProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45796	c.name = name
45797	return c
45798}
45799
45800// Fields allows partial responses to be retrieved. See
45801// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45802// for more information.
45803func (c *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsGetCall {
45804	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45805	return c
45806}
45807
45808// IfNoneMatch sets the optional parameter which makes the operation
45809// fail if the object's ETag matches the given value. This is useful for
45810// getting updates only after the object has changed since the last
45811// request. Use googleapi.IsNotModified to check whether the response
45812// error from Do is the result of In-None-Match.
45813func (c *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsGetCall {
45814	c.ifNoneMatch_ = entityTag
45815	return c
45816}
45817
45818// Context sets the context to be used in this call's Do method. Any
45819// pending HTTP request will be aborted if the provided context is
45820// canceled.
45821func (c *ProjectsLocationsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOperationsGetCall {
45822	c.ctx_ = ctx
45823	return c
45824}
45825
45826// Header returns an http.Header that can be modified by the caller to
45827// add HTTP headers to the request.
45828func (c *ProjectsLocationsOperationsGetCall) Header() http.Header {
45829	if c.header_ == nil {
45830		c.header_ = make(http.Header)
45831	}
45832	return c.header_
45833}
45834
45835func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) {
45836	reqHeaders := make(http.Header)
45837	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
45838	for k, v := range c.header_ {
45839		reqHeaders[k] = v
45840	}
45841	reqHeaders.Set("User-Agent", c.s.userAgent())
45842	if c.ifNoneMatch_ != "" {
45843		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45844	}
45845	var body io.Reader = nil
45846	c.urlParams_.Set("alt", alt)
45847	c.urlParams_.Set("prettyPrint", "false")
45848	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
45849	urls += "?" + c.urlParams_.Encode()
45850	req, err := http.NewRequest("GET", urls, body)
45851	if err != nil {
45852		return nil, err
45853	}
45854	req.Header = reqHeaders
45855	googleapi.Expand(req.URL, map[string]string{
45856		"name": c.name,
45857	})
45858	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45859}
45860
45861// Do executes the "dialogflow.projects.locations.operations.get" call.
45862// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
45863// Any non-2xx status code is an error. Response headers are in either
45864// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
45865// was returned at all) in error.(*googleapi.Error).Header. Use
45866// googleapi.IsNotModified to check whether the returned error was
45867// because http.StatusNotModified was returned.
45868func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
45869	gensupport.SetOptions(c.urlParams_, opts...)
45870	res, err := c.doRequest("json")
45871	if res != nil && res.StatusCode == http.StatusNotModified {
45872		if res.Body != nil {
45873			res.Body.Close()
45874		}
45875		return nil, &googleapi.Error{
45876			Code:   res.StatusCode,
45877			Header: res.Header,
45878		}
45879	}
45880	if err != nil {
45881		return nil, err
45882	}
45883	defer googleapi.CloseBody(res)
45884	if err := googleapi.CheckResponse(res); err != nil {
45885		return nil, err
45886	}
45887	ret := &GoogleLongrunningOperation{
45888		ServerResponse: googleapi.ServerResponse{
45889			Header:         res.Header,
45890			HTTPStatusCode: res.StatusCode,
45891		},
45892	}
45893	target := &ret
45894	if err := gensupport.DecodeResponse(target, res); err != nil {
45895		return nil, err
45896	}
45897	return ret, nil
45898	// {
45899	//   "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.",
45900	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
45901	//   "httpMethod": "GET",
45902	//   "id": "dialogflow.projects.locations.operations.get",
45903	//   "parameterOrder": [
45904	//     "name"
45905	//   ],
45906	//   "parameters": {
45907	//     "name": {
45908	//       "description": "The name of the operation resource.",
45909	//       "location": "path",
45910	//       "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$",
45911	//       "required": true,
45912	//       "type": "string"
45913	//     }
45914	//   },
45915	//   "path": "v2/{+name}",
45916	//   "response": {
45917	//     "$ref": "GoogleLongrunningOperation"
45918	//   },
45919	//   "scopes": [
45920	//     "https://www.googleapis.com/auth/cloud-platform",
45921	//     "https://www.googleapis.com/auth/dialogflow"
45922	//   ]
45923	// }
45924
45925}
45926
45927// method id "dialogflow.projects.locations.operations.list":
45928
45929type ProjectsLocationsOperationsListCall struct {
45930	s            *Service
45931	name         string
45932	urlParams_   gensupport.URLParams
45933	ifNoneMatch_ string
45934	ctx_         context.Context
45935	header_      http.Header
45936}
45937
45938// List: Lists operations that match the specified filter in the
45939// request. If the server doesn't support this method, it returns
45940// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to
45941// override the binding to use different resource name schemes, such as
45942// `users/*/operations`. To override the binding, API services can add a
45943// binding such as "/v1/{name=users/*}/operations" to their service
45944// configuration. For backwards compatibility, the default name includes
45945// the operations collection id, however overriding users must ensure
45946// the name binding is the parent resource, without the operations
45947// collection id.
45948//
45949// - name: The name of the operation's parent resource.
45950func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall {
45951	c := &ProjectsLocationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45952	c.name = name
45953	return c
45954}
45955
45956// Filter sets the optional parameter "filter": The standard list
45957// filter.
45958func (c *ProjectsLocationsOperationsListCall) Filter(filter string) *ProjectsLocationsOperationsListCall {
45959	c.urlParams_.Set("filter", filter)
45960	return c
45961}
45962
45963// PageSize sets the optional parameter "pageSize": The standard list
45964// page size.
45965func (c *ProjectsLocationsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsOperationsListCall {
45966	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
45967	return c
45968}
45969
45970// PageToken sets the optional parameter "pageToken": The standard list
45971// page token.
45972func (c *ProjectsLocationsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsOperationsListCall {
45973	c.urlParams_.Set("pageToken", pageToken)
45974	return c
45975}
45976
45977// Fields allows partial responses to be retrieved. See
45978// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45979// for more information.
45980func (c *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsListCall {
45981	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45982	return c
45983}
45984
45985// IfNoneMatch sets the optional parameter which makes the operation
45986// fail if the object's ETag matches the given value. This is useful for
45987// getting updates only after the object has changed since the last
45988// request. Use googleapi.IsNotModified to check whether the response
45989// error from Do is the result of In-None-Match.
45990func (c *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsListCall {
45991	c.ifNoneMatch_ = entityTag
45992	return c
45993}
45994
45995// Context sets the context to be used in this call's Do method. Any
45996// pending HTTP request will be aborted if the provided context is
45997// canceled.
45998func (c *ProjectsLocationsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsOperationsListCall {
45999	c.ctx_ = ctx
46000	return c
46001}
46002
46003// Header returns an http.Header that can be modified by the caller to
46004// add HTTP headers to the request.
46005func (c *ProjectsLocationsOperationsListCall) Header() http.Header {
46006	if c.header_ == nil {
46007		c.header_ = make(http.Header)
46008	}
46009	return c.header_
46010}
46011
46012func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Response, error) {
46013	reqHeaders := make(http.Header)
46014	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
46015	for k, v := range c.header_ {
46016		reqHeaders[k] = v
46017	}
46018	reqHeaders.Set("User-Agent", c.s.userAgent())
46019	if c.ifNoneMatch_ != "" {
46020		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46021	}
46022	var body io.Reader = nil
46023	c.urlParams_.Set("alt", alt)
46024	c.urlParams_.Set("prettyPrint", "false")
46025	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}/operations")
46026	urls += "?" + c.urlParams_.Encode()
46027	req, err := http.NewRequest("GET", urls, body)
46028	if err != nil {
46029		return nil, err
46030	}
46031	req.Header = reqHeaders
46032	googleapi.Expand(req.URL, map[string]string{
46033		"name": c.name,
46034	})
46035	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46036}
46037
46038// Do executes the "dialogflow.projects.locations.operations.list" call.
46039// Exactly one of *GoogleLongrunningListOperationsResponse or error will
46040// be non-nil. Any non-2xx status code is an error. Response headers are
46041// in either
46042// *GoogleLongrunningListOperationsResponse.ServerResponse.Header or (if
46043// a response was returned at all) in error.(*googleapi.Error).Header.
46044// Use googleapi.IsNotModified to check whether the returned error was
46045// because http.StatusNotModified was returned.
46046func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) {
46047	gensupport.SetOptions(c.urlParams_, opts...)
46048	res, err := c.doRequest("json")
46049	if res != nil && res.StatusCode == http.StatusNotModified {
46050		if res.Body != nil {
46051			res.Body.Close()
46052		}
46053		return nil, &googleapi.Error{
46054			Code:   res.StatusCode,
46055			Header: res.Header,
46056		}
46057	}
46058	if err != nil {
46059		return nil, err
46060	}
46061	defer googleapi.CloseBody(res)
46062	if err := googleapi.CheckResponse(res); err != nil {
46063		return nil, err
46064	}
46065	ret := &GoogleLongrunningListOperationsResponse{
46066		ServerResponse: googleapi.ServerResponse{
46067			Header:         res.Header,
46068			HTTPStatusCode: res.StatusCode,
46069		},
46070	}
46071	target := &ret
46072	if err := gensupport.DecodeResponse(target, res); err != nil {
46073		return nil, err
46074	}
46075	return ret, nil
46076	// {
46077	//   "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.",
46078	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/operations",
46079	//   "httpMethod": "GET",
46080	//   "id": "dialogflow.projects.locations.operations.list",
46081	//   "parameterOrder": [
46082	//     "name"
46083	//   ],
46084	//   "parameters": {
46085	//     "filter": {
46086	//       "description": "The standard list filter.",
46087	//       "location": "query",
46088	//       "type": "string"
46089	//     },
46090	//     "name": {
46091	//       "description": "The name of the operation's parent resource.",
46092	//       "location": "path",
46093	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
46094	//       "required": true,
46095	//       "type": "string"
46096	//     },
46097	//     "pageSize": {
46098	//       "description": "The standard list page size.",
46099	//       "format": "int32",
46100	//       "location": "query",
46101	//       "type": "integer"
46102	//     },
46103	//     "pageToken": {
46104	//       "description": "The standard list page token.",
46105	//       "location": "query",
46106	//       "type": "string"
46107	//     }
46108	//   },
46109	//   "path": "v2/{+name}/operations",
46110	//   "response": {
46111	//     "$ref": "GoogleLongrunningListOperationsResponse"
46112	//   },
46113	//   "scopes": [
46114	//     "https://www.googleapis.com/auth/cloud-platform",
46115	//     "https://www.googleapis.com/auth/dialogflow"
46116	//   ]
46117	// }
46118
46119}
46120
46121// Pages invokes f for each page of results.
46122// A non-nil error returned from f will halt the iteration.
46123// The provided context supersedes any context provided to the Context method.
46124func (c *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error {
46125	c.ctx_ = ctx
46126	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
46127	for {
46128		x, err := c.Do()
46129		if err != nil {
46130			return err
46131		}
46132		if err := f(x); err != nil {
46133			return err
46134		}
46135		if x.NextPageToken == "" {
46136			return nil
46137		}
46138		c.PageToken(x.NextPageToken)
46139	}
46140}
46141
46142// method id "dialogflow.projects.operations.cancel":
46143
46144type ProjectsOperationsCancelCall struct {
46145	s          *Service
46146	name       string
46147	urlParams_ gensupport.URLParams
46148	ctx_       context.Context
46149	header_    http.Header
46150}
46151
46152// Cancel: Starts asynchronous cancellation on a long-running operation.
46153// The server makes a best effort to cancel the operation, but success
46154// is not guaranteed. If the server doesn't support this method, it
46155// returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use
46156// Operations.GetOperation or other methods to check whether the
46157// cancellation succeeded or whether the operation completed despite
46158// cancellation. On successful cancellation, the operation is not
46159// deleted; instead, it becomes an operation with an Operation.error
46160// value with a google.rpc.Status.code of 1, corresponding to
46161// `Code.CANCELLED`.
46162//
46163// - name: The name of the operation resource to be cancelled.
46164func (r *ProjectsOperationsService) Cancel(name string) *ProjectsOperationsCancelCall {
46165	c := &ProjectsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46166	c.name = name
46167	return c
46168}
46169
46170// Fields allows partial responses to be retrieved. See
46171// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46172// for more information.
46173func (c *ProjectsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsOperationsCancelCall {
46174	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46175	return c
46176}
46177
46178// Context sets the context to be used in this call's Do method. Any
46179// pending HTTP request will be aborted if the provided context is
46180// canceled.
46181func (c *ProjectsOperationsCancelCall) Context(ctx context.Context) *ProjectsOperationsCancelCall {
46182	c.ctx_ = ctx
46183	return c
46184}
46185
46186// Header returns an http.Header that can be modified by the caller to
46187// add HTTP headers to the request.
46188func (c *ProjectsOperationsCancelCall) Header() http.Header {
46189	if c.header_ == nil {
46190		c.header_ = make(http.Header)
46191	}
46192	return c.header_
46193}
46194
46195func (c *ProjectsOperationsCancelCall) doRequest(alt string) (*http.Response, error) {
46196	reqHeaders := make(http.Header)
46197	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
46198	for k, v := range c.header_ {
46199		reqHeaders[k] = v
46200	}
46201	reqHeaders.Set("User-Agent", c.s.userAgent())
46202	var body io.Reader = nil
46203	c.urlParams_.Set("alt", alt)
46204	c.urlParams_.Set("prettyPrint", "false")
46205	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:cancel")
46206	urls += "?" + c.urlParams_.Encode()
46207	req, err := http.NewRequest("POST", urls, body)
46208	if err != nil {
46209		return nil, err
46210	}
46211	req.Header = reqHeaders
46212	googleapi.Expand(req.URL, map[string]string{
46213		"name": c.name,
46214	})
46215	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46216}
46217
46218// Do executes the "dialogflow.projects.operations.cancel" call.
46219// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
46220// non-2xx status code is an error. Response headers are in either
46221// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
46222// returned at all) in error.(*googleapi.Error).Header. Use
46223// googleapi.IsNotModified to check whether the returned error was
46224// because http.StatusNotModified was returned.
46225func (c *ProjectsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
46226	gensupport.SetOptions(c.urlParams_, opts...)
46227	res, err := c.doRequest("json")
46228	if res != nil && res.StatusCode == http.StatusNotModified {
46229		if res.Body != nil {
46230			res.Body.Close()
46231		}
46232		return nil, &googleapi.Error{
46233			Code:   res.StatusCode,
46234			Header: res.Header,
46235		}
46236	}
46237	if err != nil {
46238		return nil, err
46239	}
46240	defer googleapi.CloseBody(res)
46241	if err := googleapi.CheckResponse(res); err != nil {
46242		return nil, err
46243	}
46244	ret := &GoogleProtobufEmpty{
46245		ServerResponse: googleapi.ServerResponse{
46246			Header:         res.Header,
46247			HTTPStatusCode: res.StatusCode,
46248		},
46249	}
46250	target := &ret
46251	if err := gensupport.DecodeResponse(target, res); err != nil {
46252		return nil, err
46253	}
46254	return ret, nil
46255	// {
46256	//   "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`.",
46257	//   "flatPath": "v2/projects/{projectsId}/operations/{operationsId}:cancel",
46258	//   "httpMethod": "POST",
46259	//   "id": "dialogflow.projects.operations.cancel",
46260	//   "parameterOrder": [
46261	//     "name"
46262	//   ],
46263	//   "parameters": {
46264	//     "name": {
46265	//       "description": "The name of the operation resource to be cancelled.",
46266	//       "location": "path",
46267	//       "pattern": "^projects/[^/]+/operations/[^/]+$",
46268	//       "required": true,
46269	//       "type": "string"
46270	//     }
46271	//   },
46272	//   "path": "v2/{+name}:cancel",
46273	//   "response": {
46274	//     "$ref": "GoogleProtobufEmpty"
46275	//   },
46276	//   "scopes": [
46277	//     "https://www.googleapis.com/auth/cloud-platform",
46278	//     "https://www.googleapis.com/auth/dialogflow"
46279	//   ]
46280	// }
46281
46282}
46283
46284// method id "dialogflow.projects.operations.get":
46285
46286type ProjectsOperationsGetCall struct {
46287	s            *Service
46288	name         string
46289	urlParams_   gensupport.URLParams
46290	ifNoneMatch_ string
46291	ctx_         context.Context
46292	header_      http.Header
46293}
46294
46295// Get: Gets the latest state of a long-running operation. Clients can
46296// use this method to poll the operation result at intervals as
46297// recommended by the API service.
46298//
46299// - name: The name of the operation resource.
46300func (r *ProjectsOperationsService) Get(name string) *ProjectsOperationsGetCall {
46301	c := &ProjectsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46302	c.name = name
46303	return c
46304}
46305
46306// Fields allows partial responses to be retrieved. See
46307// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46308// for more information.
46309func (c *ProjectsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsOperationsGetCall {
46310	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46311	return c
46312}
46313
46314// IfNoneMatch sets the optional parameter which makes the operation
46315// fail if the object's ETag matches the given value. This is useful for
46316// getting updates only after the object has changed since the last
46317// request. Use googleapi.IsNotModified to check whether the response
46318// error from Do is the result of In-None-Match.
46319func (c *ProjectsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsOperationsGetCall {
46320	c.ifNoneMatch_ = entityTag
46321	return c
46322}
46323
46324// Context sets the context to be used in this call's Do method. Any
46325// pending HTTP request will be aborted if the provided context is
46326// canceled.
46327func (c *ProjectsOperationsGetCall) Context(ctx context.Context) *ProjectsOperationsGetCall {
46328	c.ctx_ = ctx
46329	return c
46330}
46331
46332// Header returns an http.Header that can be modified by the caller to
46333// add HTTP headers to the request.
46334func (c *ProjectsOperationsGetCall) Header() http.Header {
46335	if c.header_ == nil {
46336		c.header_ = make(http.Header)
46337	}
46338	return c.header_
46339}
46340
46341func (c *ProjectsOperationsGetCall) doRequest(alt string) (*http.Response, error) {
46342	reqHeaders := make(http.Header)
46343	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
46344	for k, v := range c.header_ {
46345		reqHeaders[k] = v
46346	}
46347	reqHeaders.Set("User-Agent", c.s.userAgent())
46348	if c.ifNoneMatch_ != "" {
46349		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46350	}
46351	var body io.Reader = nil
46352	c.urlParams_.Set("alt", alt)
46353	c.urlParams_.Set("prettyPrint", "false")
46354	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
46355	urls += "?" + c.urlParams_.Encode()
46356	req, err := http.NewRequest("GET", urls, body)
46357	if err != nil {
46358		return nil, err
46359	}
46360	req.Header = reqHeaders
46361	googleapi.Expand(req.URL, map[string]string{
46362		"name": c.name,
46363	})
46364	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46365}
46366
46367// Do executes the "dialogflow.projects.operations.get" call.
46368// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
46369// Any non-2xx status code is an error. Response headers are in either
46370// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
46371// was returned at all) in error.(*googleapi.Error).Header. Use
46372// googleapi.IsNotModified to check whether the returned error was
46373// because http.StatusNotModified was returned.
46374func (c *ProjectsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
46375	gensupport.SetOptions(c.urlParams_, opts...)
46376	res, err := c.doRequest("json")
46377	if res != nil && res.StatusCode == http.StatusNotModified {
46378		if res.Body != nil {
46379			res.Body.Close()
46380		}
46381		return nil, &googleapi.Error{
46382			Code:   res.StatusCode,
46383			Header: res.Header,
46384		}
46385	}
46386	if err != nil {
46387		return nil, err
46388	}
46389	defer googleapi.CloseBody(res)
46390	if err := googleapi.CheckResponse(res); err != nil {
46391		return nil, err
46392	}
46393	ret := &GoogleLongrunningOperation{
46394		ServerResponse: googleapi.ServerResponse{
46395			Header:         res.Header,
46396			HTTPStatusCode: res.StatusCode,
46397		},
46398	}
46399	target := &ret
46400	if err := gensupport.DecodeResponse(target, res); err != nil {
46401		return nil, err
46402	}
46403	return ret, nil
46404	// {
46405	//   "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.",
46406	//   "flatPath": "v2/projects/{projectsId}/operations/{operationsId}",
46407	//   "httpMethod": "GET",
46408	//   "id": "dialogflow.projects.operations.get",
46409	//   "parameterOrder": [
46410	//     "name"
46411	//   ],
46412	//   "parameters": {
46413	//     "name": {
46414	//       "description": "The name of the operation resource.",
46415	//       "location": "path",
46416	//       "pattern": "^projects/[^/]+/operations/[^/]+$",
46417	//       "required": true,
46418	//       "type": "string"
46419	//     }
46420	//   },
46421	//   "path": "v2/{+name}",
46422	//   "response": {
46423	//     "$ref": "GoogleLongrunningOperation"
46424	//   },
46425	//   "scopes": [
46426	//     "https://www.googleapis.com/auth/cloud-platform",
46427	//     "https://www.googleapis.com/auth/dialogflow"
46428	//   ]
46429	// }
46430
46431}
46432
46433// method id "dialogflow.projects.operations.list":
46434
46435type ProjectsOperationsListCall struct {
46436	s            *Service
46437	name         string
46438	urlParams_   gensupport.URLParams
46439	ifNoneMatch_ string
46440	ctx_         context.Context
46441	header_      http.Header
46442}
46443
46444// List: Lists operations that match the specified filter in the
46445// request. If the server doesn't support this method, it returns
46446// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to
46447// override the binding to use different resource name schemes, such as
46448// `users/*/operations`. To override the binding, API services can add a
46449// binding such as "/v1/{name=users/*}/operations" to their service
46450// configuration. For backwards compatibility, the default name includes
46451// the operations collection id, however overriding users must ensure
46452// the name binding is the parent resource, without the operations
46453// collection id.
46454//
46455// - name: The name of the operation's parent resource.
46456func (r *ProjectsOperationsService) List(name string) *ProjectsOperationsListCall {
46457	c := &ProjectsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46458	c.name = name
46459	return c
46460}
46461
46462// Filter sets the optional parameter "filter": The standard list
46463// filter.
46464func (c *ProjectsOperationsListCall) Filter(filter string) *ProjectsOperationsListCall {
46465	c.urlParams_.Set("filter", filter)
46466	return c
46467}
46468
46469// PageSize sets the optional parameter "pageSize": The standard list
46470// page size.
46471func (c *ProjectsOperationsListCall) PageSize(pageSize int64) *ProjectsOperationsListCall {
46472	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
46473	return c
46474}
46475
46476// PageToken sets the optional parameter "pageToken": The standard list
46477// page token.
46478func (c *ProjectsOperationsListCall) PageToken(pageToken string) *ProjectsOperationsListCall {
46479	c.urlParams_.Set("pageToken", pageToken)
46480	return c
46481}
46482
46483// Fields allows partial responses to be retrieved. See
46484// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46485// for more information.
46486func (c *ProjectsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsOperationsListCall {
46487	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46488	return c
46489}
46490
46491// IfNoneMatch sets the optional parameter which makes the operation
46492// fail if the object's ETag matches the given value. This is useful for
46493// getting updates only after the object has changed since the last
46494// request. Use googleapi.IsNotModified to check whether the response
46495// error from Do is the result of In-None-Match.
46496func (c *ProjectsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsOperationsListCall {
46497	c.ifNoneMatch_ = entityTag
46498	return c
46499}
46500
46501// Context sets the context to be used in this call's Do method. Any
46502// pending HTTP request will be aborted if the provided context is
46503// canceled.
46504func (c *ProjectsOperationsListCall) Context(ctx context.Context) *ProjectsOperationsListCall {
46505	c.ctx_ = ctx
46506	return c
46507}
46508
46509// Header returns an http.Header that can be modified by the caller to
46510// add HTTP headers to the request.
46511func (c *ProjectsOperationsListCall) Header() http.Header {
46512	if c.header_ == nil {
46513		c.header_ = make(http.Header)
46514	}
46515	return c.header_
46516}
46517
46518func (c *ProjectsOperationsListCall) doRequest(alt string) (*http.Response, error) {
46519	reqHeaders := make(http.Header)
46520	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210410")
46521	for k, v := range c.header_ {
46522		reqHeaders[k] = v
46523	}
46524	reqHeaders.Set("User-Agent", c.s.userAgent())
46525	if c.ifNoneMatch_ != "" {
46526		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46527	}
46528	var body io.Reader = nil
46529	c.urlParams_.Set("alt", alt)
46530	c.urlParams_.Set("prettyPrint", "false")
46531	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}/operations")
46532	urls += "?" + c.urlParams_.Encode()
46533	req, err := http.NewRequest("GET", urls, body)
46534	if err != nil {
46535		return nil, err
46536	}
46537	req.Header = reqHeaders
46538	googleapi.Expand(req.URL, map[string]string{
46539		"name": c.name,
46540	})
46541	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46542}
46543
46544// Do executes the "dialogflow.projects.operations.list" call.
46545// Exactly one of *GoogleLongrunningListOperationsResponse or error will
46546// be non-nil. Any non-2xx status code is an error. Response headers are
46547// in either
46548// *GoogleLongrunningListOperationsResponse.ServerResponse.Header or (if
46549// a response was returned at all) in error.(*googleapi.Error).Header.
46550// Use googleapi.IsNotModified to check whether the returned error was
46551// because http.StatusNotModified was returned.
46552func (c *ProjectsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) {
46553	gensupport.SetOptions(c.urlParams_, opts...)
46554	res, err := c.doRequest("json")
46555	if res != nil && res.StatusCode == http.StatusNotModified {
46556		if res.Body != nil {
46557			res.Body.Close()
46558		}
46559		return nil, &googleapi.Error{
46560			Code:   res.StatusCode,
46561			Header: res.Header,
46562		}
46563	}
46564	if err != nil {
46565		return nil, err
46566	}
46567	defer googleapi.CloseBody(res)
46568	if err := googleapi.CheckResponse(res); err != nil {
46569		return nil, err
46570	}
46571	ret := &GoogleLongrunningListOperationsResponse{
46572		ServerResponse: googleapi.ServerResponse{
46573			Header:         res.Header,
46574			HTTPStatusCode: res.StatusCode,
46575		},
46576	}
46577	target := &ret
46578	if err := gensupport.DecodeResponse(target, res); err != nil {
46579		return nil, err
46580	}
46581	return ret, nil
46582	// {
46583	//   "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.",
46584	//   "flatPath": "v2/projects/{projectsId}/operations",
46585	//   "httpMethod": "GET",
46586	//   "id": "dialogflow.projects.operations.list",
46587	//   "parameterOrder": [
46588	//     "name"
46589	//   ],
46590	//   "parameters": {
46591	//     "filter": {
46592	//       "description": "The standard list filter.",
46593	//       "location": "query",
46594	//       "type": "string"
46595	//     },
46596	//     "name": {
46597	//       "description": "The name of the operation's parent resource.",
46598	//       "location": "path",
46599	//       "pattern": "^projects/[^/]+$",
46600	//       "required": true,
46601	//       "type": "string"
46602	//     },
46603	//     "pageSize": {
46604	//       "description": "The standard list page size.",
46605	//       "format": "int32",
46606	//       "location": "query",
46607	//       "type": "integer"
46608	//     },
46609	//     "pageToken": {
46610	//       "description": "The standard list page token.",
46611	//       "location": "query",
46612	//       "type": "string"
46613	//     }
46614	//   },
46615	//   "path": "v2/{+name}/operations",
46616	//   "response": {
46617	//     "$ref": "GoogleLongrunningListOperationsResponse"
46618	//   },
46619	//   "scopes": [
46620	//     "https://www.googleapis.com/auth/cloud-platform",
46621	//     "https://www.googleapis.com/auth/dialogflow"
46622	//   ]
46623	// }
46624
46625}
46626
46627// Pages invokes f for each page of results.
46628// A non-nil error returned from f will halt the iteration.
46629// The provided context supersedes any context provided to the Context method.
46630func (c *ProjectsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error {
46631	c.ctx_ = ctx
46632	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
46633	for {
46634		x, err := c.Do()
46635		if err != nil {
46636			return err
46637		}
46638		if err := f(x); err != nil {
46639			return err
46640		}
46641		if x.NextPageToken == "" {
46642			return nil
46643		}
46644		c.PageToken(x.NextPageToken)
46645	}
46646}
46647