Debian Codegraph @

docs/dyn/aiplatform_v1.media.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="aiplatform_v1.html">Agent Platform API</a> . <a href="aiplatform_v1.media.html">media</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="#upload">upload(parent, body=None, media_body=None, media_mime_type=None, x__xgafv=None)</a></code></p>
82 <p class="firstline">Upload a file into a RagCorpus.</p>
83 <h3>Method Details</h3>
84 <div class="method">
85 <code class="details" id="close">close()</code>
86 <pre>Close httplib2 connections.</pre>
87 </div>
88
89 <div class="method">
90 <code class="details" id="upload">upload(parent, body=None, media_body=None, media_mime_type=None, x__xgafv=None)</code>
91 <pre>Upload a file into a RagCorpus.
92
93 Args:
94 parent: string, Required. The name of the RagCorpus resource into which to upload the file. Format: `projects/{project}/locations/{location}/ragCorpora/{rag_corpus}` (required)
95 body: object, The request body.
96 The object takes the form of:
97
98 { # Request message for VertexRagDataService.UploadRagFile.
99 &quot;ragFile&quot;: { # A RagFile contains user data for chunking, embedding and indexing. # Required. The RagFile to upload.
100 &quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this RagFile was created.
101 &quot;description&quot;: &quot;A String&quot;, # Optional. The description of the RagFile.
102 &quot;directUploadSource&quot;: { # The input content is encapsulated and uploaded in the request. # Output only. The RagFile is encapsulated and uploaded in the UploadRagFile request.
103 },
104 &quot;displayName&quot;: &quot;A String&quot;, # Required. The display name of the RagFile. The name can be up to 128 characters long and can consist of any UTF-8 characters.
105 &quot;fileStatus&quot;: { # RagFile status. # Output only. State of the RagFile.
106 &quot;errorStatus&quot;: &quot;A String&quot;, # Output only. Only when the `state` field is ERROR.
107 &quot;state&quot;: &quot;A String&quot;, # Output only. RagFile state.
108 },
109 &quot;gcsSource&quot;: { # The Google Cloud Storage location for the input content. # Output only. Google Cloud Storage location of the RagFile. It does not support wildcards in the Cloud Storage uri for now.
110 &quot;uris&quot;: [ # Required. Google Cloud Storage URI(-s) to the input file(s). May contain wildcards. For more information on wildcards, see https://cloud.google.com/storage/docs/wildcards.
111 &quot;A String&quot;,
112 ],
113 },
114 &quot;googleDriveSource&quot;: { # The Google Drive location for the input content. # Output only. Google Drive location. Supports importing individual files as well as Google Drive folders.
115 &quot;resourceIds&quot;: [ # Required. Google Drive resource IDs.
116 { # The type and ID of the Google Drive resource.
117 &quot;resourceId&quot;: &quot;A String&quot;, # Required. The ID of the Google Drive resource.
118 &quot;resourceType&quot;: &quot;A String&quot;, # Required. The type of the Google Drive resource.
119 },
120 ],
121 },
122 &quot;jiraSource&quot;: { # The Jira source for the ImportRagFilesRequest. # The RagFile is imported from a Jira query.
123 &quot;jiraQueries&quot;: [ # Required. The Jira queries.
124 { # JiraQueries contains the Jira queries and corresponding authentication.
125 &quot;apiKeyConfig&quot;: { # The API secret. # Required. The SecretManager secret version resource name (e.g. projects/{project}/secrets/{secret}/versions/{version}) storing the Jira API key. See [Manage API tokens for your Atlassian account](https://support.atlassian.com/atlassian-account/docs/manage-api-tokens-for-your-atlassian-account/).
126 &quot;apiKeySecretVersion&quot;: &quot;A String&quot;, # Required. The SecretManager secret version resource name storing API key. e.g. projects/{project}/secrets/{secret}/versions/{version}
127 &quot;apiKeyString&quot;: &quot;A String&quot;, # The API key string. Either this or `api_key_secret_version` must be set.
128 },
129 &quot;customQueries&quot;: [ # A list of custom Jira queries to import. For information about JQL (Jira Query Language), see https://support.atlassian.com/jira-service-management-cloud/docs/use-advanced-search-with-jira-query-language-jql/
130 &quot;A String&quot;,
131 ],
132 &quot;email&quot;: &quot;A String&quot;, # Required. The Jira email address.
133 &quot;projects&quot;: [ # A list of Jira projects to import in their entirety.
134 &quot;A String&quot;,
135 ],
136 &quot;serverUri&quot;: &quot;A String&quot;, # Required. The Jira server URI.
137 },
138 ],
139 },
140 &quot;name&quot;: &quot;A String&quot;, # Output only. The resource name of the RagFile.
141 &quot;sharePointSources&quot;: { # The SharePointSources to pass to ImportRagFiles. # The RagFile is imported from a SharePoint source.
142 &quot;sharePointSources&quot;: [ # The SharePoint sources.
143 { # An individual SharePointSource.
144 &quot;clientId&quot;: &quot;A String&quot;, # The Application ID for the app registered in Microsoft Azure Portal. The application must also be configured with MS Graph permissions &quot;Files.ReadAll&quot;, &quot;Sites.ReadAll&quot; and BrowserSiteLists.Read.All.
145 &quot;clientSecret&quot;: { # The API secret. # The application secret for the app registered in Azure.
146 &quot;apiKeySecretVersion&quot;: &quot;A String&quot;, # Required. The SecretManager secret version resource name storing API key. e.g. projects/{project}/secrets/{secret}/versions/{version}
147 &quot;apiKeyString&quot;: &quot;A String&quot;, # The API key string. Either this or `api_key_secret_version` must be set.
148 },
149 &quot;driveId&quot;: &quot;A String&quot;, # The ID of the drive to download from.
150 &quot;driveName&quot;: &quot;A String&quot;, # The name of the drive to download from.
151 &quot;fileId&quot;: &quot;A String&quot;, # Output only. The SharePoint file id. Output only.
152 &quot;sharepointFolderId&quot;: &quot;A String&quot;, # The ID of the SharePoint folder to download from.
153 &quot;sharepointFolderPath&quot;: &quot;A String&quot;, # The path of the SharePoint folder to download from.
154 &quot;sharepointSiteName&quot;: &quot;A String&quot;, # The name of the SharePoint site to download from. This can be the site name or the site id.
155 &quot;tenantId&quot;: &quot;A String&quot;, # Unique identifier of the Azure Active Directory Instance.
156 },
157 ],
158 },
159 &quot;slackSource&quot;: { # The Slack source for the ImportRagFilesRequest. # The RagFile is imported from a Slack channel.
160 &quot;channels&quot;: [ # Required. The Slack channels.
161 { # SlackChannels contains the Slack channels and corresponding access token.
162 &quot;apiKeyConfig&quot;: { # The API secret. # Required. The SecretManager secret version resource name (e.g. projects/{project}/secrets/{secret}/versions/{version}) storing the Slack channel access token that has access to the slack channel IDs. See: https://api.slack.com/tutorials/tracks/getting-a-token.
163 &quot;apiKeySecretVersion&quot;: &quot;A String&quot;, # Required. The SecretManager secret version resource name storing API key. e.g. projects/{project}/secrets/{secret}/versions/{version}
164 &quot;apiKeyString&quot;: &quot;A String&quot;, # The API key string. Either this or `api_key_secret_version` must be set.
165 },
166 &quot;channels&quot;: [ # Required. The Slack channel IDs.
167 { # SlackChannel contains the Slack channel ID and the time range to import.
168 &quot;channelId&quot;: &quot;A String&quot;, # Required. The Slack channel ID.
169 &quot;endTime&quot;: &quot;A String&quot;, # Optional. The ending timestamp for messages to import.
170 &quot;startTime&quot;: &quot;A String&quot;, # Optional. The starting timestamp for messages to import.
171 },
172 ],
173 },
174 ],
175 },
176 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this RagFile was last updated.
177 &quot;userMetadata&quot;: &quot;A String&quot;, # Output only. The metadata for metadata search. The user_metadata Needs to be in JSON format.
178 },
179 &quot;uploadRagFileConfig&quot;: { # Config for uploading RagFile. # Required. The config for the RagFiles to be uploaded into the RagCorpus. VertexRagDataService.UploadRagFile.
180 &quot;ragFileTransformationConfig&quot;: { # Specifies the transformation config for RagFiles. # Specifies the transformation config for RagFiles.
181 &quot;ragFileChunkingConfig&quot;: { # Specifies the size and overlap of chunks for RagFiles. # Specifies the chunking config for RagFiles.
182 &quot;fixedLengthChunking&quot;: { # Specifies the fixed length chunking config. # Specifies the fixed length chunking config.
183 &quot;chunkOverlap&quot;: 42, # The overlap between chunks.
184 &quot;chunkSize&quot;: 42, # The size of the chunks.
185 },
186 },
187 },
188 },
189 }
190
191 media_body: string, The filename of the media request body, or an instance of a MediaUpload object.
192 media_mime_type: string, The MIME type of the media request body, or an instance of a MediaUpload object.
193 x__xgafv: string, V1 error format.
194 Allowed values
195 1 - v1 error format
196 2 - v2 error format
197
198 Returns:
199 An object of the form:
200
201 { # Response message for VertexRagDataService.UploadRagFile.
202 &quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error that occurred while processing the RagFile.
203 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
204 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
205 {
206 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
207 },
208 ],
209 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
210 },
211 &quot;ragFile&quot;: { # A RagFile contains user data for chunking, embedding and indexing. # The RagFile that had been uploaded into the RagCorpus.
212 &quot;createTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this RagFile was created.
213 &quot;description&quot;: &quot;A String&quot;, # Optional. The description of the RagFile.
214 &quot;directUploadSource&quot;: { # The input content is encapsulated and uploaded in the request. # Output only. The RagFile is encapsulated and uploaded in the UploadRagFile request.
215 },
216 &quot;displayName&quot;: &quot;A String&quot;, # Required. The display name of the RagFile. The name can be up to 128 characters long and can consist of any UTF-8 characters.
217 &quot;fileStatus&quot;: { # RagFile status. # Output only. State of the RagFile.
218 &quot;errorStatus&quot;: &quot;A String&quot;, # Output only. Only when the `state` field is ERROR.
219 &quot;state&quot;: &quot;A String&quot;, # Output only. RagFile state.
220 },
221 &quot;gcsSource&quot;: { # The Google Cloud Storage location for the input content. # Output only. Google Cloud Storage location of the RagFile. It does not support wildcards in the Cloud Storage uri for now.
222 &quot;uris&quot;: [ # Required. Google Cloud Storage URI(-s) to the input file(s). May contain wildcards. For more information on wildcards, see https://cloud.google.com/storage/docs/wildcards.
223 &quot;A String&quot;,
224 ],
225 },
226 &quot;googleDriveSource&quot;: { # The Google Drive location for the input content. # Output only. Google Drive location. Supports importing individual files as well as Google Drive folders.
227 &quot;resourceIds&quot;: [ # Required. Google Drive resource IDs.
228 { # The type and ID of the Google Drive resource.
229 &quot;resourceId&quot;: &quot;A String&quot;, # Required. The ID of the Google Drive resource.
230 &quot;resourceType&quot;: &quot;A String&quot;, # Required. The type of the Google Drive resource.
231 },
232 ],
233 },
234 &quot;jiraSource&quot;: { # The Jira source for the ImportRagFilesRequest. # The RagFile is imported from a Jira query.
235 &quot;jiraQueries&quot;: [ # Required. The Jira queries.
236 { # JiraQueries contains the Jira queries and corresponding authentication.
237 &quot;apiKeyConfig&quot;: { # The API secret. # Required. The SecretManager secret version resource name (e.g. projects/{project}/secrets/{secret}/versions/{version}) storing the Jira API key. See [Manage API tokens for your Atlassian account](https://support.atlassian.com/atlassian-account/docs/manage-api-tokens-for-your-atlassian-account/).
238 &quot;apiKeySecretVersion&quot;: &quot;A String&quot;, # Required. The SecretManager secret version resource name storing API key. e.g. projects/{project}/secrets/{secret}/versions/{version}
239 &quot;apiKeyString&quot;: &quot;A String&quot;, # The API key string. Either this or `api_key_secret_version` must be set.
240 },
241 &quot;customQueries&quot;: [ # A list of custom Jira queries to import. For information about JQL (Jira Query Language), see https://support.atlassian.com/jira-service-management-cloud/docs/use-advanced-search-with-jira-query-language-jql/
242 &quot;A String&quot;,
243 ],
244 &quot;email&quot;: &quot;A String&quot;, # Required. The Jira email address.
245 &quot;projects&quot;: [ # A list of Jira projects to import in their entirety.
246 &quot;A String&quot;,
247 ],
248 &quot;serverUri&quot;: &quot;A String&quot;, # Required. The Jira server URI.
249 },
250 ],
251 },
252 &quot;name&quot;: &quot;A String&quot;, # Output only. The resource name of the RagFile.
253 &quot;sharePointSources&quot;: { # The SharePointSources to pass to ImportRagFiles. # The RagFile is imported from a SharePoint source.
254 &quot;sharePointSources&quot;: [ # The SharePoint sources.
255 { # An individual SharePointSource.
256 &quot;clientId&quot;: &quot;A String&quot;, # The Application ID for the app registered in Microsoft Azure Portal. The application must also be configured with MS Graph permissions &quot;Files.ReadAll&quot;, &quot;Sites.ReadAll&quot; and BrowserSiteLists.Read.All.
257 &quot;clientSecret&quot;: { # The API secret. # The application secret for the app registered in Azure.
258 &quot;apiKeySecretVersion&quot;: &quot;A String&quot;, # Required. The SecretManager secret version resource name storing API key. e.g. projects/{project}/secrets/{secret}/versions/{version}
259 &quot;apiKeyString&quot;: &quot;A String&quot;, # The API key string. Either this or `api_key_secret_version` must be set.
260 },
261 &quot;driveId&quot;: &quot;A String&quot;, # The ID of the drive to download from.
262 &quot;driveName&quot;: &quot;A String&quot;, # The name of the drive to download from.
263 &quot;fileId&quot;: &quot;A String&quot;, # Output only. The SharePoint file id. Output only.
264 &quot;sharepointFolderId&quot;: &quot;A String&quot;, # The ID of the SharePoint folder to download from.
265 &quot;sharepointFolderPath&quot;: &quot;A String&quot;, # The path of the SharePoint folder to download from.
266 &quot;sharepointSiteName&quot;: &quot;A String&quot;, # The name of the SharePoint site to download from. This can be the site name or the site id.
267 &quot;tenantId&quot;: &quot;A String&quot;, # Unique identifier of the Azure Active Directory Instance.
268 },
269 ],
270 },
271 &quot;slackSource&quot;: { # The Slack source for the ImportRagFilesRequest. # The RagFile is imported from a Slack channel.
272 &quot;channels&quot;: [ # Required. The Slack channels.
273 { # SlackChannels contains the Slack channels and corresponding access token.
274 &quot;apiKeyConfig&quot;: { # The API secret. # Required. The SecretManager secret version resource name (e.g. projects/{project}/secrets/{secret}/versions/{version}) storing the Slack channel access token that has access to the slack channel IDs. See: https://api.slack.com/tutorials/tracks/getting-a-token.
275 &quot;apiKeySecretVersion&quot;: &quot;A String&quot;, # Required. The SecretManager secret version resource name storing API key. e.g. projects/{project}/secrets/{secret}/versions/{version}
276 &quot;apiKeyString&quot;: &quot;A String&quot;, # The API key string. Either this or `api_key_secret_version` must be set.
277 },
278 &quot;channels&quot;: [ # Required. The Slack channel IDs.
279 { # SlackChannel contains the Slack channel ID and the time range to import.
280 &quot;channelId&quot;: &quot;A String&quot;, # Required. The Slack channel ID.
281 &quot;endTime&quot;: &quot;A String&quot;, # Optional. The ending timestamp for messages to import.
282 &quot;startTime&quot;: &quot;A String&quot;, # Optional. The starting timestamp for messages to import.
283 },
284 ],
285 },
286 ],
287 },
288 &quot;updateTime&quot;: &quot;A String&quot;, # Output only. Timestamp when this RagFile was last updated.
289 &quot;userMetadata&quot;: &quot;A String&quot;, # Output only. The metadata for metadata search. The user_metadata Needs to be in JSON format.
290 },
291 }</pre>
292 </div>
293
294 </body></html>