Debian Codegraph @

docs/dyn/ces_v1beta.projects.locations.apps.examples.html

raw
1 <html><body>
2 <style>
3
4 body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13 }
14
15 body {
16 font-size: 13px;
17 padding: 1em;
18 }
19
20 h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23 }
24
25 h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28 }
29
30 h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34 }
35
36 pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39 }
40
41 pre {
42 margin-top: 0.5em;
43 }
44
45 h1, h2, h3, p {
46 font-family: Arial, sans serif;
47 }
48
49 h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51 }
52
53 .toc_element {
54 margin-top: 0.5em;
55 }
56
57 .firstline {
58 margin-left: 2 em;
59 }
60
61 .method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66 }
67
68 .details {
69 font-weight: bold;
70 font-size: 14px;
71 }
72
73 </style>
74
75 <h1><a href="ces_v1beta.html">Gemini Enterprise for Customer Experience API</a> . <a href="ces_v1beta.projects.html">projects</a> . <a href="ces_v1beta.projects.locations.html">locations</a> . <a href="ces_v1beta.projects.locations.apps.html">apps</a> . <a href="ces_v1beta.projects.locations.apps.examples.html">examples</a></h1>
76 <h2>Instance Methods</h2>
77 <p class="toc_element">
78 <code><a href="#close">close()</a></code></p>
79 <p class="firstline">Close httplib2 connections.</p>
80 <p class="toc_element">
81 <code><a href="#create">create(parent, body=None, exampleId=None, x__xgafv=None)</a></code></p>
82 <p class="firstline">Creates a new example in the given app.</p>
83 <p class="toc_element">
84 <code><a href="#delete">delete(name, etag=None, x__xgafv=None)</a></code></p>
85 <p class="firstline">Deletes the specified example.</p>
86 <p class="toc_element">
87 <code><a href="#get">get(name, x__xgafv=None)</a></code></p>
88 <p class="firstline">Gets details of the specified example.</p>
89 <p class="toc_element">
90 <code><a href="#list">list(parent, filter=None, orderBy=None, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p>
91 <p class="firstline">Lists examples in the given app.</p>
92 <p class="toc_element">
93 <code><a href="#list_next">list_next()</a></code></p>
94 <p class="firstline">Retrieves the next page of results.</p>
95 <p class="toc_element">
96 <code><a href="#patch">patch(name, body=None, updateMask=None, x__xgafv=None)</a></code></p>
97 <p class="firstline">Updates the specified example.</p>
98 <h3>Method Details</h3>
99 <div class="method">
100 <code class="details" id="close">close()</code>
101 <pre>Close httplib2 connections.</pre>
102 </div>
103
104 <div class="method">
105 <code class="details" id="create">create(parent, body=None, exampleId=None, x__xgafv=None)</code>
106 <pre>Creates a new example in the given app.
107
108 Args:
109 parent: string, Required. The resource name of the app to create an example in. (required)
110 body: object, The request body.
111 The object takes the form of:
112
113 { # An example represents a sample conversation between the user and the agent(s).
114 &quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the example was created.
115 &quot;description&quot;: &quot;A String&quot;, # Optional. Human-readable description of the example.
116 &quot;displayName&quot;: &quot;A String&quot;, # Required. Display name of the example.
117 &quot;entryAgent&quot;: &quot;A String&quot;, # Optional. The agent that initially handles the conversation. If not specified, the example represents a conversation that is handled by the root agent. Format: `projects/{project}/locations/{location}/apps/{app}/agents/{agent}`
118 &quot;etag&quot;: &quot;A String&quot;, # Etag used to ensure the object hasn&#x27;t changed during a read-modify-write operation. If the etag is empty, the update will overwrite any concurrent changes.
119 &quot;invalid&quot;: True or False, # Output only. The example may become invalid if referencing resources are deleted. Invalid examples will not be used as few-shot examples.
120 &quot;messages&quot;: [ # Optional. The collection of messages that make up the conversation.
121 { # A message within a conversation.
122 &quot;chunks&quot;: [ # Optional. Content of the message as a series of chunks.
123 { # A chunk of content within a message.
124 &quot;agentTransfer&quot;: { # Represents an event indicating the transfer of a conversation to a different agent. # Optional. Agent transfer event.
125 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the agent.
126 &quot;targetAgent&quot;: &quot;A String&quot;, # Required. The agent to which the conversation is being transferred. The agent will handle the conversation from this point forward. Format: `projects/{project}/locations/{location}/apps/{app}/agents/{agent}`
127 },
128 &quot;blob&quot;: { # Represents a blob input or output in the conversation. # Optional. Blob data.
129 &quot;data&quot;: &quot;A String&quot;, # Required. Raw bytes of the blob.
130 &quot;mimeType&quot;: &quot;A String&quot;, # Required. The IANA standard MIME type of the source data.
131 },
132 &quot;defaultVariables&quot;: { # A struct represents default variables at the start of the conversation, keyed by variable names.
133 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
134 },
135 &quot;image&quot;: { # Represents an image input or output in the conversation. # Optional. Image data.
136 &quot;data&quot;: &quot;A String&quot;, # Required. Raw bytes of the image.
137 &quot;mimeType&quot;: &quot;A String&quot;, # Required. The IANA standard MIME type of the source data. Supported image types includes: * image/png * image/jpeg * image/webp
138 },
139 &quot;payload&quot;: { # Optional. Custom payload data.
140 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
141 },
142 &quot;text&quot;: &quot;A String&quot;, # Optional. Text data.
143 &quot;toolCall&quot;: { # Request for the client or the agent to execute the specified tool. # Optional. Tool execution request.
144 &quot;args&quot;: { # Optional. The input parameters and values for the tool in JSON object format.
145 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
146 },
147 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the tool.
148 &quot;id&quot;: &quot;A String&quot;, # Optional. The unique identifier of the tool call. If populated, the client should return the execution result with the matching ID in ToolResponse.
149 &quot;tool&quot;: &quot;A String&quot;, # Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}`
150 &quot;toolsetTool&quot;: { # A tool that is created from a toolset. # Optional. The toolset tool to execute.
151 &quot;toolId&quot;: &quot;A String&quot;, # Optional. The tool ID to filter the tools to retrieve the schema for.
152 &quot;toolset&quot;: &quot;A String&quot;, # Required. The resource name of the Toolset from which this tool is derived. Format: `projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}`
153 },
154 },
155 &quot;toolResponse&quot;: { # The execution result of a specific tool from the client or the agent. # Optional. Tool execution response.
156 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the tool.
157 &quot;id&quot;: &quot;A String&quot;, # Optional. The matching ID of the tool call the response is for.
158 &quot;response&quot;: { # Required. The tool execution result in JSON object format. Use &quot;output&quot; key to specify tool response and &quot;error&quot; key to specify error details (if any). If &quot;output&quot; and &quot;error&quot; keys are not specified, then whole &quot;response&quot; is treated as tool execution result.
159 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
160 },
161 &quot;tool&quot;: &quot;A String&quot;, # Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}`
162 &quot;toolsetTool&quot;: { # A tool that is created from a toolset. # Optional. The toolset tool that got executed.
163 &quot;toolId&quot;: &quot;A String&quot;, # Optional. The tool ID to filter the tools to retrieve the schema for.
164 &quot;toolset&quot;: &quot;A String&quot;, # Required. The resource name of the Toolset from which this tool is derived. Format: `projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}`
165 },
166 },
167 &quot;transcript&quot;: &quot;A String&quot;, # Optional. Transcript associated with the audio.
168 &quot;updatedVariables&quot;: { # A struct represents variables that were updated in the conversation, keyed by variable names.
169 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
170 },
171 },
172 ],
173 &quot;eventTime&quot;: &quot;A String&quot;, # Optional. Timestamp when the message was sent or received. Should not be used if the message is part of an example.
174 &quot;role&quot;: &quot;A String&quot;, # Optional. The role within the conversation, e.g., user, agent.
175 },
176 ],
177 &quot;name&quot;: &quot;A String&quot;, # Identifier. The unique identifier of the example. Format: `projects/{project}/locations/{location}/apps/{app}/examples/{example}`
178 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the example was last updated.
179 }
180
181 exampleId: string, Optional. The ID to use for the example, which will become the final component of the example&#x27;s resource name. If not provided, a unique ID will be automatically assigned for the example.
182 x__xgafv: string, V1 error format.
183 Allowed values
184 1 - v1 error format
185 2 - v2 error format
186
187 Returns:
188 An object of the form:
189
190 { # An example represents a sample conversation between the user and the agent(s).
191 &quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the example was created.
192 &quot;description&quot;: &quot;A String&quot;, # Optional. Human-readable description of the example.
193 &quot;displayName&quot;: &quot;A String&quot;, # Required. Display name of the example.
194 &quot;entryAgent&quot;: &quot;A String&quot;, # Optional. The agent that initially handles the conversation. If not specified, the example represents a conversation that is handled by the root agent. Format: `projects/{project}/locations/{location}/apps/{app}/agents/{agent}`
195 &quot;etag&quot;: &quot;A String&quot;, # Etag used to ensure the object hasn&#x27;t changed during a read-modify-write operation. If the etag is empty, the update will overwrite any concurrent changes.
196 &quot;invalid&quot;: True or False, # Output only. The example may become invalid if referencing resources are deleted. Invalid examples will not be used as few-shot examples.
197 &quot;messages&quot;: [ # Optional. The collection of messages that make up the conversation.
198 { # A message within a conversation.
199 &quot;chunks&quot;: [ # Optional. Content of the message as a series of chunks.
200 { # A chunk of content within a message.
201 &quot;agentTransfer&quot;: { # Represents an event indicating the transfer of a conversation to a different agent. # Optional. Agent transfer event.
202 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the agent.
203 &quot;targetAgent&quot;: &quot;A String&quot;, # Required. The agent to which the conversation is being transferred. The agent will handle the conversation from this point forward. Format: `projects/{project}/locations/{location}/apps/{app}/agents/{agent}`
204 },
205 &quot;blob&quot;: { # Represents a blob input or output in the conversation. # Optional. Blob data.
206 &quot;data&quot;: &quot;A String&quot;, # Required. Raw bytes of the blob.
207 &quot;mimeType&quot;: &quot;A String&quot;, # Required. The IANA standard MIME type of the source data.
208 },
209 &quot;defaultVariables&quot;: { # A struct represents default variables at the start of the conversation, keyed by variable names.
210 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
211 },
212 &quot;image&quot;: { # Represents an image input or output in the conversation. # Optional. Image data.
213 &quot;data&quot;: &quot;A String&quot;, # Required. Raw bytes of the image.
214 &quot;mimeType&quot;: &quot;A String&quot;, # Required. The IANA standard MIME type of the source data. Supported image types includes: * image/png * image/jpeg * image/webp
215 },
216 &quot;payload&quot;: { # Optional. Custom payload data.
217 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
218 },
219 &quot;text&quot;: &quot;A String&quot;, # Optional. Text data.
220 &quot;toolCall&quot;: { # Request for the client or the agent to execute the specified tool. # Optional. Tool execution request.
221 &quot;args&quot;: { # Optional. The input parameters and values for the tool in JSON object format.
222 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
223 },
224 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the tool.
225 &quot;id&quot;: &quot;A String&quot;, # Optional. The unique identifier of the tool call. If populated, the client should return the execution result with the matching ID in ToolResponse.
226 &quot;tool&quot;: &quot;A String&quot;, # Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}`
227 &quot;toolsetTool&quot;: { # A tool that is created from a toolset. # Optional. The toolset tool to execute.
228 &quot;toolId&quot;: &quot;A String&quot;, # Optional. The tool ID to filter the tools to retrieve the schema for.
229 &quot;toolset&quot;: &quot;A String&quot;, # Required. The resource name of the Toolset from which this tool is derived. Format: `projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}`
230 },
231 },
232 &quot;toolResponse&quot;: { # The execution result of a specific tool from the client or the agent. # Optional. Tool execution response.
233 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the tool.
234 &quot;id&quot;: &quot;A String&quot;, # Optional. The matching ID of the tool call the response is for.
235 &quot;response&quot;: { # Required. The tool execution result in JSON object format. Use &quot;output&quot; key to specify tool response and &quot;error&quot; key to specify error details (if any). If &quot;output&quot; and &quot;error&quot; keys are not specified, then whole &quot;response&quot; is treated as tool execution result.
236 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
237 },
238 &quot;tool&quot;: &quot;A String&quot;, # Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}`
239 &quot;toolsetTool&quot;: { # A tool that is created from a toolset. # Optional. The toolset tool that got executed.
240 &quot;toolId&quot;: &quot;A String&quot;, # Optional. The tool ID to filter the tools to retrieve the schema for.
241 &quot;toolset&quot;: &quot;A String&quot;, # Required. The resource name of the Toolset from which this tool is derived. Format: `projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}`
242 },
243 },
244 &quot;transcript&quot;: &quot;A String&quot;, # Optional. Transcript associated with the audio.
245 &quot;updatedVariables&quot;: { # A struct represents variables that were updated in the conversation, keyed by variable names.
246 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
247 },
248 },
249 ],
250 &quot;eventTime&quot;: &quot;A String&quot;, # Optional. Timestamp when the message was sent or received. Should not be used if the message is part of an example.
251 &quot;role&quot;: &quot;A String&quot;, # Optional. The role within the conversation, e.g., user, agent.
252 },
253 ],
254 &quot;name&quot;: &quot;A String&quot;, # Identifier. The unique identifier of the example. Format: `projects/{project}/locations/{location}/apps/{app}/examples/{example}`
255 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the example was last updated.
256 }</pre>
257 </div>
258
259 <div class="method">
260 <code class="details" id="delete">delete(name, etag=None, x__xgafv=None)</code>
261 <pre>Deletes the specified example.
262
263 Args:
264 name: string, Required. The resource name of the example to delete. (required)
265 etag: string, Optional. The current etag of the example. If an etag is not provided, the deletion will overwrite any concurrent changes. If an etag is provided and does not match the current etag of the example, deletion will be blocked and an ABORTED error will be returned.
266 x__xgafv: string, V1 error format.
267 Allowed values
268 1 - v1 error format
269 2 - v2 error format
270
271 Returns:
272 An object of the form:
273
274 { # A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }
275 }</pre>
276 </div>
277
278 <div class="method">
279 <code class="details" id="get">get(name, x__xgafv=None)</code>
280 <pre>Gets details of the specified example.
281
282 Args:
283 name: string, Required. The resource name of the example to retrieve. (required)
284 x__xgafv: string, V1 error format.
285 Allowed values
286 1 - v1 error format
287 2 - v2 error format
288
289 Returns:
290 An object of the form:
291
292 { # An example represents a sample conversation between the user and the agent(s).
293 &quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the example was created.
294 &quot;description&quot;: &quot;A String&quot;, # Optional. Human-readable description of the example.
295 &quot;displayName&quot;: &quot;A String&quot;, # Required. Display name of the example.
296 &quot;entryAgent&quot;: &quot;A String&quot;, # Optional. The agent that initially handles the conversation. If not specified, the example represents a conversation that is handled by the root agent. Format: `projects/{project}/locations/{location}/apps/{app}/agents/{agent}`
297 &quot;etag&quot;: &quot;A String&quot;, # Etag used to ensure the object hasn&#x27;t changed during a read-modify-write operation. If the etag is empty, the update will overwrite any concurrent changes.
298 &quot;invalid&quot;: True or False, # Output only. The example may become invalid if referencing resources are deleted. Invalid examples will not be used as few-shot examples.
299 &quot;messages&quot;: [ # Optional. The collection of messages that make up the conversation.
300 { # A message within a conversation.
301 &quot;chunks&quot;: [ # Optional. Content of the message as a series of chunks.
302 { # A chunk of content within a message.
303 &quot;agentTransfer&quot;: { # Represents an event indicating the transfer of a conversation to a different agent. # Optional. Agent transfer event.
304 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the agent.
305 &quot;targetAgent&quot;: &quot;A String&quot;, # Required. The agent to which the conversation is being transferred. The agent will handle the conversation from this point forward. Format: `projects/{project}/locations/{location}/apps/{app}/agents/{agent}`
306 },
307 &quot;blob&quot;: { # Represents a blob input or output in the conversation. # Optional. Blob data.
308 &quot;data&quot;: &quot;A String&quot;, # Required. Raw bytes of the blob.
309 &quot;mimeType&quot;: &quot;A String&quot;, # Required. The IANA standard MIME type of the source data.
310 },
311 &quot;defaultVariables&quot;: { # A struct represents default variables at the start of the conversation, keyed by variable names.
312 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
313 },
314 &quot;image&quot;: { # Represents an image input or output in the conversation. # Optional. Image data.
315 &quot;data&quot;: &quot;A String&quot;, # Required. Raw bytes of the image.
316 &quot;mimeType&quot;: &quot;A String&quot;, # Required. The IANA standard MIME type of the source data. Supported image types includes: * image/png * image/jpeg * image/webp
317 },
318 &quot;payload&quot;: { # Optional. Custom payload data.
319 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
320 },
321 &quot;text&quot;: &quot;A String&quot;, # Optional. Text data.
322 &quot;toolCall&quot;: { # Request for the client or the agent to execute the specified tool. # Optional. Tool execution request.
323 &quot;args&quot;: { # Optional. The input parameters and values for the tool in JSON object format.
324 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
325 },
326 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the tool.
327 &quot;id&quot;: &quot;A String&quot;, # Optional. The unique identifier of the tool call. If populated, the client should return the execution result with the matching ID in ToolResponse.
328 &quot;tool&quot;: &quot;A String&quot;, # Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}`
329 &quot;toolsetTool&quot;: { # A tool that is created from a toolset. # Optional. The toolset tool to execute.
330 &quot;toolId&quot;: &quot;A String&quot;, # Optional. The tool ID to filter the tools to retrieve the schema for.
331 &quot;toolset&quot;: &quot;A String&quot;, # Required. The resource name of the Toolset from which this tool is derived. Format: `projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}`
332 },
333 },
334 &quot;toolResponse&quot;: { # The execution result of a specific tool from the client or the agent. # Optional. Tool execution response.
335 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the tool.
336 &quot;id&quot;: &quot;A String&quot;, # Optional. The matching ID of the tool call the response is for.
337 &quot;response&quot;: { # Required. The tool execution result in JSON object format. Use &quot;output&quot; key to specify tool response and &quot;error&quot; key to specify error details (if any). If &quot;output&quot; and &quot;error&quot; keys are not specified, then whole &quot;response&quot; is treated as tool execution result.
338 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
339 },
340 &quot;tool&quot;: &quot;A String&quot;, # Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}`
341 &quot;toolsetTool&quot;: { # A tool that is created from a toolset. # Optional. The toolset tool that got executed.
342 &quot;toolId&quot;: &quot;A String&quot;, # Optional. The tool ID to filter the tools to retrieve the schema for.
343 &quot;toolset&quot;: &quot;A String&quot;, # Required. The resource name of the Toolset from which this tool is derived. Format: `projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}`
344 },
345 },
346 &quot;transcript&quot;: &quot;A String&quot;, # Optional. Transcript associated with the audio.
347 &quot;updatedVariables&quot;: { # A struct represents variables that were updated in the conversation, keyed by variable names.
348 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
349 },
350 },
351 ],
352 &quot;eventTime&quot;: &quot;A String&quot;, # Optional. Timestamp when the message was sent or received. Should not be used if the message is part of an example.
353 &quot;role&quot;: &quot;A String&quot;, # Optional. The role within the conversation, e.g., user, agent.
354 },
355 ],
356 &quot;name&quot;: &quot;A String&quot;, # Identifier. The unique identifier of the example. Format: `projects/{project}/locations/{location}/apps/{app}/examples/{example}`
357 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the example was last updated.
358 }</pre>
359 </div>
360
361 <div class="method">
362 <code class="details" id="list">list(parent, filter=None, orderBy=None, pageSize=None, pageToken=None, x__xgafv=None)</code>
363 <pre>Lists examples in the given app.
364
365 Args:
366 parent: string, Required. The resource name of the app to list examples from. (required)
367 filter: string, Optional. Filter to be applied when listing the examples. See https://google.aip.dev/160 for more details.
368 orderBy: string, Optional. Field to sort by. Only &quot;name&quot; and &quot;create_time&quot; is supported. See https://google.aip.dev/132#ordering for more details.
369 pageSize: integer, Optional. Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.
370 pageToken: string, Optional. The next_page_token value returned from a previous list AgentService.ListExamples call.
371 x__xgafv: string, V1 error format.
372 Allowed values
373 1 - v1 error format
374 2 - v2 error format
375
376 Returns:
377 An object of the form:
378
379 { # Response message for AgentService.ListExamples.
380 &quot;examples&quot;: [ # The list of examples.
381 { # An example represents a sample conversation between the user and the agent(s).
382 &quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the example was created.
383 &quot;description&quot;: &quot;A String&quot;, # Optional. Human-readable description of the example.
384 &quot;displayName&quot;: &quot;A String&quot;, # Required. Display name of the example.
385 &quot;entryAgent&quot;: &quot;A String&quot;, # Optional. The agent that initially handles the conversation. If not specified, the example represents a conversation that is handled by the root agent. Format: `projects/{project}/locations/{location}/apps/{app}/agents/{agent}`
386 &quot;etag&quot;: &quot;A String&quot;, # Etag used to ensure the object hasn&#x27;t changed during a read-modify-write operation. If the etag is empty, the update will overwrite any concurrent changes.
387 &quot;invalid&quot;: True or False, # Output only. The example may become invalid if referencing resources are deleted. Invalid examples will not be used as few-shot examples.
388 &quot;messages&quot;: [ # Optional. The collection of messages that make up the conversation.
389 { # A message within a conversation.
390 &quot;chunks&quot;: [ # Optional. Content of the message as a series of chunks.
391 { # A chunk of content within a message.
392 &quot;agentTransfer&quot;: { # Represents an event indicating the transfer of a conversation to a different agent. # Optional. Agent transfer event.
393 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the agent.
394 &quot;targetAgent&quot;: &quot;A String&quot;, # Required. The agent to which the conversation is being transferred. The agent will handle the conversation from this point forward. Format: `projects/{project}/locations/{location}/apps/{app}/agents/{agent}`
395 },
396 &quot;blob&quot;: { # Represents a blob input or output in the conversation. # Optional. Blob data.
397 &quot;data&quot;: &quot;A String&quot;, # Required. Raw bytes of the blob.
398 &quot;mimeType&quot;: &quot;A String&quot;, # Required. The IANA standard MIME type of the source data.
399 },
400 &quot;defaultVariables&quot;: { # A struct represents default variables at the start of the conversation, keyed by variable names.
401 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
402 },
403 &quot;image&quot;: { # Represents an image input or output in the conversation. # Optional. Image data.
404 &quot;data&quot;: &quot;A String&quot;, # Required. Raw bytes of the image.
405 &quot;mimeType&quot;: &quot;A String&quot;, # Required. The IANA standard MIME type of the source data. Supported image types includes: * image/png * image/jpeg * image/webp
406 },
407 &quot;payload&quot;: { # Optional. Custom payload data.
408 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
409 },
410 &quot;text&quot;: &quot;A String&quot;, # Optional. Text data.
411 &quot;toolCall&quot;: { # Request for the client or the agent to execute the specified tool. # Optional. Tool execution request.
412 &quot;args&quot;: { # Optional. The input parameters and values for the tool in JSON object format.
413 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
414 },
415 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the tool.
416 &quot;id&quot;: &quot;A String&quot;, # Optional. The unique identifier of the tool call. If populated, the client should return the execution result with the matching ID in ToolResponse.
417 &quot;tool&quot;: &quot;A String&quot;, # Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}`
418 &quot;toolsetTool&quot;: { # A tool that is created from a toolset. # Optional. The toolset tool to execute.
419 &quot;toolId&quot;: &quot;A String&quot;, # Optional. The tool ID to filter the tools to retrieve the schema for.
420 &quot;toolset&quot;: &quot;A String&quot;, # Required. The resource name of the Toolset from which this tool is derived. Format: `projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}`
421 },
422 },
423 &quot;toolResponse&quot;: { # The execution result of a specific tool from the client or the agent. # Optional. Tool execution response.
424 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the tool.
425 &quot;id&quot;: &quot;A String&quot;, # Optional. The matching ID of the tool call the response is for.
426 &quot;response&quot;: { # Required. The tool execution result in JSON object format. Use &quot;output&quot; key to specify tool response and &quot;error&quot; key to specify error details (if any). If &quot;output&quot; and &quot;error&quot; keys are not specified, then whole &quot;response&quot; is treated as tool execution result.
427 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
428 },
429 &quot;tool&quot;: &quot;A String&quot;, # Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}`
430 &quot;toolsetTool&quot;: { # A tool that is created from a toolset. # Optional. The toolset tool that got executed.
431 &quot;toolId&quot;: &quot;A String&quot;, # Optional. The tool ID to filter the tools to retrieve the schema for.
432 &quot;toolset&quot;: &quot;A String&quot;, # Required. The resource name of the Toolset from which this tool is derived. Format: `projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}`
433 },
434 },
435 &quot;transcript&quot;: &quot;A String&quot;, # Optional. Transcript associated with the audio.
436 &quot;updatedVariables&quot;: { # A struct represents variables that were updated in the conversation, keyed by variable names.
437 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
438 },
439 },
440 ],
441 &quot;eventTime&quot;: &quot;A String&quot;, # Optional. Timestamp when the message was sent or received. Should not be used if the message is part of an example.
442 &quot;role&quot;: &quot;A String&quot;, # Optional. The role within the conversation, e.g., user, agent.
443 },
444 ],
445 &quot;name&quot;: &quot;A String&quot;, # Identifier. The unique identifier of the example. Format: `projects/{project}/locations/{location}/apps/{app}/examples/{example}`
446 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the example was last updated.
447 },
448 ],
449 &quot;nextPageToken&quot;: &quot;A String&quot;, # A token that can be sent as ListExamplesRequest.page_token to retrieve the next page. Absence of this field indicates there are no subsequent pages.
450 }</pre>
451 </div>
452
453 <div class="method">
454 <code class="details" id="list_next">list_next()</code>
455 <pre>Retrieves the next page of results.
456
457 Args:
458 previous_request: The request for the previous page. (required)
459 previous_response: The response from the request for the previous page. (required)
460
461 Returns:
462 A request object that you can call &#x27;execute()&#x27; on to request the next
463 page. Returns None if there are no more items in the collection.
464 </pre>
465 </div>
466
467 <div class="method">
468 <code class="details" id="patch">patch(name, body=None, updateMask=None, x__xgafv=None)</code>
469 <pre>Updates the specified example.
470
471 Args:
472 name: string, Identifier. The unique identifier of the example. Format: `projects/{project}/locations/{location}/apps/{app}/examples/{example}` (required)
473 body: object, The request body.
474 The object takes the form of:
475
476 { # An example represents a sample conversation between the user and the agent(s).
477 &quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the example was created.
478 &quot;description&quot;: &quot;A String&quot;, # Optional. Human-readable description of the example.
479 &quot;displayName&quot;: &quot;A String&quot;, # Required. Display name of the example.
480 &quot;entryAgent&quot;: &quot;A String&quot;, # Optional. The agent that initially handles the conversation. If not specified, the example represents a conversation that is handled by the root agent. Format: `projects/{project}/locations/{location}/apps/{app}/agents/{agent}`
481 &quot;etag&quot;: &quot;A String&quot;, # Etag used to ensure the object hasn&#x27;t changed during a read-modify-write operation. If the etag is empty, the update will overwrite any concurrent changes.
482 &quot;invalid&quot;: True or False, # Output only. The example may become invalid if referencing resources are deleted. Invalid examples will not be used as few-shot examples.
483 &quot;messages&quot;: [ # Optional. The collection of messages that make up the conversation.
484 { # A message within a conversation.
485 &quot;chunks&quot;: [ # Optional. Content of the message as a series of chunks.
486 { # A chunk of content within a message.
487 &quot;agentTransfer&quot;: { # Represents an event indicating the transfer of a conversation to a different agent. # Optional. Agent transfer event.
488 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the agent.
489 &quot;targetAgent&quot;: &quot;A String&quot;, # Required. The agent to which the conversation is being transferred. The agent will handle the conversation from this point forward. Format: `projects/{project}/locations/{location}/apps/{app}/agents/{agent}`
490 },
491 &quot;blob&quot;: { # Represents a blob input or output in the conversation. # Optional. Blob data.
492 &quot;data&quot;: &quot;A String&quot;, # Required. Raw bytes of the blob.
493 &quot;mimeType&quot;: &quot;A String&quot;, # Required. The IANA standard MIME type of the source data.
494 },
495 &quot;defaultVariables&quot;: { # A struct represents default variables at the start of the conversation, keyed by variable names.
496 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
497 },
498 &quot;image&quot;: { # Represents an image input or output in the conversation. # Optional. Image data.
499 &quot;data&quot;: &quot;A String&quot;, # Required. Raw bytes of the image.
500 &quot;mimeType&quot;: &quot;A String&quot;, # Required. The IANA standard MIME type of the source data. Supported image types includes: * image/png * image/jpeg * image/webp
501 },
502 &quot;payload&quot;: { # Optional. Custom payload data.
503 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
504 },
505 &quot;text&quot;: &quot;A String&quot;, # Optional. Text data.
506 &quot;toolCall&quot;: { # Request for the client or the agent to execute the specified tool. # Optional. Tool execution request.
507 &quot;args&quot;: { # Optional. The input parameters and values for the tool in JSON object format.
508 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
509 },
510 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the tool.
511 &quot;id&quot;: &quot;A String&quot;, # Optional. The unique identifier of the tool call. If populated, the client should return the execution result with the matching ID in ToolResponse.
512 &quot;tool&quot;: &quot;A String&quot;, # Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}`
513 &quot;toolsetTool&quot;: { # A tool that is created from a toolset. # Optional. The toolset tool to execute.
514 &quot;toolId&quot;: &quot;A String&quot;, # Optional. The tool ID to filter the tools to retrieve the schema for.
515 &quot;toolset&quot;: &quot;A String&quot;, # Required. The resource name of the Toolset from which this tool is derived. Format: `projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}`
516 },
517 },
518 &quot;toolResponse&quot;: { # The execution result of a specific tool from the client or the agent. # Optional. Tool execution response.
519 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the tool.
520 &quot;id&quot;: &quot;A String&quot;, # Optional. The matching ID of the tool call the response is for.
521 &quot;response&quot;: { # Required. The tool execution result in JSON object format. Use &quot;output&quot; key to specify tool response and &quot;error&quot; key to specify error details (if any). If &quot;output&quot; and &quot;error&quot; keys are not specified, then whole &quot;response&quot; is treated as tool execution result.
522 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
523 },
524 &quot;tool&quot;: &quot;A String&quot;, # Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}`
525 &quot;toolsetTool&quot;: { # A tool that is created from a toolset. # Optional. The toolset tool that got executed.
526 &quot;toolId&quot;: &quot;A String&quot;, # Optional. The tool ID to filter the tools to retrieve the schema for.
527 &quot;toolset&quot;: &quot;A String&quot;, # Required. The resource name of the Toolset from which this tool is derived. Format: `projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}`
528 },
529 },
530 &quot;transcript&quot;: &quot;A String&quot;, # Optional. Transcript associated with the audio.
531 &quot;updatedVariables&quot;: { # A struct represents variables that were updated in the conversation, keyed by variable names.
532 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
533 },
534 },
535 ],
536 &quot;eventTime&quot;: &quot;A String&quot;, # Optional. Timestamp when the message was sent or received. Should not be used if the message is part of an example.
537 &quot;role&quot;: &quot;A String&quot;, # Optional. The role within the conversation, e.g., user, agent.
538 },
539 ],
540 &quot;name&quot;: &quot;A String&quot;, # Identifier. The unique identifier of the example. Format: `projects/{project}/locations/{location}/apps/{app}/examples/{example}`
541 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the example was last updated.
542 }
543
544 updateMask: string, Optional. Field mask is used to control which fields get updated. If the mask is not present, all fields will be updated.
545 x__xgafv: string, V1 error format.
546 Allowed values
547 1 - v1 error format
548 2 - v2 error format
549
550 Returns:
551 An object of the form:
552
553 { # An example represents a sample conversation between the user and the agent(s).
554 &quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the example was created.
555 &quot;description&quot;: &quot;A String&quot;, # Optional. Human-readable description of the example.
556 &quot;displayName&quot;: &quot;A String&quot;, # Required. Display name of the example.
557 &quot;entryAgent&quot;: &quot;A String&quot;, # Optional. The agent that initially handles the conversation. If not specified, the example represents a conversation that is handled by the root agent. Format: `projects/{project}/locations/{location}/apps/{app}/agents/{agent}`
558 &quot;etag&quot;: &quot;A String&quot;, # Etag used to ensure the object hasn&#x27;t changed during a read-modify-write operation. If the etag is empty, the update will overwrite any concurrent changes.
559 &quot;invalid&quot;: True or False, # Output only. The example may become invalid if referencing resources are deleted. Invalid examples will not be used as few-shot examples.
560 &quot;messages&quot;: [ # Optional. The collection of messages that make up the conversation.
561 { # A message within a conversation.
562 &quot;chunks&quot;: [ # Optional. Content of the message as a series of chunks.
563 { # A chunk of content within a message.
564 &quot;agentTransfer&quot;: { # Represents an event indicating the transfer of a conversation to a different agent. # Optional. Agent transfer event.
565 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the agent.
566 &quot;targetAgent&quot;: &quot;A String&quot;, # Required. The agent to which the conversation is being transferred. The agent will handle the conversation from this point forward. Format: `projects/{project}/locations/{location}/apps/{app}/agents/{agent}`
567 },
568 &quot;blob&quot;: { # Represents a blob input or output in the conversation. # Optional. Blob data.
569 &quot;data&quot;: &quot;A String&quot;, # Required. Raw bytes of the blob.
570 &quot;mimeType&quot;: &quot;A String&quot;, # Required. The IANA standard MIME type of the source data.
571 },
572 &quot;defaultVariables&quot;: { # A struct represents default variables at the start of the conversation, keyed by variable names.
573 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
574 },
575 &quot;image&quot;: { # Represents an image input or output in the conversation. # Optional. Image data.
576 &quot;data&quot;: &quot;A String&quot;, # Required. Raw bytes of the image.
577 &quot;mimeType&quot;: &quot;A String&quot;, # Required. The IANA standard MIME type of the source data. Supported image types includes: * image/png * image/jpeg * image/webp
578 },
579 &quot;payload&quot;: { # Optional. Custom payload data.
580 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
581 },
582 &quot;text&quot;: &quot;A String&quot;, # Optional. Text data.
583 &quot;toolCall&quot;: { # Request for the client or the agent to execute the specified tool. # Optional. Tool execution request.
584 &quot;args&quot;: { # Optional. The input parameters and values for the tool in JSON object format.
585 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
586 },
587 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the tool.
588 &quot;id&quot;: &quot;A String&quot;, # Optional. The unique identifier of the tool call. If populated, the client should return the execution result with the matching ID in ToolResponse.
589 &quot;tool&quot;: &quot;A String&quot;, # Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}`
590 &quot;toolsetTool&quot;: { # A tool that is created from a toolset. # Optional. The toolset tool to execute.
591 &quot;toolId&quot;: &quot;A String&quot;, # Optional. The tool ID to filter the tools to retrieve the schema for.
592 &quot;toolset&quot;: &quot;A String&quot;, # Required. The resource name of the Toolset from which this tool is derived. Format: `projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}`
593 },
594 },
595 &quot;toolResponse&quot;: { # The execution result of a specific tool from the client or the agent. # Optional. Tool execution response.
596 &quot;displayName&quot;: &quot;A String&quot;, # Output only. Display name of the tool.
597 &quot;id&quot;: &quot;A String&quot;, # Optional. The matching ID of the tool call the response is for.
598 &quot;response&quot;: { # Required. The tool execution result in JSON object format. Use &quot;output&quot; key to specify tool response and &quot;error&quot; key to specify error details (if any). If &quot;output&quot; and &quot;error&quot; keys are not specified, then whole &quot;response&quot; is treated as tool execution result.
599 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
600 },
601 &quot;tool&quot;: &quot;A String&quot;, # Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}`
602 &quot;toolsetTool&quot;: { # A tool that is created from a toolset. # Optional. The toolset tool that got executed.
603 &quot;toolId&quot;: &quot;A String&quot;, # Optional. The tool ID to filter the tools to retrieve the schema for.
604 &quot;toolset&quot;: &quot;A String&quot;, # Required. The resource name of the Toolset from which this tool is derived. Format: `projects/{project}/locations/{location}/apps/{app}/toolsets/{toolset}`
605 },
606 },
607 &quot;transcript&quot;: &quot;A String&quot;, # Optional. Transcript associated with the audio.
608 &quot;updatedVariables&quot;: { # A struct represents variables that were updated in the conversation, keyed by variable names.
609 &quot;a_key&quot;: &quot;&quot;, # Properties of the object.
610 },
611 },
612 ],
613 &quot;eventTime&quot;: &quot;A String&quot;, # Optional. Timestamp when the message was sent or received. Should not be used if the message is part of an example.
614 &quot;role&quot;: &quot;A String&quot;, # Optional. The role within the conversation, e.g., user, agent.
615 },
616 ],
617 &quot;name&quot;: &quot;A String&quot;, # Identifier. The unique identifier of the example. Format: `projects/{project}/locations/{location}/apps/{app}/examples/{example}`
618 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. Timestamp when the example was last updated.
619 }</pre>
620 </div>
621
622 </body></html>