aws-sdk-qapps 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/CHANGELOG.md +8 -0
- data/LICENSE.txt +202 -0
- data/VERSION +1 -0
- data/lib/aws-sdk-qapps/client.rb +2443 -0
- data/lib/aws-sdk-qapps/client_api.rb +991 -0
- data/lib/aws-sdk-qapps/customizations.rb +0 -0
- data/lib/aws-sdk-qapps/endpoint_parameters.rb +66 -0
- data/lib/aws-sdk-qapps/endpoint_provider.rb +54 -0
- data/lib/aws-sdk-qapps/endpoints.rb +338 -0
- data/lib/aws-sdk-qapps/errors.rb +264 -0
- data/lib/aws-sdk-qapps/plugins/endpoints.rb +116 -0
- data/lib/aws-sdk-qapps/resource.rb +26 -0
- data/lib/aws-sdk-qapps/types.rb +2136 -0
- data/lib/aws-sdk-qapps/waiters.rb +15 -0
- data/lib/aws-sdk-qapps.rb +58 -0
- data/sig/client.rbs +625 -0
- data/sig/errors.rbs +57 -0
- data/sig/resource.rbs +80 -0
- data/sig/types.rbs +622 -0
- data/sig/waiters.rbs +13 -0
- metadata +100 -0
@@ -0,0 +1,2443 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# WARNING ABOUT GENERATED CODE
|
4
|
+
#
|
5
|
+
# This file is generated. See the contributing guide for more information:
|
6
|
+
# https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
|
7
|
+
#
|
8
|
+
# WARNING ABOUT GENERATED CODE
|
9
|
+
|
10
|
+
require 'seahorse/client/plugins/content_length.rb'
|
11
|
+
require 'aws-sdk-core/plugins/credentials_configuration.rb'
|
12
|
+
require 'aws-sdk-core/plugins/logging.rb'
|
13
|
+
require 'aws-sdk-core/plugins/param_converter.rb'
|
14
|
+
require 'aws-sdk-core/plugins/param_validator.rb'
|
15
|
+
require 'aws-sdk-core/plugins/user_agent.rb'
|
16
|
+
require 'aws-sdk-core/plugins/helpful_socket_errors.rb'
|
17
|
+
require 'aws-sdk-core/plugins/retry_errors.rb'
|
18
|
+
require 'aws-sdk-core/plugins/global_configuration.rb'
|
19
|
+
require 'aws-sdk-core/plugins/regional_endpoint.rb'
|
20
|
+
require 'aws-sdk-core/plugins/endpoint_discovery.rb'
|
21
|
+
require 'aws-sdk-core/plugins/endpoint_pattern.rb'
|
22
|
+
require 'aws-sdk-core/plugins/response_paging.rb'
|
23
|
+
require 'aws-sdk-core/plugins/stub_responses.rb'
|
24
|
+
require 'aws-sdk-core/plugins/idempotency_token.rb'
|
25
|
+
require 'aws-sdk-core/plugins/invocation_id.rb'
|
26
|
+
require 'aws-sdk-core/plugins/jsonvalue_converter.rb'
|
27
|
+
require 'aws-sdk-core/plugins/client_metrics_plugin.rb'
|
28
|
+
require 'aws-sdk-core/plugins/client_metrics_send_plugin.rb'
|
29
|
+
require 'aws-sdk-core/plugins/transfer_encoding.rb'
|
30
|
+
require 'aws-sdk-core/plugins/http_checksum.rb'
|
31
|
+
require 'aws-sdk-core/plugins/checksum_algorithm.rb'
|
32
|
+
require 'aws-sdk-core/plugins/request_compression.rb'
|
33
|
+
require 'aws-sdk-core/plugins/defaults_mode.rb'
|
34
|
+
require 'aws-sdk-core/plugins/recursion_detection.rb'
|
35
|
+
require 'aws-sdk-core/plugins/sign.rb'
|
36
|
+
require 'aws-sdk-core/plugins/protocols/rest_json.rb'
|
37
|
+
|
38
|
+
Aws::Plugins::GlobalConfiguration.add_identifier(:qapps)
|
39
|
+
|
40
|
+
module Aws::QApps
|
41
|
+
# An API client for QApps. To construct a client, you need to configure a `:region` and `:credentials`.
|
42
|
+
#
|
43
|
+
# client = Aws::QApps::Client.new(
|
44
|
+
# region: region_name,
|
45
|
+
# credentials: credentials,
|
46
|
+
# # ...
|
47
|
+
# )
|
48
|
+
#
|
49
|
+
# For details on configuring region and credentials see
|
50
|
+
# the [developer guide](/sdk-for-ruby/v3/developer-guide/setup-config.html).
|
51
|
+
#
|
52
|
+
# See {#initialize} for a full list of supported configuration options.
|
53
|
+
class Client < Seahorse::Client::Base
|
54
|
+
|
55
|
+
include Aws::ClientStubs
|
56
|
+
|
57
|
+
@identifier = :qapps
|
58
|
+
|
59
|
+
set_api(ClientApi::API)
|
60
|
+
|
61
|
+
add_plugin(Seahorse::Client::Plugins::ContentLength)
|
62
|
+
add_plugin(Aws::Plugins::CredentialsConfiguration)
|
63
|
+
add_plugin(Aws::Plugins::Logging)
|
64
|
+
add_plugin(Aws::Plugins::ParamConverter)
|
65
|
+
add_plugin(Aws::Plugins::ParamValidator)
|
66
|
+
add_plugin(Aws::Plugins::UserAgent)
|
67
|
+
add_plugin(Aws::Plugins::HelpfulSocketErrors)
|
68
|
+
add_plugin(Aws::Plugins::RetryErrors)
|
69
|
+
add_plugin(Aws::Plugins::GlobalConfiguration)
|
70
|
+
add_plugin(Aws::Plugins::RegionalEndpoint)
|
71
|
+
add_plugin(Aws::Plugins::EndpointDiscovery)
|
72
|
+
add_plugin(Aws::Plugins::EndpointPattern)
|
73
|
+
add_plugin(Aws::Plugins::ResponsePaging)
|
74
|
+
add_plugin(Aws::Plugins::StubResponses)
|
75
|
+
add_plugin(Aws::Plugins::IdempotencyToken)
|
76
|
+
add_plugin(Aws::Plugins::InvocationId)
|
77
|
+
add_plugin(Aws::Plugins::JsonvalueConverter)
|
78
|
+
add_plugin(Aws::Plugins::ClientMetricsPlugin)
|
79
|
+
add_plugin(Aws::Plugins::ClientMetricsSendPlugin)
|
80
|
+
add_plugin(Aws::Plugins::TransferEncoding)
|
81
|
+
add_plugin(Aws::Plugins::HttpChecksum)
|
82
|
+
add_plugin(Aws::Plugins::ChecksumAlgorithm)
|
83
|
+
add_plugin(Aws::Plugins::RequestCompression)
|
84
|
+
add_plugin(Aws::Plugins::DefaultsMode)
|
85
|
+
add_plugin(Aws::Plugins::RecursionDetection)
|
86
|
+
add_plugin(Aws::Plugins::Sign)
|
87
|
+
add_plugin(Aws::Plugins::Protocols::RestJson)
|
88
|
+
add_plugin(Aws::QApps::Plugins::Endpoints)
|
89
|
+
|
90
|
+
# @overload initialize(options)
|
91
|
+
# @param [Hash] options
|
92
|
+
#
|
93
|
+
# @option options [Array<Seahorse::Client::Plugin>] :plugins ([]])
|
94
|
+
# A list of plugins to apply to the client. Each plugin is either a
|
95
|
+
# class name or an instance of a plugin class.
|
96
|
+
#
|
97
|
+
# @option options [required, Aws::CredentialProvider] :credentials
|
98
|
+
# Your AWS credentials. This can be an instance of any one of the
|
99
|
+
# following classes:
|
100
|
+
#
|
101
|
+
# * `Aws::Credentials` - Used for configuring static, non-refreshing
|
102
|
+
# credentials.
|
103
|
+
#
|
104
|
+
# * `Aws::SharedCredentials` - Used for loading static credentials from a
|
105
|
+
# shared file, such as `~/.aws/config`.
|
106
|
+
#
|
107
|
+
# * `Aws::AssumeRoleCredentials` - Used when you need to assume a role.
|
108
|
+
#
|
109
|
+
# * `Aws::AssumeRoleWebIdentityCredentials` - Used when you need to
|
110
|
+
# assume a role after providing credentials via the web.
|
111
|
+
#
|
112
|
+
# * `Aws::SSOCredentials` - Used for loading credentials from AWS SSO using an
|
113
|
+
# access token generated from `aws login`.
|
114
|
+
#
|
115
|
+
# * `Aws::ProcessCredentials` - Used for loading credentials from a
|
116
|
+
# process that outputs to stdout.
|
117
|
+
#
|
118
|
+
# * `Aws::InstanceProfileCredentials` - Used for loading credentials
|
119
|
+
# from an EC2 IMDS on an EC2 instance.
|
120
|
+
#
|
121
|
+
# * `Aws::ECSCredentials` - Used for loading credentials from
|
122
|
+
# instances running in ECS.
|
123
|
+
#
|
124
|
+
# * `Aws::CognitoIdentityCredentials` - Used for loading credentials
|
125
|
+
# from the Cognito Identity service.
|
126
|
+
#
|
127
|
+
# When `:credentials` are not configured directly, the following
|
128
|
+
# locations will be searched for credentials:
|
129
|
+
#
|
130
|
+
# * `Aws.config[:credentials]`
|
131
|
+
# * The `:access_key_id`, `:secret_access_key`, and `:session_token` options.
|
132
|
+
# * ENV['AWS_ACCESS_KEY_ID'], ENV['AWS_SECRET_ACCESS_KEY']
|
133
|
+
# * `~/.aws/credentials`
|
134
|
+
# * `~/.aws/config`
|
135
|
+
# * EC2/ECS IMDS instance profile - When used by default, the timeouts
|
136
|
+
# are very aggressive. Construct and pass an instance of
|
137
|
+
# `Aws::InstanceProfileCredentails` or `Aws::ECSCredentials` to
|
138
|
+
# enable retries and extended timeouts. Instance profile credential
|
139
|
+
# fetching can be disabled by setting ENV['AWS_EC2_METADATA_DISABLED']
|
140
|
+
# to true.
|
141
|
+
#
|
142
|
+
# @option options [required, String] :region
|
143
|
+
# The AWS region to connect to. The configured `:region` is
|
144
|
+
# used to determine the service `:endpoint`. When not passed,
|
145
|
+
# a default `:region` is searched for in the following locations:
|
146
|
+
#
|
147
|
+
# * `Aws.config[:region]`
|
148
|
+
# * `ENV['AWS_REGION']`
|
149
|
+
# * `ENV['AMAZON_REGION']`
|
150
|
+
# * `ENV['AWS_DEFAULT_REGION']`
|
151
|
+
# * `~/.aws/credentials`
|
152
|
+
# * `~/.aws/config`
|
153
|
+
#
|
154
|
+
# @option options [String] :access_key_id
|
155
|
+
#
|
156
|
+
# @option options [Boolean] :active_endpoint_cache (false)
|
157
|
+
# When set to `true`, a thread polling for endpoints will be running in
|
158
|
+
# the background every 60 secs (default). Defaults to `false`.
|
159
|
+
#
|
160
|
+
# @option options [Boolean] :adaptive_retry_wait_to_fill (true)
|
161
|
+
# Used only in `adaptive` retry mode. When true, the request will sleep
|
162
|
+
# until there is sufficent client side capacity to retry the request.
|
163
|
+
# When false, the request will raise a `RetryCapacityNotAvailableError` and will
|
164
|
+
# not retry instead of sleeping.
|
165
|
+
#
|
166
|
+
# @option options [Boolean] :client_side_monitoring (false)
|
167
|
+
# When `true`, client-side metrics will be collected for all API requests from
|
168
|
+
# this client.
|
169
|
+
#
|
170
|
+
# @option options [String] :client_side_monitoring_client_id ("")
|
171
|
+
# Allows you to provide an identifier for this client which will be attached to
|
172
|
+
# all generated client side metrics. Defaults to an empty string.
|
173
|
+
#
|
174
|
+
# @option options [String] :client_side_monitoring_host ("127.0.0.1")
|
175
|
+
# Allows you to specify the DNS hostname or IPv4 or IPv6 address that the client
|
176
|
+
# side monitoring agent is running on, where client metrics will be published via UDP.
|
177
|
+
#
|
178
|
+
# @option options [Integer] :client_side_monitoring_port (31000)
|
179
|
+
# Required for publishing client metrics. The port that the client side monitoring
|
180
|
+
# agent is running on, where client metrics will be published via UDP.
|
181
|
+
#
|
182
|
+
# @option options [Aws::ClientSideMonitoring::Publisher] :client_side_monitoring_publisher (Aws::ClientSideMonitoring::Publisher)
|
183
|
+
# Allows you to provide a custom client-side monitoring publisher class. By default,
|
184
|
+
# will use the Client Side Monitoring Agent Publisher.
|
185
|
+
#
|
186
|
+
# @option options [Boolean] :convert_params (true)
|
187
|
+
# When `true`, an attempt is made to coerce request parameters into
|
188
|
+
# the required types.
|
189
|
+
#
|
190
|
+
# @option options [Boolean] :correct_clock_skew (true)
|
191
|
+
# Used only in `standard` and adaptive retry modes. Specifies whether to apply
|
192
|
+
# a clock skew correction and retry requests with skewed client clocks.
|
193
|
+
#
|
194
|
+
# @option options [String] :defaults_mode ("legacy")
|
195
|
+
# See {Aws::DefaultsModeConfiguration} for a list of the
|
196
|
+
# accepted modes and the configuration defaults that are included.
|
197
|
+
#
|
198
|
+
# @option options [Boolean] :disable_host_prefix_injection (false)
|
199
|
+
# Set to true to disable SDK automatically adding host prefix
|
200
|
+
# to default service endpoint when available.
|
201
|
+
#
|
202
|
+
# @option options [Boolean] :disable_request_compression (false)
|
203
|
+
# When set to 'true' the request body will not be compressed
|
204
|
+
# for supported operations.
|
205
|
+
#
|
206
|
+
# @option options [String, URI::HTTPS, URI::HTTP] :endpoint
|
207
|
+
# Normally you should not configure the `:endpoint` option
|
208
|
+
# directly. This is normally constructed from the `:region`
|
209
|
+
# option. Configuring `:endpoint` is normally reserved for
|
210
|
+
# connecting to test or custom endpoints. The endpoint should
|
211
|
+
# be a URI formatted like:
|
212
|
+
#
|
213
|
+
# 'http://example.com'
|
214
|
+
# 'https://example.com'
|
215
|
+
# 'http://example.com:123'
|
216
|
+
#
|
217
|
+
# @option options [Integer] :endpoint_cache_max_entries (1000)
|
218
|
+
# Used for the maximum size limit of the LRU cache storing endpoints data
|
219
|
+
# for endpoint discovery enabled operations. Defaults to 1000.
|
220
|
+
#
|
221
|
+
# @option options [Integer] :endpoint_cache_max_threads (10)
|
222
|
+
# Used for the maximum threads in use for polling endpoints to be cached, defaults to 10.
|
223
|
+
#
|
224
|
+
# @option options [Integer] :endpoint_cache_poll_interval (60)
|
225
|
+
# When :endpoint_discovery and :active_endpoint_cache is enabled,
|
226
|
+
# Use this option to config the time interval in seconds for making
|
227
|
+
# requests fetching endpoints information. Defaults to 60 sec.
|
228
|
+
#
|
229
|
+
# @option options [Boolean] :endpoint_discovery (false)
|
230
|
+
# When set to `true`, endpoint discovery will be enabled for operations when available.
|
231
|
+
#
|
232
|
+
# @option options [Boolean] :ignore_configured_endpoint_urls
|
233
|
+
# Setting to true disables use of endpoint URLs provided via environment
|
234
|
+
# variables and the shared configuration file.
|
235
|
+
#
|
236
|
+
# @option options [Aws::Log::Formatter] :log_formatter (Aws::Log::Formatter.default)
|
237
|
+
# The log formatter.
|
238
|
+
#
|
239
|
+
# @option options [Symbol] :log_level (:info)
|
240
|
+
# The log level to send messages to the `:logger` at.
|
241
|
+
#
|
242
|
+
# @option options [Logger] :logger
|
243
|
+
# The Logger instance to send log messages to. If this option
|
244
|
+
# is not set, logging will be disabled.
|
245
|
+
#
|
246
|
+
# @option options [Integer] :max_attempts (3)
|
247
|
+
# An integer representing the maximum number attempts that will be made for
|
248
|
+
# a single request, including the initial attempt. For example,
|
249
|
+
# setting this value to 5 will result in a request being retried up to
|
250
|
+
# 4 times. Used in `standard` and `adaptive` retry modes.
|
251
|
+
#
|
252
|
+
# @option options [String] :profile ("default")
|
253
|
+
# Used when loading credentials from the shared credentials file
|
254
|
+
# at HOME/.aws/credentials. When not specified, 'default' is used.
|
255
|
+
#
|
256
|
+
# @option options [Integer] :request_min_compression_size_bytes (10240)
|
257
|
+
# The minimum size in bytes that triggers compression for request
|
258
|
+
# bodies. The value must be non-negative integer value between 0
|
259
|
+
# and 10485780 bytes inclusive.
|
260
|
+
#
|
261
|
+
# @option options [Proc] :retry_backoff
|
262
|
+
# A proc or lambda used for backoff. Defaults to 2**retries * retry_base_delay.
|
263
|
+
# This option is only used in the `legacy` retry mode.
|
264
|
+
#
|
265
|
+
# @option options [Float] :retry_base_delay (0.3)
|
266
|
+
# The base delay in seconds used by the default backoff function. This option
|
267
|
+
# is only used in the `legacy` retry mode.
|
268
|
+
#
|
269
|
+
# @option options [Symbol] :retry_jitter (:none)
|
270
|
+
# A delay randomiser function used by the default backoff function.
|
271
|
+
# Some predefined functions can be referenced by name - :none, :equal, :full,
|
272
|
+
# otherwise a Proc that takes and returns a number. This option is only used
|
273
|
+
# in the `legacy` retry mode.
|
274
|
+
#
|
275
|
+
# @see https://www.awsarchitectureblog.com/2015/03/backoff.html
|
276
|
+
#
|
277
|
+
# @option options [Integer] :retry_limit (3)
|
278
|
+
# The maximum number of times to retry failed requests. Only
|
279
|
+
# ~ 500 level server errors and certain ~ 400 level client errors
|
280
|
+
# are retried. Generally, these are throttling errors, data
|
281
|
+
# checksum errors, networking errors, timeout errors, auth errors,
|
282
|
+
# endpoint discovery, and errors from expired credentials.
|
283
|
+
# This option is only used in the `legacy` retry mode.
|
284
|
+
#
|
285
|
+
# @option options [Integer] :retry_max_delay (0)
|
286
|
+
# The maximum number of seconds to delay between retries (0 for no limit)
|
287
|
+
# used by the default backoff function. This option is only used in the
|
288
|
+
# `legacy` retry mode.
|
289
|
+
#
|
290
|
+
# @option options [String] :retry_mode ("legacy")
|
291
|
+
# Specifies which retry algorithm to use. Values are:
|
292
|
+
#
|
293
|
+
# * `legacy` - The pre-existing retry behavior. This is default value if
|
294
|
+
# no retry mode is provided.
|
295
|
+
#
|
296
|
+
# * `standard` - A standardized set of retry rules across the AWS SDKs.
|
297
|
+
# This includes support for retry quotas, which limit the number of
|
298
|
+
# unsuccessful retries a client can make.
|
299
|
+
#
|
300
|
+
# * `adaptive` - An experimental retry mode that includes all the
|
301
|
+
# functionality of `standard` mode along with automatic client side
|
302
|
+
# throttling. This is a provisional mode that may change behavior
|
303
|
+
# in the future.
|
304
|
+
#
|
305
|
+
# @option options [String] :sdk_ua_app_id
|
306
|
+
# A unique and opaque application ID that is appended to the
|
307
|
+
# User-Agent header as app/sdk_ua_app_id. It should have a
|
308
|
+
# maximum length of 50. This variable is sourced from environment
|
309
|
+
# variable AWS_SDK_UA_APP_ID or the shared config profile attribute sdk_ua_app_id.
|
310
|
+
#
|
311
|
+
# @option options [String] :secret_access_key
|
312
|
+
#
|
313
|
+
# @option options [String] :session_token
|
314
|
+
#
|
315
|
+
# @option options [Array] :sigv4a_signing_region_set
|
316
|
+
# A list of regions that should be signed with SigV4a signing. When
|
317
|
+
# not passed, a default `:sigv4a_signing_region_set` is searched for
|
318
|
+
# in the following locations:
|
319
|
+
#
|
320
|
+
# * `Aws.config[:sigv4a_signing_region_set]`
|
321
|
+
# * `ENV['AWS_SIGV4A_SIGNING_REGION_SET']`
|
322
|
+
# * `~/.aws/config`
|
323
|
+
#
|
324
|
+
# @option options [Boolean] :stub_responses (false)
|
325
|
+
# Causes the client to return stubbed responses. By default
|
326
|
+
# fake responses are generated and returned. You can specify
|
327
|
+
# the response data to return or errors to raise by calling
|
328
|
+
# {ClientStubs#stub_responses}. See {ClientStubs} for more information.
|
329
|
+
#
|
330
|
+
# ** Please note ** When response stubbing is enabled, no HTTP
|
331
|
+
# requests are made, and retries are disabled.
|
332
|
+
#
|
333
|
+
# @option options [Aws::TokenProvider] :token_provider
|
334
|
+
# A Bearer Token Provider. This can be an instance of any one of the
|
335
|
+
# following classes:
|
336
|
+
#
|
337
|
+
# * `Aws::StaticTokenProvider` - Used for configuring static, non-refreshing
|
338
|
+
# tokens.
|
339
|
+
#
|
340
|
+
# * `Aws::SSOTokenProvider` - Used for loading tokens from AWS SSO using an
|
341
|
+
# access token generated from `aws login`.
|
342
|
+
#
|
343
|
+
# When `:token_provider` is not configured directly, the `Aws::TokenProviderChain`
|
344
|
+
# will be used to search for tokens configured for your profile in shared configuration files.
|
345
|
+
#
|
346
|
+
# @option options [Boolean] :use_dualstack_endpoint
|
347
|
+
# When set to `true`, dualstack enabled endpoints (with `.aws` TLD)
|
348
|
+
# will be used if available.
|
349
|
+
#
|
350
|
+
# @option options [Boolean] :use_fips_endpoint
|
351
|
+
# When set to `true`, fips compatible endpoints will be used if available.
|
352
|
+
# When a `fips` region is used, the region is normalized and this config
|
353
|
+
# is set to `true`.
|
354
|
+
#
|
355
|
+
# @option options [Boolean] :validate_params (true)
|
356
|
+
# When `true`, request parameters are validated before
|
357
|
+
# sending the request.
|
358
|
+
#
|
359
|
+
# @option options [Aws::QApps::EndpointProvider] :endpoint_provider
|
360
|
+
# The endpoint provider used to resolve endpoints. Any object that responds to `#resolve_endpoint(parameters)` where `parameters` is a Struct similar to `Aws::QApps::EndpointParameters`
|
361
|
+
#
|
362
|
+
# @option options [Float] :http_continue_timeout (1)
|
363
|
+
# The number of seconds to wait for a 100-continue response before sending the
|
364
|
+
# request body. This option has no effect unless the request has "Expect"
|
365
|
+
# header set to "100-continue". Defaults to `nil` which disables this
|
366
|
+
# behaviour. This value can safely be set per request on the session.
|
367
|
+
#
|
368
|
+
# @option options [Float] :http_idle_timeout (5)
|
369
|
+
# The number of seconds a connection is allowed to sit idle before it
|
370
|
+
# is considered stale. Stale connections are closed and removed from the
|
371
|
+
# pool before making a request.
|
372
|
+
#
|
373
|
+
# @option options [Float] :http_open_timeout (15)
|
374
|
+
# The default number of seconds to wait for response data.
|
375
|
+
# This value can safely be set per-request on the session.
|
376
|
+
#
|
377
|
+
# @option options [URI::HTTP,String] :http_proxy
|
378
|
+
# A proxy to send requests through. Formatted like 'http://proxy.com:123'.
|
379
|
+
#
|
380
|
+
# @option options [Float] :http_read_timeout (60)
|
381
|
+
# The default number of seconds to wait for response data.
|
382
|
+
# This value can safely be set per-request on the session.
|
383
|
+
#
|
384
|
+
# @option options [Boolean] :http_wire_trace (false)
|
385
|
+
# When `true`, HTTP debug output will be sent to the `:logger`.
|
386
|
+
#
|
387
|
+
# @option options [Proc] :on_chunk_received
|
388
|
+
# When a Proc object is provided, it will be used as callback when each chunk
|
389
|
+
# of the response body is received. It provides three arguments: the chunk,
|
390
|
+
# the number of bytes received, and the total number of
|
391
|
+
# bytes in the response (or nil if the server did not send a `content-length`).
|
392
|
+
#
|
393
|
+
# @option options [Proc] :on_chunk_sent
|
394
|
+
# When a Proc object is provided, it will be used as callback when each chunk
|
395
|
+
# of the request body is sent. It provides three arguments: the chunk,
|
396
|
+
# the number of bytes read from the body, and the total number of
|
397
|
+
# bytes in the body.
|
398
|
+
#
|
399
|
+
# @option options [Boolean] :raise_response_errors (true)
|
400
|
+
# When `true`, response errors are raised.
|
401
|
+
#
|
402
|
+
# @option options [String] :ssl_ca_bundle
|
403
|
+
# Full path to the SSL certificate authority bundle file that should be used when
|
404
|
+
# verifying peer certificates. If you do not pass `:ssl_ca_bundle` or
|
405
|
+
# `:ssl_ca_directory` the the system default will be used if available.
|
406
|
+
#
|
407
|
+
# @option options [String] :ssl_ca_directory
|
408
|
+
# Full path of the directory that contains the unbundled SSL certificate
|
409
|
+
# authority files for verifying peer certificates. If you do
|
410
|
+
# not pass `:ssl_ca_bundle` or `:ssl_ca_directory` the the system
|
411
|
+
# default will be used if available.
|
412
|
+
#
|
413
|
+
# @option options [String] :ssl_ca_store
|
414
|
+
# Sets the X509::Store to verify peer certificate.
|
415
|
+
#
|
416
|
+
# @option options [Float] :ssl_timeout
|
417
|
+
# Sets the SSL timeout in seconds
|
418
|
+
#
|
419
|
+
# @option options [Boolean] :ssl_verify_peer (true)
|
420
|
+
# When `true`, SSL peer certificates are verified when establishing a connection.
|
421
|
+
#
|
422
|
+
def initialize(*args)
|
423
|
+
super
|
424
|
+
end
|
425
|
+
|
426
|
+
# @!group API Operations
|
427
|
+
|
428
|
+
# Associates a rating or review for a library item with the user
|
429
|
+
# submitting the request. This increments the rating count for the
|
430
|
+
# specified library item.
|
431
|
+
#
|
432
|
+
# @option params [required, String] :instance_id
|
433
|
+
# The unique identifier for the Amazon Q Business application
|
434
|
+
# environment instance.
|
435
|
+
#
|
436
|
+
# @option params [required, String] :library_item_id
|
437
|
+
# The unique identifier of the library item to associate the review
|
438
|
+
# with.
|
439
|
+
#
|
440
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
441
|
+
#
|
442
|
+
#
|
443
|
+
# @example Example: Increase the rating counter by 1 for the related app for this user
|
444
|
+
#
|
445
|
+
# resp = client.associate_library_item_review({
|
446
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
447
|
+
# library_item_id: "cb9ecf72-8563-450d-9db9-994f98297316",
|
448
|
+
# })
|
449
|
+
#
|
450
|
+
# @example Request syntax with placeholder values
|
451
|
+
#
|
452
|
+
# resp = client.associate_library_item_review({
|
453
|
+
# instance_id: "InstanceId", # required
|
454
|
+
# library_item_id: "UUID", # required
|
455
|
+
# })
|
456
|
+
#
|
457
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/AssociateLibraryItemReview AWS API Documentation
|
458
|
+
#
|
459
|
+
# @overload associate_library_item_review(params = {})
|
460
|
+
# @param [Hash] params ({})
|
461
|
+
def associate_library_item_review(params = {}, options = {})
|
462
|
+
req = build_request(:associate_library_item_review, params)
|
463
|
+
req.send_request(options)
|
464
|
+
end
|
465
|
+
|
466
|
+
# This operation creates a link between the user's identity calling the
|
467
|
+
# operation and a specific Q App. This is useful to mark the Q App as a
|
468
|
+
# *favorite* for the user if the user doesn't own the Amazon Q App so
|
469
|
+
# they can still run it and see it in their inventory of Q Apps.
|
470
|
+
#
|
471
|
+
# @option params [required, String] :instance_id
|
472
|
+
# The unique identifier of the Amazon Q Business application environment
|
473
|
+
# instance.
|
474
|
+
#
|
475
|
+
# @option params [required, String] :app_id
|
476
|
+
# The ID of the Amazon Q App to associate with the user.
|
477
|
+
#
|
478
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
479
|
+
#
|
480
|
+
#
|
481
|
+
# @example Example: Links an Amazon Q App to the invoker's list of apps
|
482
|
+
#
|
483
|
+
# resp = client.associate_q_app_with_user({
|
484
|
+
# app_id: "393e77fb-0a30-4f47-ad30-75d71aeaed8a",
|
485
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
486
|
+
# })
|
487
|
+
#
|
488
|
+
# @example Request syntax with placeholder values
|
489
|
+
#
|
490
|
+
# resp = client.associate_q_app_with_user({
|
491
|
+
# instance_id: "InstanceId", # required
|
492
|
+
# app_id: "UUID", # required
|
493
|
+
# })
|
494
|
+
#
|
495
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/AssociateQAppWithUser AWS API Documentation
|
496
|
+
#
|
497
|
+
# @overload associate_q_app_with_user(params = {})
|
498
|
+
# @param [Hash] params ({})
|
499
|
+
def associate_q_app_with_user(params = {}, options = {})
|
500
|
+
req = build_request(:associate_q_app_with_user, params)
|
501
|
+
req.send_request(options)
|
502
|
+
end
|
503
|
+
|
504
|
+
# Creates a new library item for an Amazon Q App, allowing it to be
|
505
|
+
# discovered and used by other allowed users.
|
506
|
+
#
|
507
|
+
# @option params [required, String] :instance_id
|
508
|
+
# The unique identifier of the Amazon Q Business application environment
|
509
|
+
# instance.
|
510
|
+
#
|
511
|
+
# @option params [required, String] :app_id
|
512
|
+
# The unique identifier of the Amazon Q App to publish to the library.
|
513
|
+
#
|
514
|
+
# @option params [required, Integer] :app_version
|
515
|
+
# The version of the Amazon Q App to publish to the library.
|
516
|
+
#
|
517
|
+
# @option params [required, Array<String>] :categories
|
518
|
+
# The categories to associate with the library item for easier
|
519
|
+
# discovery.
|
520
|
+
#
|
521
|
+
# @return [Types::CreateLibraryItemOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
522
|
+
#
|
523
|
+
# * {Types::CreateLibraryItemOutput#library_item_id #library_item_id} => String
|
524
|
+
# * {Types::CreateLibraryItemOutput#status #status} => String
|
525
|
+
# * {Types::CreateLibraryItemOutput#created_at #created_at} => Time
|
526
|
+
# * {Types::CreateLibraryItemOutput#created_by #created_by} => String
|
527
|
+
# * {Types::CreateLibraryItemOutput#updated_at #updated_at} => Time
|
528
|
+
# * {Types::CreateLibraryItemOutput#updated_by #updated_by} => String
|
529
|
+
# * {Types::CreateLibraryItemOutput#rating_count #rating_count} => Integer
|
530
|
+
#
|
531
|
+
#
|
532
|
+
# @example Example: Create a Library Item
|
533
|
+
#
|
534
|
+
# resp = client.create_library_item({
|
535
|
+
# app_id: "7a11f34b-42d4-4bc8-b668-ae4a788dae1e",
|
536
|
+
# app_version: 6,
|
537
|
+
# categories: [
|
538
|
+
# "9c871ed4-1c41-4065-aefe-321cd4b61cf8",
|
539
|
+
# ],
|
540
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
541
|
+
# })
|
542
|
+
#
|
543
|
+
# resp.to_h outputs the following:
|
544
|
+
# {
|
545
|
+
# created_at: Time.parse("2024-05-21T23:17:27.350Z"),
|
546
|
+
# created_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
547
|
+
# library_item_id: "cb9ecf72-8563-450d-9db9-994f98297316",
|
548
|
+
# rating_count: 0,
|
549
|
+
# status: "PUBLISHED",
|
550
|
+
# updated_at: Time.parse("2024-05-21T23:17:27.350Z"),
|
551
|
+
# updated_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
552
|
+
# }
|
553
|
+
#
|
554
|
+
# @example Request syntax with placeholder values
|
555
|
+
#
|
556
|
+
# resp = client.create_library_item({
|
557
|
+
# instance_id: "InstanceId", # required
|
558
|
+
# app_id: "UUID", # required
|
559
|
+
# app_version: 1, # required
|
560
|
+
# categories: ["UUID"], # required
|
561
|
+
# })
|
562
|
+
#
|
563
|
+
# @example Response structure
|
564
|
+
#
|
565
|
+
# resp.library_item_id #=> String
|
566
|
+
# resp.status #=> String
|
567
|
+
# resp.created_at #=> Time
|
568
|
+
# resp.created_by #=> String
|
569
|
+
# resp.updated_at #=> Time
|
570
|
+
# resp.updated_by #=> String
|
571
|
+
# resp.rating_count #=> Integer
|
572
|
+
#
|
573
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/CreateLibraryItem AWS API Documentation
|
574
|
+
#
|
575
|
+
# @overload create_library_item(params = {})
|
576
|
+
# @param [Hash] params ({})
|
577
|
+
def create_library_item(params = {}, options = {})
|
578
|
+
req = build_request(:create_library_item, params)
|
579
|
+
req.send_request(options)
|
580
|
+
end
|
581
|
+
|
582
|
+
# Creates a new Amazon Q App based on the provided definition. The Q App
|
583
|
+
# definition specifies the cards and flow of the Q App. This operation
|
584
|
+
# also calculates the dependencies between the cards by inspecting the
|
585
|
+
# references in the prompts.
|
586
|
+
#
|
587
|
+
# @option params [required, String] :instance_id
|
588
|
+
# The unique identifier of the Amazon Q Business application environment
|
589
|
+
# instance.
|
590
|
+
#
|
591
|
+
# @option params [required, String] :title
|
592
|
+
# The title of the new Q App.
|
593
|
+
#
|
594
|
+
# @option params [String] :description
|
595
|
+
# The description of the new Q App.
|
596
|
+
#
|
597
|
+
# @option params [required, Types::AppDefinitionInput] :app_definition
|
598
|
+
# The definition of the new Q App, specifying the cards and flow.
|
599
|
+
#
|
600
|
+
# @option params [Hash<String,String>] :tags
|
601
|
+
# Optional tags to associate with the new Q App.
|
602
|
+
#
|
603
|
+
# @return [Types::CreateQAppOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
604
|
+
#
|
605
|
+
# * {Types::CreateQAppOutput#app_id #app_id} => String
|
606
|
+
# * {Types::CreateQAppOutput#app_arn #app_arn} => String
|
607
|
+
# * {Types::CreateQAppOutput#title #title} => String
|
608
|
+
# * {Types::CreateQAppOutput#description #description} => String
|
609
|
+
# * {Types::CreateQAppOutput#initial_prompt #initial_prompt} => String
|
610
|
+
# * {Types::CreateQAppOutput#app_version #app_version} => Integer
|
611
|
+
# * {Types::CreateQAppOutput#status #status} => String
|
612
|
+
# * {Types::CreateQAppOutput#created_at #created_at} => Time
|
613
|
+
# * {Types::CreateQAppOutput#created_by #created_by} => String
|
614
|
+
# * {Types::CreateQAppOutput#updated_at #updated_at} => Time
|
615
|
+
# * {Types::CreateQAppOutput#updated_by #updated_by} => String
|
616
|
+
# * {Types::CreateQAppOutput#required_capabilities #required_capabilities} => Array<String>
|
617
|
+
#
|
618
|
+
#
|
619
|
+
# @example Example: A basic application with 1 text input card and 1 output card
|
620
|
+
#
|
621
|
+
# resp = client.create_q_app({
|
622
|
+
# app_definition: {
|
623
|
+
# cards: [
|
624
|
+
# {
|
625
|
+
# text_input: {
|
626
|
+
# type: "text-input",
|
627
|
+
# id: "4cf94d96-8819-45c2-98cc-58c56b35c72f",
|
628
|
+
# title: "Color Base",
|
629
|
+
# },
|
630
|
+
# },
|
631
|
+
# {
|
632
|
+
# q_query: {
|
633
|
+
# type: "q-query",
|
634
|
+
# id: "18870b94-1e63-40e0-8c12-669c90ac5acc",
|
635
|
+
# prompt: "Recommend me a list of colors that go well with @4cf94d96-8819-45c2-98cc-58c56b35c72f",
|
636
|
+
# title: "Recommended Palette",
|
637
|
+
# },
|
638
|
+
# },
|
639
|
+
# ],
|
640
|
+
# initial_prompt: "Create an app that recommend a list of colors based on input.",
|
641
|
+
# },
|
642
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
643
|
+
# title: "Color Palette Generator",
|
644
|
+
# })
|
645
|
+
#
|
646
|
+
# resp.to_h outputs the following:
|
647
|
+
# {
|
648
|
+
# app_arn: "arn:aws:qapps:us-west-2:123456789012:app/7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
649
|
+
# app_id: "7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
650
|
+
# app_version: 1,
|
651
|
+
# created_at: Time.parse("2024-05-14T00:11:54.232Z"),
|
652
|
+
# created_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
653
|
+
# initial_prompt: "Create an app that recommend a list of colors based on input.",
|
654
|
+
# required_capabilities: [
|
655
|
+
# "CreatorMode",
|
656
|
+
# ],
|
657
|
+
# status: "DRAFT",
|
658
|
+
# title: "Color Palette Generator",
|
659
|
+
# updated_at: Time.parse("2024-05-14T00:13:26.168Z"),
|
660
|
+
# updated_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
661
|
+
# }
|
662
|
+
#
|
663
|
+
# @example Request syntax with placeholder values
|
664
|
+
#
|
665
|
+
# resp = client.create_q_app({
|
666
|
+
# instance_id: "InstanceId", # required
|
667
|
+
# title: "Title", # required
|
668
|
+
# description: "Description",
|
669
|
+
# app_definition: { # required
|
670
|
+
# cards: [ # required
|
671
|
+
# {
|
672
|
+
# text_input: {
|
673
|
+
# title: "Title", # required
|
674
|
+
# id: "UUID", # required
|
675
|
+
# type: "text-input", # required, accepts text-input, q-query, file-upload, q-plugin
|
676
|
+
# placeholder: "Placeholder",
|
677
|
+
# default_value: "Default",
|
678
|
+
# },
|
679
|
+
# q_query: {
|
680
|
+
# title: "Title", # required
|
681
|
+
# id: "UUID", # required
|
682
|
+
# type: "text-input", # required, accepts text-input, q-query, file-upload, q-plugin
|
683
|
+
# prompt: "Prompt", # required
|
684
|
+
# output_source: "approved-sources", # accepts approved-sources, llm
|
685
|
+
# attribute_filter: {
|
686
|
+
# and_all_filters: [
|
687
|
+
# {
|
688
|
+
# # recursive AttributeFilter
|
689
|
+
# },
|
690
|
+
# ],
|
691
|
+
# or_all_filters: [
|
692
|
+
# {
|
693
|
+
# # recursive AttributeFilter
|
694
|
+
# },
|
695
|
+
# ],
|
696
|
+
# not_filter: {
|
697
|
+
# # recursive AttributeFilter
|
698
|
+
# },
|
699
|
+
# equals_to: {
|
700
|
+
# name: "DocumentAttributeKey", # required
|
701
|
+
# value: { # required
|
702
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
703
|
+
# string_list_value: ["PlatoString"],
|
704
|
+
# long_value: 1,
|
705
|
+
# date_value: Time.now,
|
706
|
+
# },
|
707
|
+
# },
|
708
|
+
# contains_all: {
|
709
|
+
# name: "DocumentAttributeKey", # required
|
710
|
+
# value: { # required
|
711
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
712
|
+
# string_list_value: ["PlatoString"],
|
713
|
+
# long_value: 1,
|
714
|
+
# date_value: Time.now,
|
715
|
+
# },
|
716
|
+
# },
|
717
|
+
# contains_any: {
|
718
|
+
# name: "DocumentAttributeKey", # required
|
719
|
+
# value: { # required
|
720
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
721
|
+
# string_list_value: ["PlatoString"],
|
722
|
+
# long_value: 1,
|
723
|
+
# date_value: Time.now,
|
724
|
+
# },
|
725
|
+
# },
|
726
|
+
# greater_than: {
|
727
|
+
# name: "DocumentAttributeKey", # required
|
728
|
+
# value: { # required
|
729
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
730
|
+
# string_list_value: ["PlatoString"],
|
731
|
+
# long_value: 1,
|
732
|
+
# date_value: Time.now,
|
733
|
+
# },
|
734
|
+
# },
|
735
|
+
# greater_than_or_equals: {
|
736
|
+
# name: "DocumentAttributeKey", # required
|
737
|
+
# value: { # required
|
738
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
739
|
+
# string_list_value: ["PlatoString"],
|
740
|
+
# long_value: 1,
|
741
|
+
# date_value: Time.now,
|
742
|
+
# },
|
743
|
+
# },
|
744
|
+
# less_than: {
|
745
|
+
# name: "DocumentAttributeKey", # required
|
746
|
+
# value: { # required
|
747
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
748
|
+
# string_list_value: ["PlatoString"],
|
749
|
+
# long_value: 1,
|
750
|
+
# date_value: Time.now,
|
751
|
+
# },
|
752
|
+
# },
|
753
|
+
# less_than_or_equals: {
|
754
|
+
# name: "DocumentAttributeKey", # required
|
755
|
+
# value: { # required
|
756
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
757
|
+
# string_list_value: ["PlatoString"],
|
758
|
+
# long_value: 1,
|
759
|
+
# date_value: Time.now,
|
760
|
+
# },
|
761
|
+
# },
|
762
|
+
# },
|
763
|
+
# },
|
764
|
+
# q_plugin: {
|
765
|
+
# title: "Title", # required
|
766
|
+
# id: "UUID", # required
|
767
|
+
# type: "text-input", # required, accepts text-input, q-query, file-upload, q-plugin
|
768
|
+
# prompt: "Prompt", # required
|
769
|
+
# plugin_id: "PluginId", # required
|
770
|
+
# },
|
771
|
+
# file_upload: {
|
772
|
+
# title: "Title", # required
|
773
|
+
# id: "UUID", # required
|
774
|
+
# type: "text-input", # required, accepts text-input, q-query, file-upload, q-plugin
|
775
|
+
# filename: "Filename",
|
776
|
+
# file_id: "UUID",
|
777
|
+
# allow_override: false,
|
778
|
+
# },
|
779
|
+
# },
|
780
|
+
# ],
|
781
|
+
# initial_prompt: "InitialPrompt",
|
782
|
+
# },
|
783
|
+
# tags: {
|
784
|
+
# "String" => "String",
|
785
|
+
# },
|
786
|
+
# })
|
787
|
+
#
|
788
|
+
# @example Response structure
|
789
|
+
#
|
790
|
+
# resp.app_id #=> String
|
791
|
+
# resp.app_arn #=> String
|
792
|
+
# resp.title #=> String
|
793
|
+
# resp.description #=> String
|
794
|
+
# resp.initial_prompt #=> String
|
795
|
+
# resp.app_version #=> Integer
|
796
|
+
# resp.status #=> String, one of "PUBLISHED", "DRAFT", "DELETED"
|
797
|
+
# resp.created_at #=> Time
|
798
|
+
# resp.created_by #=> String
|
799
|
+
# resp.updated_at #=> Time
|
800
|
+
# resp.updated_by #=> String
|
801
|
+
# resp.required_capabilities #=> Array
|
802
|
+
# resp.required_capabilities[0] #=> String, one of "FileUpload", "CreatorMode", "RetrievalMode", "PluginMode"
|
803
|
+
#
|
804
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/CreateQApp AWS API Documentation
|
805
|
+
#
|
806
|
+
# @overload create_q_app(params = {})
|
807
|
+
# @param [Hash] params ({})
|
808
|
+
def create_q_app(params = {}, options = {})
|
809
|
+
req = build_request(:create_q_app, params)
|
810
|
+
req.send_request(options)
|
811
|
+
end
|
812
|
+
|
813
|
+
# Deletes a library item for an Amazon Q App, removing it from the
|
814
|
+
# library so it can no longer be discovered or used by other users.
|
815
|
+
#
|
816
|
+
# @option params [required, String] :instance_id
|
817
|
+
# The unique identifier of the Amazon Q Business application environment
|
818
|
+
# instance.
|
819
|
+
#
|
820
|
+
# @option params [required, String] :library_item_id
|
821
|
+
# The unique identifier of the library item to delete.
|
822
|
+
#
|
823
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
824
|
+
#
|
825
|
+
#
|
826
|
+
# @example Example: Delete a library item
|
827
|
+
#
|
828
|
+
# resp = client.delete_library_item({
|
829
|
+
# instance_id: "3642ba81-344c-42fd-a480-9119a5a5f26b",
|
830
|
+
# library_item_id: "72088fd4-78b6-43da-bfb8-8621323c3cfb",
|
831
|
+
# })
|
832
|
+
#
|
833
|
+
# @example Request syntax with placeholder values
|
834
|
+
#
|
835
|
+
# resp = client.delete_library_item({
|
836
|
+
# instance_id: "InstanceId", # required
|
837
|
+
# library_item_id: "UUID", # required
|
838
|
+
# })
|
839
|
+
#
|
840
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/DeleteLibraryItem AWS API Documentation
|
841
|
+
#
|
842
|
+
# @overload delete_library_item(params = {})
|
843
|
+
# @param [Hash] params ({})
|
844
|
+
def delete_library_item(params = {}, options = {})
|
845
|
+
req = build_request(:delete_library_item, params)
|
846
|
+
req.send_request(options)
|
847
|
+
end
|
848
|
+
|
849
|
+
# Deletes an Amazon Q App owned by the user. If the Q App was previously
|
850
|
+
# published to the library, it is also removed from the library.
|
851
|
+
#
|
852
|
+
# @option params [required, String] :instance_id
|
853
|
+
# The unique identifier of the Amazon Q Business application environment
|
854
|
+
# instance.
|
855
|
+
#
|
856
|
+
# @option params [required, String] :app_id
|
857
|
+
# The unique identifier of the Q App to delete.
|
858
|
+
#
|
859
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
860
|
+
#
|
861
|
+
#
|
862
|
+
# @example Example: Delete an Amazon Q App
|
863
|
+
#
|
864
|
+
# resp = client.delete_q_app({
|
865
|
+
# app_id: "393e77fb-0a30-4f47-ad30-75d71aeaed8a",
|
866
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
867
|
+
# })
|
868
|
+
#
|
869
|
+
# @example Request syntax with placeholder values
|
870
|
+
#
|
871
|
+
# resp = client.delete_q_app({
|
872
|
+
# instance_id: "InstanceId", # required
|
873
|
+
# app_id: "UUID", # required
|
874
|
+
# })
|
875
|
+
#
|
876
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/DeleteQApp AWS API Documentation
|
877
|
+
#
|
878
|
+
# @overload delete_q_app(params = {})
|
879
|
+
# @param [Hash] params ({})
|
880
|
+
def delete_q_app(params = {}, options = {})
|
881
|
+
req = build_request(:delete_q_app, params)
|
882
|
+
req.send_request(options)
|
883
|
+
end
|
884
|
+
|
885
|
+
# Removes a rating or review previously submitted by the user for a
|
886
|
+
# library item.
|
887
|
+
#
|
888
|
+
# @option params [required, String] :instance_id
|
889
|
+
# The unique identifier of the Amazon Q Business application environment
|
890
|
+
# instance.
|
891
|
+
#
|
892
|
+
# @option params [required, String] :library_item_id
|
893
|
+
# The unique identifier of the library item to remove the review from.
|
894
|
+
#
|
895
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
896
|
+
#
|
897
|
+
#
|
898
|
+
# @example Example: Decrease the rating counter by 1 for the related app for this user
|
899
|
+
#
|
900
|
+
# resp = client.disassociate_library_item_review({
|
901
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
902
|
+
# library_item_id: "cb9ecf72-8563-450d-9db9-994f98297316",
|
903
|
+
# })
|
904
|
+
#
|
905
|
+
# @example Request syntax with placeholder values
|
906
|
+
#
|
907
|
+
# resp = client.disassociate_library_item_review({
|
908
|
+
# instance_id: "InstanceId", # required
|
909
|
+
# library_item_id: "UUID", # required
|
910
|
+
# })
|
911
|
+
#
|
912
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/DisassociateLibraryItemReview AWS API Documentation
|
913
|
+
#
|
914
|
+
# @overload disassociate_library_item_review(params = {})
|
915
|
+
# @param [Hash] params ({})
|
916
|
+
def disassociate_library_item_review(params = {}, options = {})
|
917
|
+
req = build_request(:disassociate_library_item_review, params)
|
918
|
+
req.send_request(options)
|
919
|
+
end
|
920
|
+
|
921
|
+
# Disassociates a Q App from a user removing the user's access to run
|
922
|
+
# the Q App.
|
923
|
+
#
|
924
|
+
# @option params [required, String] :instance_id
|
925
|
+
# The unique identifier of the Amazon Q Business application environment
|
926
|
+
# instance.
|
927
|
+
#
|
928
|
+
# @option params [required, String] :app_id
|
929
|
+
# The unique identifier of the Q App to disassociate from the user.
|
930
|
+
#
|
931
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
932
|
+
#
|
933
|
+
#
|
934
|
+
# @example Example: Unlinks an Amazon Q App from the invoker's list of apps
|
935
|
+
#
|
936
|
+
# resp = client.disassociate_q_app_from_user({
|
937
|
+
# app_id: "393e77fb-0a30-4f47-ad30-75d71aeaed8a",
|
938
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
939
|
+
# })
|
940
|
+
#
|
941
|
+
# @example Request syntax with placeholder values
|
942
|
+
#
|
943
|
+
# resp = client.disassociate_q_app_from_user({
|
944
|
+
# instance_id: "InstanceId", # required
|
945
|
+
# app_id: "UUID", # required
|
946
|
+
# })
|
947
|
+
#
|
948
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/DisassociateQAppFromUser AWS API Documentation
|
949
|
+
#
|
950
|
+
# @overload disassociate_q_app_from_user(params = {})
|
951
|
+
# @param [Hash] params ({})
|
952
|
+
def disassociate_q_app_from_user(params = {}, options = {})
|
953
|
+
req = build_request(:disassociate_q_app_from_user, params)
|
954
|
+
req.send_request(options)
|
955
|
+
end
|
956
|
+
|
957
|
+
# Retrieves details about a library item for an Amazon Q App, including
|
958
|
+
# its metadata, categories, ratings, and usage statistics.
|
959
|
+
#
|
960
|
+
# @option params [required, String] :instance_id
|
961
|
+
# The unique identifier of the Amazon Q Business application environment
|
962
|
+
# instance.
|
963
|
+
#
|
964
|
+
# @option params [required, String] :library_item_id
|
965
|
+
# The unique identifier of the library item to retrieve.
|
966
|
+
#
|
967
|
+
# @option params [String] :app_id
|
968
|
+
# The unique identifier of the Amazon Q App associated with the library
|
969
|
+
# item.
|
970
|
+
#
|
971
|
+
# @return [Types::GetLibraryItemOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
972
|
+
#
|
973
|
+
# * {Types::GetLibraryItemOutput#library_item_id #library_item_id} => String
|
974
|
+
# * {Types::GetLibraryItemOutput#app_id #app_id} => String
|
975
|
+
# * {Types::GetLibraryItemOutput#app_version #app_version} => Integer
|
976
|
+
# * {Types::GetLibraryItemOutput#categories #categories} => Array<Types::Category>
|
977
|
+
# * {Types::GetLibraryItemOutput#status #status} => String
|
978
|
+
# * {Types::GetLibraryItemOutput#created_at #created_at} => Time
|
979
|
+
# * {Types::GetLibraryItemOutput#created_by #created_by} => String
|
980
|
+
# * {Types::GetLibraryItemOutput#updated_at #updated_at} => Time
|
981
|
+
# * {Types::GetLibraryItemOutput#updated_by #updated_by} => String
|
982
|
+
# * {Types::GetLibraryItemOutput#rating_count #rating_count} => Integer
|
983
|
+
# * {Types::GetLibraryItemOutput#is_rated_by_user #is_rated_by_user} => Boolean
|
984
|
+
# * {Types::GetLibraryItemOutput#user_count #user_count} => Integer
|
985
|
+
#
|
986
|
+
#
|
987
|
+
# @example Example: Retrieve a library item
|
988
|
+
#
|
989
|
+
# resp = client.get_library_item({
|
990
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
991
|
+
# library_item_id: "18cbebaa-196a-4aa5-a840-88d548e07f8f",
|
992
|
+
# })
|
993
|
+
#
|
994
|
+
# resp.to_h outputs the following:
|
995
|
+
# {
|
996
|
+
# app_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
997
|
+
# app_version: 1,
|
998
|
+
# categories: [
|
999
|
+
# {
|
1000
|
+
# id: "9c871ed4-1c41-4065-aefe-321cd4b61cf8",
|
1001
|
+
# title: "HR",
|
1002
|
+
# },
|
1003
|
+
# {
|
1004
|
+
# id: "fdc4b483-c4e2-44c9-b4b2-6c850bbdb579",
|
1005
|
+
# title: "General",
|
1006
|
+
# },
|
1007
|
+
# {
|
1008
|
+
# id: "c1c4e374-118c-446f-81fb-cba6225d88da",
|
1009
|
+
# title: "IT",
|
1010
|
+
# },
|
1011
|
+
# ],
|
1012
|
+
# created_at: Time.parse("2024-05-08T16:09:56.080Z"),
|
1013
|
+
# created_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
1014
|
+
# is_rated_by_user: false,
|
1015
|
+
# library_item_id: "18cbebaa-196a-4aa5-a840-88d548e07f8f",
|
1016
|
+
# rating_count: 0,
|
1017
|
+
# status: "PUBLISHED",
|
1018
|
+
# updated_at: Time.parse("2024-05-08T16:09:56.080Z"),
|
1019
|
+
# updated_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
1020
|
+
# user_count: 1,
|
1021
|
+
# }
|
1022
|
+
#
|
1023
|
+
# @example Request syntax with placeholder values
|
1024
|
+
#
|
1025
|
+
# resp = client.get_library_item({
|
1026
|
+
# instance_id: "InstanceId", # required
|
1027
|
+
# library_item_id: "UUID", # required
|
1028
|
+
# app_id: "UUID",
|
1029
|
+
# })
|
1030
|
+
#
|
1031
|
+
# @example Response structure
|
1032
|
+
#
|
1033
|
+
# resp.library_item_id #=> String
|
1034
|
+
# resp.app_id #=> String
|
1035
|
+
# resp.app_version #=> Integer
|
1036
|
+
# resp.categories #=> Array
|
1037
|
+
# resp.categories[0].id #=> String
|
1038
|
+
# resp.categories[0].title #=> String
|
1039
|
+
# resp.status #=> String
|
1040
|
+
# resp.created_at #=> Time
|
1041
|
+
# resp.created_by #=> String
|
1042
|
+
# resp.updated_at #=> Time
|
1043
|
+
# resp.updated_by #=> String
|
1044
|
+
# resp.rating_count #=> Integer
|
1045
|
+
# resp.is_rated_by_user #=> Boolean
|
1046
|
+
# resp.user_count #=> Integer
|
1047
|
+
#
|
1048
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/GetLibraryItem AWS API Documentation
|
1049
|
+
#
|
1050
|
+
# @overload get_library_item(params = {})
|
1051
|
+
# @param [Hash] params ({})
|
1052
|
+
def get_library_item(params = {}, options = {})
|
1053
|
+
req = build_request(:get_library_item, params)
|
1054
|
+
req.send_request(options)
|
1055
|
+
end
|
1056
|
+
|
1057
|
+
# Retrieves the full details of an Q App, including its definition
|
1058
|
+
# specifying the cards and flow.
|
1059
|
+
#
|
1060
|
+
# @option params [required, String] :instance_id
|
1061
|
+
# The unique identifier of the Amazon Q Business application environment
|
1062
|
+
# instance.
|
1063
|
+
#
|
1064
|
+
# @option params [required, String] :app_id
|
1065
|
+
# The unique identifier of the Q App to retrieve.
|
1066
|
+
#
|
1067
|
+
# @return [Types::GetQAppOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
1068
|
+
#
|
1069
|
+
# * {Types::GetQAppOutput#app_id #app_id} => String
|
1070
|
+
# * {Types::GetQAppOutput#app_arn #app_arn} => String
|
1071
|
+
# * {Types::GetQAppOutput#title #title} => String
|
1072
|
+
# * {Types::GetQAppOutput#description #description} => String
|
1073
|
+
# * {Types::GetQAppOutput#initial_prompt #initial_prompt} => String
|
1074
|
+
# * {Types::GetQAppOutput#app_version #app_version} => Integer
|
1075
|
+
# * {Types::GetQAppOutput#status #status} => String
|
1076
|
+
# * {Types::GetQAppOutput#created_at #created_at} => Time
|
1077
|
+
# * {Types::GetQAppOutput#created_by #created_by} => String
|
1078
|
+
# * {Types::GetQAppOutput#updated_at #updated_at} => Time
|
1079
|
+
# * {Types::GetQAppOutput#updated_by #updated_by} => String
|
1080
|
+
# * {Types::GetQAppOutput#required_capabilities #required_capabilities} => Array<String>
|
1081
|
+
# * {Types::GetQAppOutput#app_definition #app_definition} => Types::AppDefinition
|
1082
|
+
#
|
1083
|
+
#
|
1084
|
+
# @example Example: A basic application with 1 text input card and 1 output card
|
1085
|
+
#
|
1086
|
+
# resp = client.get_q_app({
|
1087
|
+
# app_id: "3d110749-efc3-427c-87e8-15e966e5c168",
|
1088
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
1089
|
+
# })
|
1090
|
+
#
|
1091
|
+
# resp.to_h outputs the following:
|
1092
|
+
# {
|
1093
|
+
# app_arn: "arn:aws:qapps:us-west-2:123456789012:app/7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
1094
|
+
# app_definition: {
|
1095
|
+
# app_definition_version: "1",
|
1096
|
+
# cards: [
|
1097
|
+
# {
|
1098
|
+
# text_input: {
|
1099
|
+
# type: "text-input",
|
1100
|
+
# dependencies: [
|
1101
|
+
# ],
|
1102
|
+
# id: "4cf94d96-8819-45c2-98cc-58c56b35c72f",
|
1103
|
+
# title: "Color Base",
|
1104
|
+
# },
|
1105
|
+
# },
|
1106
|
+
# {
|
1107
|
+
# q_query: {
|
1108
|
+
# type: "q-query",
|
1109
|
+
# dependencies: [
|
1110
|
+
# "91e4513d-6981-454a-9329-329c9302eef4",
|
1111
|
+
# ],
|
1112
|
+
# id: "18870b94-1e63-40e0-8c12-669c90ac5acc",
|
1113
|
+
# output_source: "llm",
|
1114
|
+
# prompt: "Recommend me a list of colors that go well with @91e4513d-6981-454a-9329-329c9302eef4 ",
|
1115
|
+
# title: "Recommended Palette",
|
1116
|
+
# },
|
1117
|
+
# },
|
1118
|
+
# ],
|
1119
|
+
# },
|
1120
|
+
# app_id: "7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
1121
|
+
# app_version: 1,
|
1122
|
+
# created_at: Time.parse("2024-05-14T00:11:54.232Z"),
|
1123
|
+
# created_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
1124
|
+
# status: "DRAFT",
|
1125
|
+
# title: "Color Palette Generator",
|
1126
|
+
# updated_at: Time.parse("2024-05-14T00:13:26.168Z"),
|
1127
|
+
# updated_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
1128
|
+
# }
|
1129
|
+
#
|
1130
|
+
# @example Request syntax with placeholder values
|
1131
|
+
#
|
1132
|
+
# resp = client.get_q_app({
|
1133
|
+
# instance_id: "InstanceId", # required
|
1134
|
+
# app_id: "UUID", # required
|
1135
|
+
# })
|
1136
|
+
#
|
1137
|
+
# @example Response structure
|
1138
|
+
#
|
1139
|
+
# resp.app_id #=> String
|
1140
|
+
# resp.app_arn #=> String
|
1141
|
+
# resp.title #=> String
|
1142
|
+
# resp.description #=> String
|
1143
|
+
# resp.initial_prompt #=> String
|
1144
|
+
# resp.app_version #=> Integer
|
1145
|
+
# resp.status #=> String, one of "PUBLISHED", "DRAFT", "DELETED"
|
1146
|
+
# resp.created_at #=> Time
|
1147
|
+
# resp.created_by #=> String
|
1148
|
+
# resp.updated_at #=> Time
|
1149
|
+
# resp.updated_by #=> String
|
1150
|
+
# resp.required_capabilities #=> Array
|
1151
|
+
# resp.required_capabilities[0] #=> String, one of "FileUpload", "CreatorMode", "RetrievalMode", "PluginMode"
|
1152
|
+
# resp.app_definition.app_definition_version #=> String
|
1153
|
+
# resp.app_definition.cards #=> Array
|
1154
|
+
# resp.app_definition.cards[0].text_input.id #=> String
|
1155
|
+
# resp.app_definition.cards[0].text_input.title #=> String
|
1156
|
+
# resp.app_definition.cards[0].text_input.dependencies #=> Array
|
1157
|
+
# resp.app_definition.cards[0].text_input.dependencies[0] #=> String
|
1158
|
+
# resp.app_definition.cards[0].text_input.type #=> String, one of "text-input", "q-query", "file-upload", "q-plugin"
|
1159
|
+
# resp.app_definition.cards[0].text_input.placeholder #=> String
|
1160
|
+
# resp.app_definition.cards[0].text_input.default_value #=> String
|
1161
|
+
# resp.app_definition.cards[0].q_query.id #=> String
|
1162
|
+
# resp.app_definition.cards[0].q_query.title #=> String
|
1163
|
+
# resp.app_definition.cards[0].q_query.dependencies #=> Array
|
1164
|
+
# resp.app_definition.cards[0].q_query.dependencies[0] #=> String
|
1165
|
+
# resp.app_definition.cards[0].q_query.type #=> String, one of "text-input", "q-query", "file-upload", "q-plugin"
|
1166
|
+
# resp.app_definition.cards[0].q_query.prompt #=> String
|
1167
|
+
# resp.app_definition.cards[0].q_query.output_source #=> String, one of "approved-sources", "llm"
|
1168
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.and_all_filters #=> Array
|
1169
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.and_all_filters[0] #=> Types::AttributeFilter
|
1170
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.or_all_filters #=> Array
|
1171
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.or_all_filters[0] #=> Types::AttributeFilter
|
1172
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.not_filter #=> Types::AttributeFilter
|
1173
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.equals_to.name #=> String
|
1174
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.equals_to.value.string_value #=> String
|
1175
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.equals_to.value.string_list_value #=> Array
|
1176
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.equals_to.value.string_list_value[0] #=> String
|
1177
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.equals_to.value.long_value #=> Integer
|
1178
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.equals_to.value.date_value #=> Time
|
1179
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.contains_all.name #=> String
|
1180
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.contains_all.value.string_value #=> String
|
1181
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.contains_all.value.string_list_value #=> Array
|
1182
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.contains_all.value.string_list_value[0] #=> String
|
1183
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.contains_all.value.long_value #=> Integer
|
1184
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.contains_all.value.date_value #=> Time
|
1185
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.contains_any.name #=> String
|
1186
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.contains_any.value.string_value #=> String
|
1187
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.contains_any.value.string_list_value #=> Array
|
1188
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.contains_any.value.string_list_value[0] #=> String
|
1189
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.contains_any.value.long_value #=> Integer
|
1190
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.contains_any.value.date_value #=> Time
|
1191
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.greater_than.name #=> String
|
1192
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.greater_than.value.string_value #=> String
|
1193
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.greater_than.value.string_list_value #=> Array
|
1194
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.greater_than.value.string_list_value[0] #=> String
|
1195
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.greater_than.value.long_value #=> Integer
|
1196
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.greater_than.value.date_value #=> Time
|
1197
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.greater_than_or_equals.name #=> String
|
1198
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.greater_than_or_equals.value.string_value #=> String
|
1199
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.greater_than_or_equals.value.string_list_value #=> Array
|
1200
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.greater_than_or_equals.value.string_list_value[0] #=> String
|
1201
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.greater_than_or_equals.value.long_value #=> Integer
|
1202
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.greater_than_or_equals.value.date_value #=> Time
|
1203
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.less_than.name #=> String
|
1204
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.less_than.value.string_value #=> String
|
1205
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.less_than.value.string_list_value #=> Array
|
1206
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.less_than.value.string_list_value[0] #=> String
|
1207
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.less_than.value.long_value #=> Integer
|
1208
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.less_than.value.date_value #=> Time
|
1209
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.less_than_or_equals.name #=> String
|
1210
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.less_than_or_equals.value.string_value #=> String
|
1211
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.less_than_or_equals.value.string_list_value #=> Array
|
1212
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.less_than_or_equals.value.string_list_value[0] #=> String
|
1213
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.less_than_or_equals.value.long_value #=> Integer
|
1214
|
+
# resp.app_definition.cards[0].q_query.attribute_filter.less_than_or_equals.value.date_value #=> Time
|
1215
|
+
# resp.app_definition.cards[0].q_plugin.id #=> String
|
1216
|
+
# resp.app_definition.cards[0].q_plugin.title #=> String
|
1217
|
+
# resp.app_definition.cards[0].q_plugin.dependencies #=> Array
|
1218
|
+
# resp.app_definition.cards[0].q_plugin.dependencies[0] #=> String
|
1219
|
+
# resp.app_definition.cards[0].q_plugin.type #=> String, one of "text-input", "q-query", "file-upload", "q-plugin"
|
1220
|
+
# resp.app_definition.cards[0].q_plugin.prompt #=> String
|
1221
|
+
# resp.app_definition.cards[0].q_plugin.plugin_type #=> String, one of "SERVICE_NOW", "SALESFORCE", "JIRA", "ZENDESK", "CUSTOM"
|
1222
|
+
# resp.app_definition.cards[0].q_plugin.plugin_id #=> String
|
1223
|
+
# resp.app_definition.cards[0].file_upload.id #=> String
|
1224
|
+
# resp.app_definition.cards[0].file_upload.title #=> String
|
1225
|
+
# resp.app_definition.cards[0].file_upload.dependencies #=> Array
|
1226
|
+
# resp.app_definition.cards[0].file_upload.dependencies[0] #=> String
|
1227
|
+
# resp.app_definition.cards[0].file_upload.type #=> String, one of "text-input", "q-query", "file-upload", "q-plugin"
|
1228
|
+
# resp.app_definition.cards[0].file_upload.filename #=> String
|
1229
|
+
# resp.app_definition.cards[0].file_upload.file_id #=> String
|
1230
|
+
# resp.app_definition.cards[0].file_upload.allow_override #=> Boolean
|
1231
|
+
# resp.app_definition.can_edit #=> Boolean
|
1232
|
+
#
|
1233
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/GetQApp AWS API Documentation
|
1234
|
+
#
|
1235
|
+
# @overload get_q_app(params = {})
|
1236
|
+
# @param [Hash] params ({})
|
1237
|
+
def get_q_app(params = {}, options = {})
|
1238
|
+
req = build_request(:get_q_app, params)
|
1239
|
+
req.send_request(options)
|
1240
|
+
end
|
1241
|
+
|
1242
|
+
# Retrieves the current state and results for an active session of an
|
1243
|
+
# Amazon Q App.
|
1244
|
+
#
|
1245
|
+
# @option params [required, String] :instance_id
|
1246
|
+
# The unique identifier of the Amazon Q Business application environment
|
1247
|
+
# instance.
|
1248
|
+
#
|
1249
|
+
# @option params [required, String] :session_id
|
1250
|
+
# The unique identifier of the Q App session to retrieve.
|
1251
|
+
#
|
1252
|
+
# @return [Types::GetQAppSessionOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
1253
|
+
#
|
1254
|
+
# * {Types::GetQAppSessionOutput#session_id #session_id} => String
|
1255
|
+
# * {Types::GetQAppSessionOutput#session_arn #session_arn} => String
|
1256
|
+
# * {Types::GetQAppSessionOutput#status #status} => String
|
1257
|
+
# * {Types::GetQAppSessionOutput#card_status #card_status} => Hash<String,Types::CardStatus>
|
1258
|
+
#
|
1259
|
+
#
|
1260
|
+
# @example Example: Retrieves an existing session for an Amazon Q App
|
1261
|
+
#
|
1262
|
+
# resp = client.get_q_app_session({
|
1263
|
+
# instance_id: "288ae830-1df2-4871-b6c0-4314d74dadef",
|
1264
|
+
# session_id: "1fca878e-64c5-4dc4-b1d9-c93effed4e82",
|
1265
|
+
# })
|
1266
|
+
#
|
1267
|
+
# resp.to_h outputs the following:
|
1268
|
+
# {
|
1269
|
+
# card_status: {
|
1270
|
+
# "1e6caeac-b481-45ff-a082-8b9a4a0b72e8" => {
|
1271
|
+
# current_state: "COMPLETED",
|
1272
|
+
# current_value: "Earth's circumference is 24,901 miles",
|
1273
|
+
# },
|
1274
|
+
# "6fb5b404-3b7b-48a4-8a8b-56406922a606" => {
|
1275
|
+
# current_state: "COMPLETED",
|
1276
|
+
# current_value: "What is the circumference of Earth?",
|
1277
|
+
# },
|
1278
|
+
# },
|
1279
|
+
# session_arn: "arn:aws:qapps:us-west-2:0123456789012:application/a929ecd6-5765-4ec7-bd3e-2ca90098b18e/qapp/65e7dce7-226a-47f9-b689-22850becef89/session/1fca878e-64c5-4dc4-b1d9-c93effed4e82",
|
1280
|
+
# session_id: "1fca878e-64c5-4dc4-b1d9-c93effed4e82",
|
1281
|
+
# status: "COMPLETED",
|
1282
|
+
# }
|
1283
|
+
#
|
1284
|
+
# @example Request syntax with placeholder values
|
1285
|
+
#
|
1286
|
+
# resp = client.get_q_app_session({
|
1287
|
+
# instance_id: "InstanceId", # required
|
1288
|
+
# session_id: "UUID", # required
|
1289
|
+
# })
|
1290
|
+
#
|
1291
|
+
# @example Response structure
|
1292
|
+
#
|
1293
|
+
# resp.session_id #=> String
|
1294
|
+
# resp.session_arn #=> String
|
1295
|
+
# resp.status #=> String, one of "IN_PROGRESS", "WAITING", "COMPLETED"
|
1296
|
+
# resp.card_status #=> Hash
|
1297
|
+
# resp.card_status["UUID"].current_state #=> String, one of "IN_PROGRESS", "WAITING", "COMPLETED"
|
1298
|
+
# resp.card_status["UUID"].current_value #=> String
|
1299
|
+
#
|
1300
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/GetQAppSession AWS API Documentation
|
1301
|
+
#
|
1302
|
+
# @overload get_q_app_session(params = {})
|
1303
|
+
# @param [Hash] params ({})
|
1304
|
+
def get_q_app_session(params = {}, options = {})
|
1305
|
+
req = build_request(:get_q_app_session, params)
|
1306
|
+
req.send_request(options)
|
1307
|
+
end
|
1308
|
+
|
1309
|
+
# Uploads a file that can then be used either as a default in a
|
1310
|
+
# `FileUploadCard` from Q App definition or as a file that is used
|
1311
|
+
# inside a single Q App run. The purpose of the document is determined
|
1312
|
+
# by a scope parameter that indicates whether it is at the app
|
1313
|
+
# definition level or at the app session level.
|
1314
|
+
#
|
1315
|
+
# @option params [required, String] :instance_id
|
1316
|
+
# The unique identifier of the Amazon Q Business application environment
|
1317
|
+
# instance.
|
1318
|
+
#
|
1319
|
+
# @option params [required, String] :card_id
|
1320
|
+
# The unique identifier of the card the file is associated with, if
|
1321
|
+
# applicable.
|
1322
|
+
#
|
1323
|
+
# @option params [required, String] :app_id
|
1324
|
+
# The unique identifier of the Q App the file is associated with.
|
1325
|
+
#
|
1326
|
+
# @option params [required, String] :file_contents_base_64
|
1327
|
+
# The base64-encoded contents of the file to upload.
|
1328
|
+
#
|
1329
|
+
# @option params [required, String] :file_name
|
1330
|
+
# The name of the file being uploaded.
|
1331
|
+
#
|
1332
|
+
# @option params [required, String] :scope
|
1333
|
+
# Whether the file is associated with an Q App definition or a specific
|
1334
|
+
# Q App session.
|
1335
|
+
#
|
1336
|
+
# @option params [String] :session_id
|
1337
|
+
# The unique identifier of the Q App session the file is associated
|
1338
|
+
# with, if applicable.
|
1339
|
+
#
|
1340
|
+
# @return [Types::ImportDocumentOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
1341
|
+
#
|
1342
|
+
# * {Types::ImportDocumentOutput#file_id #file_id} => String
|
1343
|
+
#
|
1344
|
+
#
|
1345
|
+
# @example Example: Upload a file to a specific session
|
1346
|
+
#
|
1347
|
+
# resp = client.import_document({
|
1348
|
+
# app_id: "4263767c-d889-4cb2-a8f6-8b649bc66af0",
|
1349
|
+
# card_id: "82f69028-22a9-4bea-8727-0eabf58e9fed",
|
1350
|
+
# file_contents_base_64: "data:text/plain;base64,SomeFileEncodedInBase64",
|
1351
|
+
# file_name: "myFile.txt",
|
1352
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
1353
|
+
# scope: "SESSION",
|
1354
|
+
# session_id: "4f0e5b87-9d38-41cd-9eb4-ebce2f2917cc",
|
1355
|
+
# })
|
1356
|
+
#
|
1357
|
+
# resp.to_h outputs the following:
|
1358
|
+
# {
|
1359
|
+
# file_id: "412aa1b4-341c-45af-936d-da52f8a1a3b4",
|
1360
|
+
# }
|
1361
|
+
#
|
1362
|
+
# @example Example: Upload a file into a application
|
1363
|
+
#
|
1364
|
+
# resp = client.import_document({
|
1365
|
+
# app_id: "4263767c-d889-4cb2-a8f6-8b649bc66af0",
|
1366
|
+
# card_id: "7a11f34b-42d4-4bc8-b668-ae4a788dae1e",
|
1367
|
+
# file_contents_base_64: "data:text/plain;base64,SomeFileEncodedInBase64",
|
1368
|
+
# file_name: "anApplicationFile.txt",
|
1369
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
1370
|
+
# scope: "APPLICATION",
|
1371
|
+
# })
|
1372
|
+
#
|
1373
|
+
# resp.to_h outputs the following:
|
1374
|
+
# {
|
1375
|
+
# file_id: "bc1a0cc9-076a-4e82-9a6c-f4d2d8a22489",
|
1376
|
+
# }
|
1377
|
+
#
|
1378
|
+
# @example Request syntax with placeholder values
|
1379
|
+
#
|
1380
|
+
# resp = client.import_document({
|
1381
|
+
# instance_id: "InstanceId", # required
|
1382
|
+
# card_id: "UUID", # required
|
1383
|
+
# app_id: "UUID", # required
|
1384
|
+
# file_contents_base_64: "String", # required
|
1385
|
+
# file_name: "Filename", # required
|
1386
|
+
# scope: "APPLICATION", # required, accepts APPLICATION, SESSION
|
1387
|
+
# session_id: "UUID",
|
1388
|
+
# })
|
1389
|
+
#
|
1390
|
+
# @example Response structure
|
1391
|
+
#
|
1392
|
+
# resp.file_id #=> String
|
1393
|
+
#
|
1394
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/ImportDocument AWS API Documentation
|
1395
|
+
#
|
1396
|
+
# @overload import_document(params = {})
|
1397
|
+
# @param [Hash] params ({})
|
1398
|
+
def import_document(params = {}, options = {})
|
1399
|
+
req = build_request(:import_document, params)
|
1400
|
+
req.send_request(options)
|
1401
|
+
end
|
1402
|
+
|
1403
|
+
# Lists the library items for Amazon Q Apps that are published and
|
1404
|
+
# available for users in your Amazon Web Services account.
|
1405
|
+
#
|
1406
|
+
# @option params [required, String] :instance_id
|
1407
|
+
# The unique identifier of the Amazon Q Business application environment
|
1408
|
+
# instance.
|
1409
|
+
#
|
1410
|
+
# @option params [Integer] :limit
|
1411
|
+
# The maximum number of library items to return in the response.
|
1412
|
+
#
|
1413
|
+
# @option params [String] :next_token
|
1414
|
+
# The token to request the next page of results.
|
1415
|
+
#
|
1416
|
+
# @option params [String] :category_id
|
1417
|
+
# Optional category to filter the library items by.
|
1418
|
+
#
|
1419
|
+
# @return [Types::ListLibraryItemsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
1420
|
+
#
|
1421
|
+
# * {Types::ListLibraryItemsOutput#library_items #library_items} => Array<Types::LibraryItemMember>
|
1422
|
+
# * {Types::ListLibraryItemsOutput#next_token #next_token} => String
|
1423
|
+
#
|
1424
|
+
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
1425
|
+
#
|
1426
|
+
#
|
1427
|
+
# @example Example: List at most 3 library items for this instance
|
1428
|
+
#
|
1429
|
+
# resp = client.list_library_items({
|
1430
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
1431
|
+
# limit: 3,
|
1432
|
+
# })
|
1433
|
+
#
|
1434
|
+
# resp.to_h outputs the following:
|
1435
|
+
# {
|
1436
|
+
# library_items: [
|
1437
|
+
# {
|
1438
|
+
# app_id: "7a11f34b-42d4-4bc8-b668-ae4a788dae1e",
|
1439
|
+
# app_version: 6,
|
1440
|
+
# categories: [
|
1441
|
+
# {
|
1442
|
+
# id: "9c871ed4-1c41-4065-aefe-321cd4b61cf8",
|
1443
|
+
# title: "HR",
|
1444
|
+
# },
|
1445
|
+
# {
|
1446
|
+
# id: "c1c4e374-118c-446f-81fb-cba6225d88da",
|
1447
|
+
# title: "IT",
|
1448
|
+
# },
|
1449
|
+
# ],
|
1450
|
+
# created_at: Time.parse("2024-05-21T23:17:27.350Z"),
|
1451
|
+
# created_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
1452
|
+
# is_rated_by_user: true,
|
1453
|
+
# library_item_id: "cb9ecf72-8563-450d-9db9-994f98297316",
|
1454
|
+
# rating_count: 3,
|
1455
|
+
# status: "PUBLISHED",
|
1456
|
+
# updated_at: Time.parse("2024-05-21T23:17:27.350Z"),
|
1457
|
+
# updated_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
1458
|
+
# user_count: 5,
|
1459
|
+
# },
|
1460
|
+
# {
|
1461
|
+
# app_id: "201272ac-d474-4a97-991c-5520dae04026",
|
1462
|
+
# app_version: 1,
|
1463
|
+
# categories: [
|
1464
|
+
# {
|
1465
|
+
# id: "fdc4b483-c4e2-44c9-b4b2-6c850bbdb579",
|
1466
|
+
# title: "General",
|
1467
|
+
# },
|
1468
|
+
# ],
|
1469
|
+
# created_at: Time.parse("2024-05-08T16:09:56.080Z"),
|
1470
|
+
# created_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
1471
|
+
# is_rated_by_user: false,
|
1472
|
+
# library_item_id: "18cbebaa-196a-4aa5-a840-88d548e07f8f",
|
1473
|
+
# rating_count: 5,
|
1474
|
+
# status: "PUBLISHED",
|
1475
|
+
# updated_at: Time.parse("2024-05-08T16:09:56.080Z"),
|
1476
|
+
# updated_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
1477
|
+
# user_count: 8,
|
1478
|
+
# },
|
1479
|
+
# {
|
1480
|
+
# app_id: "1802f57f-079a-4b5b-839a-79bbe2e21b3c",
|
1481
|
+
# app_version: 1,
|
1482
|
+
# categories: [
|
1483
|
+
# {
|
1484
|
+
# id: "fdc4b483-c4e2-44c9-b4b2-6c850bbdb579",
|
1485
|
+
# title: "General",
|
1486
|
+
# },
|
1487
|
+
# ],
|
1488
|
+
# created_at: Time.parse("2024-05-07T22:57:59.327Z"),
|
1489
|
+
# created_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
1490
|
+
# is_rated_by_user: false,
|
1491
|
+
# library_item_id: "549abfe0-f5c4-45a2-bb9b-c05987a49c6d",
|
1492
|
+
# rating_count: 8,
|
1493
|
+
# status: "PUBLISHED",
|
1494
|
+
# updated_at: Time.parse("2024-05-07T22:57:59.327Z"),
|
1495
|
+
# updated_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
1496
|
+
# user_count: 12,
|
1497
|
+
# },
|
1498
|
+
# ],
|
1499
|
+
# next_token: "YW5vdGhlclRva2VuIQ==",
|
1500
|
+
# }
|
1501
|
+
#
|
1502
|
+
# @example Request syntax with placeholder values
|
1503
|
+
#
|
1504
|
+
# resp = client.list_library_items({
|
1505
|
+
# instance_id: "InstanceId", # required
|
1506
|
+
# limit: 1,
|
1507
|
+
# next_token: "PaginationToken",
|
1508
|
+
# category_id: "UUID",
|
1509
|
+
# })
|
1510
|
+
#
|
1511
|
+
# @example Response structure
|
1512
|
+
#
|
1513
|
+
# resp.library_items #=> Array
|
1514
|
+
# resp.library_items[0].library_item_id #=> String
|
1515
|
+
# resp.library_items[0].app_id #=> String
|
1516
|
+
# resp.library_items[0].app_version #=> Integer
|
1517
|
+
# resp.library_items[0].categories #=> Array
|
1518
|
+
# resp.library_items[0].categories[0].id #=> String
|
1519
|
+
# resp.library_items[0].categories[0].title #=> String
|
1520
|
+
# resp.library_items[0].status #=> String
|
1521
|
+
# resp.library_items[0].created_at #=> Time
|
1522
|
+
# resp.library_items[0].created_by #=> String
|
1523
|
+
# resp.library_items[0].updated_at #=> Time
|
1524
|
+
# resp.library_items[0].updated_by #=> String
|
1525
|
+
# resp.library_items[0].rating_count #=> Integer
|
1526
|
+
# resp.library_items[0].is_rated_by_user #=> Boolean
|
1527
|
+
# resp.library_items[0].user_count #=> Integer
|
1528
|
+
# resp.next_token #=> String
|
1529
|
+
#
|
1530
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/ListLibraryItems AWS API Documentation
|
1531
|
+
#
|
1532
|
+
# @overload list_library_items(params = {})
|
1533
|
+
# @param [Hash] params ({})
|
1534
|
+
def list_library_items(params = {}, options = {})
|
1535
|
+
req = build_request(:list_library_items, params)
|
1536
|
+
req.send_request(options)
|
1537
|
+
end
|
1538
|
+
|
1539
|
+
# Lists the Amazon Q Apps owned by or associated with the user either
|
1540
|
+
# because they created it or because they used it from the library in
|
1541
|
+
# the past. The user identity is extracted from the credentials used to
|
1542
|
+
# invoke this operation..
|
1543
|
+
#
|
1544
|
+
# @option params [required, String] :instance_id
|
1545
|
+
# The unique identifier of the Amazon Q Business application environment
|
1546
|
+
# instance.
|
1547
|
+
#
|
1548
|
+
# @option params [Integer] :limit
|
1549
|
+
# The maximum number of Q Apps to return in the response.
|
1550
|
+
#
|
1551
|
+
# @option params [String] :next_token
|
1552
|
+
# The token to request the next page of results.
|
1553
|
+
#
|
1554
|
+
# @return [Types::ListQAppsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
1555
|
+
#
|
1556
|
+
# * {Types::ListQAppsOutput#apps #apps} => Array<Types::UserAppItem>
|
1557
|
+
# * {Types::ListQAppsOutput#next_token #next_token} => String
|
1558
|
+
#
|
1559
|
+
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
1560
|
+
#
|
1561
|
+
#
|
1562
|
+
# @example Example: List at most 3 Amazon Q Apps in an Q Business application
|
1563
|
+
#
|
1564
|
+
# resp = client.list_q_apps({
|
1565
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
1566
|
+
# limit: 3,
|
1567
|
+
# })
|
1568
|
+
#
|
1569
|
+
# resp.to_h outputs the following:
|
1570
|
+
# {
|
1571
|
+
# apps: [
|
1572
|
+
# {
|
1573
|
+
# app_arn: "arn:aws:qapps:us-west-2:..../7b9fe303-18bb-4643-952c-bfcf9f4c427f",
|
1574
|
+
# app_id: "7b9fe303-18bb-4643-952c-bfcf9f4c427f",
|
1575
|
+
# created_at: Time.parse("2024-05-21T04:09:10.401Z"),
|
1576
|
+
# description: "Description 1",
|
1577
|
+
# status: "DRAFT",
|
1578
|
+
# title: "App 1",
|
1579
|
+
# },
|
1580
|
+
# {
|
1581
|
+
# app_arn: "arn:aws:qapps:us-west-2:..../dd178fd6-ad3d-49b3-a32d-e915cf423e37",
|
1582
|
+
# app_id: "dd178fd6-ad3d-49b3-a32d-e915cf423e37",
|
1583
|
+
# created_at: Time.parse("2024-05-21T04:09:10.401Z"),
|
1584
|
+
# description: "Description 2",
|
1585
|
+
# status: "PUBLISHED",
|
1586
|
+
# title: "App 2",
|
1587
|
+
# },
|
1588
|
+
# {
|
1589
|
+
# app_arn: "arn:aws:qapps:us-west-2:..../3274b744-1a13-4aad-953f-eda2e4149e6e",
|
1590
|
+
# app_id: "3274b744-1a13-4aad-953f-eda2e4149e6e",
|
1591
|
+
# created_at: Time.parse("2024-05-21T04:09:10.401Z"),
|
1592
|
+
# description: "Description 3",
|
1593
|
+
# status: "DRAFT",
|
1594
|
+
# title: "App 3",
|
1595
|
+
# },
|
1596
|
+
# ],
|
1597
|
+
# next_token: "bXlzdGVyaW91c1BhZ2luYXRpb25Ub2tlbg==",
|
1598
|
+
# }
|
1599
|
+
#
|
1600
|
+
# @example Example: Retrieve the next page of Amazon Q Apps
|
1601
|
+
#
|
1602
|
+
# resp = client.list_q_apps({
|
1603
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
1604
|
+
# limit: 3,
|
1605
|
+
# next_token: "bXlzdGVyaW91c1BhZ2luYXRpb25Ub2tlbg==",
|
1606
|
+
# })
|
1607
|
+
#
|
1608
|
+
# resp.to_h outputs the following:
|
1609
|
+
# {
|
1610
|
+
# apps: [
|
1611
|
+
# {
|
1612
|
+
# app_arn: "arn:aws:qapps:us-west-2:..../bec8ee64-2635-41e8-aace-e1e418f4f295",
|
1613
|
+
# app_id: "bec8ee64-2635-41e8-aace-e1e418f4f295",
|
1614
|
+
# created_at: Time.parse("2024-05-21T04:09:10.401Z"),
|
1615
|
+
# description: "Description 4",
|
1616
|
+
# status: "PUBLISHED",
|
1617
|
+
# title: "App 4",
|
1618
|
+
# },
|
1619
|
+
# {
|
1620
|
+
# app_arn: "arn:aws:qapps:us-west-2:..../c380a45d-bd77-45b0-a0e5-8a266c1d8bc4",
|
1621
|
+
# app_id: "c380a45d-bd77-45b0-a0e5-8a266c1d8bc4",
|
1622
|
+
# created_at: Time.parse("2024-05-21T04:09:10.401Z"),
|
1623
|
+
# description: "Description 5",
|
1624
|
+
# status: "PUBLISHED",
|
1625
|
+
# title: "App 5",
|
1626
|
+
# },
|
1627
|
+
# {
|
1628
|
+
# app_arn: "arn:aws:qapps:us-west-2:..../afc4ee80-9722-4396-85a6-7aeaff52c177",
|
1629
|
+
# app_id: "afc4ee80-9722-4396-85a6-7aeaff52c177",
|
1630
|
+
# created_at: Time.parse("2024-05-21T04:09:10.401Z"),
|
1631
|
+
# description: "Description 6",
|
1632
|
+
# status: "PUBLISHED",
|
1633
|
+
# title: "App 6",
|
1634
|
+
# },
|
1635
|
+
# ],
|
1636
|
+
# next_token: "YW5vdGhlclRva2VuIQ==",
|
1637
|
+
# }
|
1638
|
+
#
|
1639
|
+
# @example Request syntax with placeholder values
|
1640
|
+
#
|
1641
|
+
# resp = client.list_q_apps({
|
1642
|
+
# instance_id: "InstanceId", # required
|
1643
|
+
# limit: 1,
|
1644
|
+
# next_token: "PaginationToken",
|
1645
|
+
# })
|
1646
|
+
#
|
1647
|
+
# @example Response structure
|
1648
|
+
#
|
1649
|
+
# resp.apps #=> Array
|
1650
|
+
# resp.apps[0].app_id #=> String
|
1651
|
+
# resp.apps[0].app_arn #=> String
|
1652
|
+
# resp.apps[0].title #=> String
|
1653
|
+
# resp.apps[0].description #=> String
|
1654
|
+
# resp.apps[0].created_at #=> Time
|
1655
|
+
# resp.apps[0].can_edit #=> Boolean
|
1656
|
+
# resp.apps[0].status #=> String
|
1657
|
+
# resp.next_token #=> String
|
1658
|
+
#
|
1659
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/ListQApps AWS API Documentation
|
1660
|
+
#
|
1661
|
+
# @overload list_q_apps(params = {})
|
1662
|
+
# @param [Hash] params ({})
|
1663
|
+
def list_q_apps(params = {}, options = {})
|
1664
|
+
req = build_request(:list_q_apps, params)
|
1665
|
+
req.send_request(options)
|
1666
|
+
end
|
1667
|
+
|
1668
|
+
# Lists the tags associated with an Amazon Q Apps resource.
|
1669
|
+
#
|
1670
|
+
# @option params [required, String] :resource_arn
|
1671
|
+
# The Amazon Resource Name (ARN) of the resource whose tags should be
|
1672
|
+
# listed.
|
1673
|
+
#
|
1674
|
+
# @return [Types::ListTagsForResourceResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
1675
|
+
#
|
1676
|
+
# * {Types::ListTagsForResourceResponse#tags #tags} => Hash<String,String>
|
1677
|
+
#
|
1678
|
+
#
|
1679
|
+
# @example Example: A call to list tags for a resource
|
1680
|
+
#
|
1681
|
+
# resp = client.list_tags_for_resource({
|
1682
|
+
# resource_arn: "arn:aws:qapps:us-west-2:123456789012:application/3642ba81-344c-42fd-a480-9119a5a5f26b/qapp/7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
1683
|
+
# })
|
1684
|
+
#
|
1685
|
+
# resp.to_h outputs the following:
|
1686
|
+
# {
|
1687
|
+
# tags: {
|
1688
|
+
# "department" => "HR",
|
1689
|
+
# },
|
1690
|
+
# }
|
1691
|
+
#
|
1692
|
+
# @example Request syntax with placeholder values
|
1693
|
+
#
|
1694
|
+
# resp = client.list_tags_for_resource({
|
1695
|
+
# resource_arn: "AmazonResourceName", # required
|
1696
|
+
# })
|
1697
|
+
#
|
1698
|
+
# @example Response structure
|
1699
|
+
#
|
1700
|
+
# resp.tags #=> Hash
|
1701
|
+
# resp.tags["TagKey"] #=> String
|
1702
|
+
#
|
1703
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/ListTagsForResource AWS API Documentation
|
1704
|
+
#
|
1705
|
+
# @overload list_tags_for_resource(params = {})
|
1706
|
+
# @param [Hash] params ({})
|
1707
|
+
def list_tags_for_resource(params = {}, options = {})
|
1708
|
+
req = build_request(:list_tags_for_resource, params)
|
1709
|
+
req.send_request(options)
|
1710
|
+
end
|
1711
|
+
|
1712
|
+
# Generates an Amazon Q App definition based on either a conversation or
|
1713
|
+
# a problem statement provided as input.The resulting app definition can
|
1714
|
+
# be used to call `CreateQApp`. This API doesn't create Amazon Q Apps
|
1715
|
+
# directly.
|
1716
|
+
#
|
1717
|
+
# @option params [required, String] :instance_id
|
1718
|
+
# The unique identifier of the Amazon Q Business application environment
|
1719
|
+
# instance.
|
1720
|
+
#
|
1721
|
+
# @option params [Types::PredictQAppInputOptions] :options
|
1722
|
+
# The input to generate the Q App definition from, either a conversation
|
1723
|
+
# or problem statement.
|
1724
|
+
#
|
1725
|
+
# @return [Types::PredictQAppOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
1726
|
+
#
|
1727
|
+
# * {Types::PredictQAppOutput#app #app} => Types::PredictAppDefinition
|
1728
|
+
# * {Types::PredictQAppOutput#problem_statement #problem_statement} => String
|
1729
|
+
#
|
1730
|
+
# @example Request syntax with placeholder values
|
1731
|
+
#
|
1732
|
+
# resp = client.predict_q_app({
|
1733
|
+
# instance_id: "InstanceId", # required
|
1734
|
+
# options: {
|
1735
|
+
# conversation: [
|
1736
|
+
# {
|
1737
|
+
# body: "ConversationMessageBodyString", # required
|
1738
|
+
# type: "USER", # required, accepts USER, SYSTEM
|
1739
|
+
# },
|
1740
|
+
# ],
|
1741
|
+
# problem_statement: "PredictQAppInputOptionsProblemStatementString",
|
1742
|
+
# },
|
1743
|
+
# })
|
1744
|
+
#
|
1745
|
+
# @example Response structure
|
1746
|
+
#
|
1747
|
+
# resp.app.title #=> String
|
1748
|
+
# resp.app.description #=> String
|
1749
|
+
# resp.app.app_definition.cards #=> Array
|
1750
|
+
# resp.app.app_definition.cards[0].text_input.title #=> String
|
1751
|
+
# resp.app.app_definition.cards[0].text_input.id #=> String
|
1752
|
+
# resp.app.app_definition.cards[0].text_input.type #=> String, one of "text-input", "q-query", "file-upload", "q-plugin"
|
1753
|
+
# resp.app.app_definition.cards[0].text_input.placeholder #=> String
|
1754
|
+
# resp.app.app_definition.cards[0].text_input.default_value #=> String
|
1755
|
+
# resp.app.app_definition.cards[0].q_query.title #=> String
|
1756
|
+
# resp.app.app_definition.cards[0].q_query.id #=> String
|
1757
|
+
# resp.app.app_definition.cards[0].q_query.type #=> String, one of "text-input", "q-query", "file-upload", "q-plugin"
|
1758
|
+
# resp.app.app_definition.cards[0].q_query.prompt #=> String
|
1759
|
+
# resp.app.app_definition.cards[0].q_query.output_source #=> String, one of "approved-sources", "llm"
|
1760
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.and_all_filters #=> Array
|
1761
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.and_all_filters[0] #=> Types::AttributeFilter
|
1762
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.or_all_filters #=> Array
|
1763
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.or_all_filters[0] #=> Types::AttributeFilter
|
1764
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.not_filter #=> Types::AttributeFilter
|
1765
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.equals_to.name #=> String
|
1766
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.equals_to.value.string_value #=> String
|
1767
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.equals_to.value.string_list_value #=> Array
|
1768
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.equals_to.value.string_list_value[0] #=> String
|
1769
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.equals_to.value.long_value #=> Integer
|
1770
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.equals_to.value.date_value #=> Time
|
1771
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.contains_all.name #=> String
|
1772
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.contains_all.value.string_value #=> String
|
1773
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.contains_all.value.string_list_value #=> Array
|
1774
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.contains_all.value.string_list_value[0] #=> String
|
1775
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.contains_all.value.long_value #=> Integer
|
1776
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.contains_all.value.date_value #=> Time
|
1777
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.contains_any.name #=> String
|
1778
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.contains_any.value.string_value #=> String
|
1779
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.contains_any.value.string_list_value #=> Array
|
1780
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.contains_any.value.string_list_value[0] #=> String
|
1781
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.contains_any.value.long_value #=> Integer
|
1782
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.contains_any.value.date_value #=> Time
|
1783
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.greater_than.name #=> String
|
1784
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.greater_than.value.string_value #=> String
|
1785
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.greater_than.value.string_list_value #=> Array
|
1786
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.greater_than.value.string_list_value[0] #=> String
|
1787
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.greater_than.value.long_value #=> Integer
|
1788
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.greater_than.value.date_value #=> Time
|
1789
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.greater_than_or_equals.name #=> String
|
1790
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.greater_than_or_equals.value.string_value #=> String
|
1791
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.greater_than_or_equals.value.string_list_value #=> Array
|
1792
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.greater_than_or_equals.value.string_list_value[0] #=> String
|
1793
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.greater_than_or_equals.value.long_value #=> Integer
|
1794
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.greater_than_or_equals.value.date_value #=> Time
|
1795
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.less_than.name #=> String
|
1796
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.less_than.value.string_value #=> String
|
1797
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.less_than.value.string_list_value #=> Array
|
1798
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.less_than.value.string_list_value[0] #=> String
|
1799
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.less_than.value.long_value #=> Integer
|
1800
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.less_than.value.date_value #=> Time
|
1801
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.less_than_or_equals.name #=> String
|
1802
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.less_than_or_equals.value.string_value #=> String
|
1803
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.less_than_or_equals.value.string_list_value #=> Array
|
1804
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.less_than_or_equals.value.string_list_value[0] #=> String
|
1805
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.less_than_or_equals.value.long_value #=> Integer
|
1806
|
+
# resp.app.app_definition.cards[0].q_query.attribute_filter.less_than_or_equals.value.date_value #=> Time
|
1807
|
+
# resp.app.app_definition.cards[0].q_plugin.title #=> String
|
1808
|
+
# resp.app.app_definition.cards[0].q_plugin.id #=> String
|
1809
|
+
# resp.app.app_definition.cards[0].q_plugin.type #=> String, one of "text-input", "q-query", "file-upload", "q-plugin"
|
1810
|
+
# resp.app.app_definition.cards[0].q_plugin.prompt #=> String
|
1811
|
+
# resp.app.app_definition.cards[0].q_plugin.plugin_id #=> String
|
1812
|
+
# resp.app.app_definition.cards[0].file_upload.title #=> String
|
1813
|
+
# resp.app.app_definition.cards[0].file_upload.id #=> String
|
1814
|
+
# resp.app.app_definition.cards[0].file_upload.type #=> String, one of "text-input", "q-query", "file-upload", "q-plugin"
|
1815
|
+
# resp.app.app_definition.cards[0].file_upload.filename #=> String
|
1816
|
+
# resp.app.app_definition.cards[0].file_upload.file_id #=> String
|
1817
|
+
# resp.app.app_definition.cards[0].file_upload.allow_override #=> Boolean
|
1818
|
+
# resp.app.app_definition.initial_prompt #=> String
|
1819
|
+
# resp.problem_statement #=> String
|
1820
|
+
#
|
1821
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/PredictQApp AWS API Documentation
|
1822
|
+
#
|
1823
|
+
# @overload predict_q_app(params = {})
|
1824
|
+
# @param [Hash] params ({})
|
1825
|
+
def predict_q_app(params = {}, options = {})
|
1826
|
+
req = build_request(:predict_q_app, params)
|
1827
|
+
req.send_request(options)
|
1828
|
+
end
|
1829
|
+
|
1830
|
+
# Starts a new session for an Amazon Q App, allowing inputs to be
|
1831
|
+
# provided and the app to be run.
|
1832
|
+
#
|
1833
|
+
# <note markdown="1"> Each Q App session will be condensed into a single conversation in the
|
1834
|
+
# web experience.
|
1835
|
+
#
|
1836
|
+
# </note>
|
1837
|
+
#
|
1838
|
+
# @option params [required, String] :instance_id
|
1839
|
+
# The unique identifier of the Amazon Q Business application environment
|
1840
|
+
# instance.
|
1841
|
+
#
|
1842
|
+
# @option params [required, String] :app_id
|
1843
|
+
# The unique identifier of the Q App to start a session for.
|
1844
|
+
#
|
1845
|
+
# @option params [required, Integer] :app_version
|
1846
|
+
# The version of the Q App to use for the session.
|
1847
|
+
#
|
1848
|
+
# @option params [Array<Types::CardValue>] :initial_values
|
1849
|
+
# Optional initial input values to provide for the Q App session.
|
1850
|
+
#
|
1851
|
+
# @option params [Hash<String,String>] :tags
|
1852
|
+
# Optional tags to associate with the new Q App session.
|
1853
|
+
#
|
1854
|
+
# @return [Types::StartQAppSessionOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
1855
|
+
#
|
1856
|
+
# * {Types::StartQAppSessionOutput#session_id #session_id} => String
|
1857
|
+
# * {Types::StartQAppSessionOutput#session_arn #session_arn} => String
|
1858
|
+
#
|
1859
|
+
#
|
1860
|
+
# @example Example: Start a session for an Amazon Q App using version 1, passing in initial values for one card
|
1861
|
+
#
|
1862
|
+
# resp = client.start_q_app_session({
|
1863
|
+
# app_id: "65e7dce7-226a-47f9-b689-22850becef89",
|
1864
|
+
# app_version: 1,
|
1865
|
+
# initial_values: [
|
1866
|
+
# {
|
1867
|
+
# value: "What is the circumference of Earth?",
|
1868
|
+
# card_id: "6fb5b404-3b7b-48a4-8a8b-56406922a606",
|
1869
|
+
# },
|
1870
|
+
# ],
|
1871
|
+
# instance_id: "4cc5e4c2-d2a2-4188-a114-9ca125b4aedc",
|
1872
|
+
# })
|
1873
|
+
#
|
1874
|
+
# resp.to_h outputs the following:
|
1875
|
+
# {
|
1876
|
+
# session_arn: "arn:aws:qapps:us-west-2:0123456789012:application/a929ecd6-5765-4ec7-bd3e-2ca90098b18e/qapp/65e7dce7-226a-47f9-b689-22850becef89/session/1fca878e-64c5-4dc4-b1d9-c93effed4e82",
|
1877
|
+
# session_id: "1fca878e-64c5-4dc4-b1d9-c93effed4e82",
|
1878
|
+
# }
|
1879
|
+
#
|
1880
|
+
# @example Request syntax with placeholder values
|
1881
|
+
#
|
1882
|
+
# resp = client.start_q_app_session({
|
1883
|
+
# instance_id: "InstanceId", # required
|
1884
|
+
# app_id: "UUID", # required
|
1885
|
+
# app_version: 1, # required
|
1886
|
+
# initial_values: [
|
1887
|
+
# {
|
1888
|
+
# card_id: "UUID", # required
|
1889
|
+
# value: "CardValueValueString", # required
|
1890
|
+
# },
|
1891
|
+
# ],
|
1892
|
+
# tags: {
|
1893
|
+
# "String" => "String",
|
1894
|
+
# },
|
1895
|
+
# })
|
1896
|
+
#
|
1897
|
+
# @example Response structure
|
1898
|
+
#
|
1899
|
+
# resp.session_id #=> String
|
1900
|
+
# resp.session_arn #=> String
|
1901
|
+
#
|
1902
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/StartQAppSession AWS API Documentation
|
1903
|
+
#
|
1904
|
+
# @overload start_q_app_session(params = {})
|
1905
|
+
# @param [Hash] params ({})
|
1906
|
+
def start_q_app_session(params = {}, options = {})
|
1907
|
+
req = build_request(:start_q_app_session, params)
|
1908
|
+
req.send_request(options)
|
1909
|
+
end
|
1910
|
+
|
1911
|
+
# Stops an active session for an Amazon Q App.This deletes all data
|
1912
|
+
# related to the session and makes it invalid for future uses. The
|
1913
|
+
# results of the session will be persisted as part of the conversation.
|
1914
|
+
#
|
1915
|
+
# @option params [required, String] :instance_id
|
1916
|
+
# The unique identifier of the Amazon Q Business application environment
|
1917
|
+
# instance.
|
1918
|
+
#
|
1919
|
+
# @option params [required, String] :session_id
|
1920
|
+
# The unique identifier of the Q App session to stop.
|
1921
|
+
#
|
1922
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
1923
|
+
#
|
1924
|
+
# @example Request syntax with placeholder values
|
1925
|
+
#
|
1926
|
+
# resp = client.stop_q_app_session({
|
1927
|
+
# instance_id: "InstanceId", # required
|
1928
|
+
# session_id: "UUID", # required
|
1929
|
+
# })
|
1930
|
+
#
|
1931
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/StopQAppSession AWS API Documentation
|
1932
|
+
#
|
1933
|
+
# @overload stop_q_app_session(params = {})
|
1934
|
+
# @param [Hash] params ({})
|
1935
|
+
def stop_q_app_session(params = {}, options = {})
|
1936
|
+
req = build_request(:stop_q_app_session, params)
|
1937
|
+
req.send_request(options)
|
1938
|
+
end
|
1939
|
+
|
1940
|
+
# Associates tags with an Amazon Q Apps resource.
|
1941
|
+
#
|
1942
|
+
# @option params [required, String] :resource_arn
|
1943
|
+
# The Amazon Resource Name (ARN) of the resource to tag.
|
1944
|
+
#
|
1945
|
+
# @option params [required, Hash<String,String>] :tags
|
1946
|
+
# The tags to associate with the resource.
|
1947
|
+
#
|
1948
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
1949
|
+
#
|
1950
|
+
#
|
1951
|
+
# @example Example: A call to tag a resource
|
1952
|
+
#
|
1953
|
+
# resp = client.tag_resource({
|
1954
|
+
# resource_arn: "arn:aws:qapps:us-west-2:123456789012:application/3642ba81-344c-42fd-a480-9119a5a5f26b/qapp/7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
1955
|
+
# tags: {
|
1956
|
+
# "department" => "HR",
|
1957
|
+
# },
|
1958
|
+
# })
|
1959
|
+
#
|
1960
|
+
# @example Request syntax with placeholder values
|
1961
|
+
#
|
1962
|
+
# resp = client.tag_resource({
|
1963
|
+
# resource_arn: "AmazonResourceName", # required
|
1964
|
+
# tags: { # required
|
1965
|
+
# "TagKey" => "TagValue",
|
1966
|
+
# },
|
1967
|
+
# })
|
1968
|
+
#
|
1969
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/TagResource AWS API Documentation
|
1970
|
+
#
|
1971
|
+
# @overload tag_resource(params = {})
|
1972
|
+
# @param [Hash] params ({})
|
1973
|
+
def tag_resource(params = {}, options = {})
|
1974
|
+
req = build_request(:tag_resource, params)
|
1975
|
+
req.send_request(options)
|
1976
|
+
end
|
1977
|
+
|
1978
|
+
# Disassociates tags from an Amazon Q Apps resource.
|
1979
|
+
#
|
1980
|
+
# @option params [required, String] :resource_arn
|
1981
|
+
# The Amazon Resource Name (ARN) of the resource to disassociate the tag
|
1982
|
+
# from.
|
1983
|
+
#
|
1984
|
+
# @option params [required, Array<String>] :tag_keys
|
1985
|
+
# The keys of the tags to disassociate from the resource.
|
1986
|
+
#
|
1987
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
1988
|
+
#
|
1989
|
+
#
|
1990
|
+
# @example Example: A call to untag a resource
|
1991
|
+
#
|
1992
|
+
# resp = client.untag_resource({
|
1993
|
+
# resource_arn: "arn:aws:qapps:us-west-2:123456789012:application/3642ba81-344c-42fd-a480-9119a5a5f26b/qapp/7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
1994
|
+
# tag_keys: [
|
1995
|
+
# "department",
|
1996
|
+
# ],
|
1997
|
+
# })
|
1998
|
+
#
|
1999
|
+
# @example Request syntax with placeholder values
|
2000
|
+
#
|
2001
|
+
# resp = client.untag_resource({
|
2002
|
+
# resource_arn: "AmazonResourceName", # required
|
2003
|
+
# tag_keys: ["TagKey"], # required
|
2004
|
+
# })
|
2005
|
+
#
|
2006
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/UntagResource AWS API Documentation
|
2007
|
+
#
|
2008
|
+
# @overload untag_resource(params = {})
|
2009
|
+
# @param [Hash] params ({})
|
2010
|
+
def untag_resource(params = {}, options = {})
|
2011
|
+
req = build_request(:untag_resource, params)
|
2012
|
+
req.send_request(options)
|
2013
|
+
end
|
2014
|
+
|
2015
|
+
# Updates the metadata and status of a library item for an Amazon Q App.
|
2016
|
+
#
|
2017
|
+
# @option params [required, String] :instance_id
|
2018
|
+
# The unique identifier of the Amazon Q Business application environment
|
2019
|
+
# instance.
|
2020
|
+
#
|
2021
|
+
# @option params [required, String] :library_item_id
|
2022
|
+
# The unique identifier of the library item to update.
|
2023
|
+
#
|
2024
|
+
# @option params [String] :status
|
2025
|
+
# The new status to set for the library item, such as "Published" or
|
2026
|
+
# "Hidden".
|
2027
|
+
#
|
2028
|
+
# @option params [Array<String>] :categories
|
2029
|
+
# The new categories to associate with the library item.
|
2030
|
+
#
|
2031
|
+
# @return [Types::UpdateLibraryItemOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
2032
|
+
#
|
2033
|
+
# * {Types::UpdateLibraryItemOutput#library_item_id #library_item_id} => String
|
2034
|
+
# * {Types::UpdateLibraryItemOutput#app_id #app_id} => String
|
2035
|
+
# * {Types::UpdateLibraryItemOutput#app_version #app_version} => Integer
|
2036
|
+
# * {Types::UpdateLibraryItemOutput#categories #categories} => Array<Types::Category>
|
2037
|
+
# * {Types::UpdateLibraryItemOutput#status #status} => String
|
2038
|
+
# * {Types::UpdateLibraryItemOutput#created_at #created_at} => Time
|
2039
|
+
# * {Types::UpdateLibraryItemOutput#created_by #created_by} => String
|
2040
|
+
# * {Types::UpdateLibraryItemOutput#updated_at #updated_at} => Time
|
2041
|
+
# * {Types::UpdateLibraryItemOutput#updated_by #updated_by} => String
|
2042
|
+
# * {Types::UpdateLibraryItemOutput#rating_count #rating_count} => Integer
|
2043
|
+
# * {Types::UpdateLibraryItemOutput#is_rated_by_user #is_rated_by_user} => Boolean
|
2044
|
+
# * {Types::UpdateLibraryItemOutput#user_count #user_count} => Integer
|
2045
|
+
#
|
2046
|
+
#
|
2047
|
+
# @example Example: Sets the status of a library item to DISABLED
|
2048
|
+
#
|
2049
|
+
# resp = client.update_library_item({
|
2050
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
2051
|
+
# library_item_id: "cb9ecf72-8563-450d-9db9-994f98297316",
|
2052
|
+
# status: "DISABLED",
|
2053
|
+
# })
|
2054
|
+
#
|
2055
|
+
# resp.to_h outputs the following:
|
2056
|
+
# {
|
2057
|
+
# app_id: "7a11f34b-42d4-4bc8-b668-ae4a788dae1e",
|
2058
|
+
# app_version: 6,
|
2059
|
+
# categories: [
|
2060
|
+
# {
|
2061
|
+
# id: "9c871ed4-1c41-4065-aefe-321cd4b61cf8",
|
2062
|
+
# title: "HR",
|
2063
|
+
# },
|
2064
|
+
# {
|
2065
|
+
# id: "fdc4b483-c4e2-44c9-b4b2-6c850bbdb579",
|
2066
|
+
# title: "General",
|
2067
|
+
# },
|
2068
|
+
# {
|
2069
|
+
# id: "c1c4e374-118c-446f-81fb-cba6225d88da",
|
2070
|
+
# title: "IT",
|
2071
|
+
# },
|
2072
|
+
# ],
|
2073
|
+
# created_at: Time.parse("2024-05-21T23:17:27.350Z"),
|
2074
|
+
# created_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
2075
|
+
# library_item_id: "cb9ecf72-8563-450d-9db9-994f98297316",
|
2076
|
+
# rating_count: 24,
|
2077
|
+
# status: "DISABLED",
|
2078
|
+
# updated_at: Time.parse("2024-05-28T19:43:48.577Z"),
|
2079
|
+
# updated_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
2080
|
+
# }
|
2081
|
+
#
|
2082
|
+
# @example Request syntax with placeholder values
|
2083
|
+
#
|
2084
|
+
# resp = client.update_library_item({
|
2085
|
+
# instance_id: "InstanceId", # required
|
2086
|
+
# library_item_id: "UUID", # required
|
2087
|
+
# status: "PUBLISHED", # accepts PUBLISHED, DISABLED
|
2088
|
+
# categories: ["UUID"],
|
2089
|
+
# })
|
2090
|
+
#
|
2091
|
+
# @example Response structure
|
2092
|
+
#
|
2093
|
+
# resp.library_item_id #=> String
|
2094
|
+
# resp.app_id #=> String
|
2095
|
+
# resp.app_version #=> Integer
|
2096
|
+
# resp.categories #=> Array
|
2097
|
+
# resp.categories[0].id #=> String
|
2098
|
+
# resp.categories[0].title #=> String
|
2099
|
+
# resp.status #=> String
|
2100
|
+
# resp.created_at #=> Time
|
2101
|
+
# resp.created_by #=> String
|
2102
|
+
# resp.updated_at #=> Time
|
2103
|
+
# resp.updated_by #=> String
|
2104
|
+
# resp.rating_count #=> Integer
|
2105
|
+
# resp.is_rated_by_user #=> Boolean
|
2106
|
+
# resp.user_count #=> Integer
|
2107
|
+
#
|
2108
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/UpdateLibraryItem AWS API Documentation
|
2109
|
+
#
|
2110
|
+
# @overload update_library_item(params = {})
|
2111
|
+
# @param [Hash] params ({})
|
2112
|
+
def update_library_item(params = {}, options = {})
|
2113
|
+
req = build_request(:update_library_item, params)
|
2114
|
+
req.send_request(options)
|
2115
|
+
end
|
2116
|
+
|
2117
|
+
# Updates an existing Amazon Q App, allowing modifications to its title,
|
2118
|
+
# description, and definition.
|
2119
|
+
#
|
2120
|
+
# @option params [required, String] :instance_id
|
2121
|
+
# The unique identifier of the Amazon Q Business application environment
|
2122
|
+
# instance.
|
2123
|
+
#
|
2124
|
+
# @option params [required, String] :app_id
|
2125
|
+
# The unique identifier of the Q App to update.
|
2126
|
+
#
|
2127
|
+
# @option params [String] :title
|
2128
|
+
# The new title for the Q App.
|
2129
|
+
#
|
2130
|
+
# @option params [String] :description
|
2131
|
+
# The new description for the Q App.
|
2132
|
+
#
|
2133
|
+
# @option params [Types::AppDefinitionInput] :app_definition
|
2134
|
+
# The new definition specifying the cards and flow for the Q App.
|
2135
|
+
#
|
2136
|
+
# @return [Types::UpdateQAppOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
2137
|
+
#
|
2138
|
+
# * {Types::UpdateQAppOutput#app_id #app_id} => String
|
2139
|
+
# * {Types::UpdateQAppOutput#app_arn #app_arn} => String
|
2140
|
+
# * {Types::UpdateQAppOutput#title #title} => String
|
2141
|
+
# * {Types::UpdateQAppOutput#description #description} => String
|
2142
|
+
# * {Types::UpdateQAppOutput#initial_prompt #initial_prompt} => String
|
2143
|
+
# * {Types::UpdateQAppOutput#app_version #app_version} => Integer
|
2144
|
+
# * {Types::UpdateQAppOutput#status #status} => String
|
2145
|
+
# * {Types::UpdateQAppOutput#created_at #created_at} => Time
|
2146
|
+
# * {Types::UpdateQAppOutput#created_by #created_by} => String
|
2147
|
+
# * {Types::UpdateQAppOutput#updated_at #updated_at} => Time
|
2148
|
+
# * {Types::UpdateQAppOutput#updated_by #updated_by} => String
|
2149
|
+
# * {Types::UpdateQAppOutput#required_capabilities #required_capabilities} => Array<String>
|
2150
|
+
#
|
2151
|
+
#
|
2152
|
+
# @example Example: Updating the title of an app
|
2153
|
+
#
|
2154
|
+
# resp = client.update_q_app({
|
2155
|
+
# app_id: "7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
2156
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
2157
|
+
# title: "This is the new title",
|
2158
|
+
# })
|
2159
|
+
#
|
2160
|
+
# resp.to_h outputs the following:
|
2161
|
+
# {
|
2162
|
+
# app_arn: "arn:aws:qapps:us-west-2:123456789012:app/7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
2163
|
+
# app_id: "7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
2164
|
+
# app_version: 2,
|
2165
|
+
# created_at: Time.parse("2024-05-14T00:11:54.232Z"),
|
2166
|
+
# created_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
2167
|
+
# required_capabilities: [
|
2168
|
+
# "CreatorMode",
|
2169
|
+
# ],
|
2170
|
+
# status: "DRAFT",
|
2171
|
+
# title: "This is the new title",
|
2172
|
+
# updated_at: Time.parse("2024-05-17T23:15:08.571Z"),
|
2173
|
+
# updated_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
2174
|
+
# }
|
2175
|
+
#
|
2176
|
+
# @example Example: Updating the app so it has a single q-query card
|
2177
|
+
#
|
2178
|
+
# resp = client.update_q_app({
|
2179
|
+
# app_definition: {
|
2180
|
+
# cards: [
|
2181
|
+
# {
|
2182
|
+
# q_query: {
|
2183
|
+
# type: "q-query",
|
2184
|
+
# id: "18870b94-1e63-40e0-8c12-669c90ac5acc",
|
2185
|
+
# prompt: "Recommend me an itinerary for a trip",
|
2186
|
+
# title: "Trip Ideas",
|
2187
|
+
# },
|
2188
|
+
# },
|
2189
|
+
# ],
|
2190
|
+
# },
|
2191
|
+
# app_id: "7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
2192
|
+
# instance_id: "0b95c9c4-89cc-4aa8-9aae-aa91cbec699f",
|
2193
|
+
# })
|
2194
|
+
#
|
2195
|
+
# resp.to_h outputs the following:
|
2196
|
+
# {
|
2197
|
+
# app_arn: "arn:aws:qapps:us-west-2:123456789012:app/7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
2198
|
+
# app_id: "7212ff04-de7b-4831-bd80-45d6975ba1b0",
|
2199
|
+
# app_version: 99,
|
2200
|
+
# created_at: Time.parse("2024-05-14T00:11:54.232Z"),
|
2201
|
+
# created_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
2202
|
+
# required_capabilities: [
|
2203
|
+
# "CreatorMode",
|
2204
|
+
# ],
|
2205
|
+
# status: "DRAFT",
|
2206
|
+
# title: "Previous Title Stays the Same",
|
2207
|
+
# updated_at: Time.parse("2024-05-17T23:15:08.571Z"),
|
2208
|
+
# updated_by: "a841e300-40c1-7062-fa34-5b46dadbbaac",
|
2209
|
+
# }
|
2210
|
+
#
|
2211
|
+
# @example Request syntax with placeholder values
|
2212
|
+
#
|
2213
|
+
# resp = client.update_q_app({
|
2214
|
+
# instance_id: "InstanceId", # required
|
2215
|
+
# app_id: "UUID", # required
|
2216
|
+
# title: "Title",
|
2217
|
+
# description: "Description",
|
2218
|
+
# app_definition: {
|
2219
|
+
# cards: [ # required
|
2220
|
+
# {
|
2221
|
+
# text_input: {
|
2222
|
+
# title: "Title", # required
|
2223
|
+
# id: "UUID", # required
|
2224
|
+
# type: "text-input", # required, accepts text-input, q-query, file-upload, q-plugin
|
2225
|
+
# placeholder: "Placeholder",
|
2226
|
+
# default_value: "Default",
|
2227
|
+
# },
|
2228
|
+
# q_query: {
|
2229
|
+
# title: "Title", # required
|
2230
|
+
# id: "UUID", # required
|
2231
|
+
# type: "text-input", # required, accepts text-input, q-query, file-upload, q-plugin
|
2232
|
+
# prompt: "Prompt", # required
|
2233
|
+
# output_source: "approved-sources", # accepts approved-sources, llm
|
2234
|
+
# attribute_filter: {
|
2235
|
+
# and_all_filters: [
|
2236
|
+
# {
|
2237
|
+
# # recursive AttributeFilter
|
2238
|
+
# },
|
2239
|
+
# ],
|
2240
|
+
# or_all_filters: [
|
2241
|
+
# {
|
2242
|
+
# # recursive AttributeFilter
|
2243
|
+
# },
|
2244
|
+
# ],
|
2245
|
+
# not_filter: {
|
2246
|
+
# # recursive AttributeFilter
|
2247
|
+
# },
|
2248
|
+
# equals_to: {
|
2249
|
+
# name: "DocumentAttributeKey", # required
|
2250
|
+
# value: { # required
|
2251
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
2252
|
+
# string_list_value: ["PlatoString"],
|
2253
|
+
# long_value: 1,
|
2254
|
+
# date_value: Time.now,
|
2255
|
+
# },
|
2256
|
+
# },
|
2257
|
+
# contains_all: {
|
2258
|
+
# name: "DocumentAttributeKey", # required
|
2259
|
+
# value: { # required
|
2260
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
2261
|
+
# string_list_value: ["PlatoString"],
|
2262
|
+
# long_value: 1,
|
2263
|
+
# date_value: Time.now,
|
2264
|
+
# },
|
2265
|
+
# },
|
2266
|
+
# contains_any: {
|
2267
|
+
# name: "DocumentAttributeKey", # required
|
2268
|
+
# value: { # required
|
2269
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
2270
|
+
# string_list_value: ["PlatoString"],
|
2271
|
+
# long_value: 1,
|
2272
|
+
# date_value: Time.now,
|
2273
|
+
# },
|
2274
|
+
# },
|
2275
|
+
# greater_than: {
|
2276
|
+
# name: "DocumentAttributeKey", # required
|
2277
|
+
# value: { # required
|
2278
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
2279
|
+
# string_list_value: ["PlatoString"],
|
2280
|
+
# long_value: 1,
|
2281
|
+
# date_value: Time.now,
|
2282
|
+
# },
|
2283
|
+
# },
|
2284
|
+
# greater_than_or_equals: {
|
2285
|
+
# name: "DocumentAttributeKey", # required
|
2286
|
+
# value: { # required
|
2287
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
2288
|
+
# string_list_value: ["PlatoString"],
|
2289
|
+
# long_value: 1,
|
2290
|
+
# date_value: Time.now,
|
2291
|
+
# },
|
2292
|
+
# },
|
2293
|
+
# less_than: {
|
2294
|
+
# name: "DocumentAttributeKey", # required
|
2295
|
+
# value: { # required
|
2296
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
2297
|
+
# string_list_value: ["PlatoString"],
|
2298
|
+
# long_value: 1,
|
2299
|
+
# date_value: Time.now,
|
2300
|
+
# },
|
2301
|
+
# },
|
2302
|
+
# less_than_or_equals: {
|
2303
|
+
# name: "DocumentAttributeKey", # required
|
2304
|
+
# value: { # required
|
2305
|
+
# string_value: "DocumentAttributeValueStringValueString",
|
2306
|
+
# string_list_value: ["PlatoString"],
|
2307
|
+
# long_value: 1,
|
2308
|
+
# date_value: Time.now,
|
2309
|
+
# },
|
2310
|
+
# },
|
2311
|
+
# },
|
2312
|
+
# },
|
2313
|
+
# q_plugin: {
|
2314
|
+
# title: "Title", # required
|
2315
|
+
# id: "UUID", # required
|
2316
|
+
# type: "text-input", # required, accepts text-input, q-query, file-upload, q-plugin
|
2317
|
+
# prompt: "Prompt", # required
|
2318
|
+
# plugin_id: "PluginId", # required
|
2319
|
+
# },
|
2320
|
+
# file_upload: {
|
2321
|
+
# title: "Title", # required
|
2322
|
+
# id: "UUID", # required
|
2323
|
+
# type: "text-input", # required, accepts text-input, q-query, file-upload, q-plugin
|
2324
|
+
# filename: "Filename",
|
2325
|
+
# file_id: "UUID",
|
2326
|
+
# allow_override: false,
|
2327
|
+
# },
|
2328
|
+
# },
|
2329
|
+
# ],
|
2330
|
+
# initial_prompt: "InitialPrompt",
|
2331
|
+
# },
|
2332
|
+
# })
|
2333
|
+
#
|
2334
|
+
# @example Response structure
|
2335
|
+
#
|
2336
|
+
# resp.app_id #=> String
|
2337
|
+
# resp.app_arn #=> String
|
2338
|
+
# resp.title #=> String
|
2339
|
+
# resp.description #=> String
|
2340
|
+
# resp.initial_prompt #=> String
|
2341
|
+
# resp.app_version #=> Integer
|
2342
|
+
# resp.status #=> String, one of "PUBLISHED", "DRAFT", "DELETED"
|
2343
|
+
# resp.created_at #=> Time
|
2344
|
+
# resp.created_by #=> String
|
2345
|
+
# resp.updated_at #=> Time
|
2346
|
+
# resp.updated_by #=> String
|
2347
|
+
# resp.required_capabilities #=> Array
|
2348
|
+
# resp.required_capabilities[0] #=> String, one of "FileUpload", "CreatorMode", "RetrievalMode", "PluginMode"
|
2349
|
+
#
|
2350
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/UpdateQApp AWS API Documentation
|
2351
|
+
#
|
2352
|
+
# @overload update_q_app(params = {})
|
2353
|
+
# @param [Hash] params ({})
|
2354
|
+
def update_q_app(params = {}, options = {})
|
2355
|
+
req = build_request(:update_q_app, params)
|
2356
|
+
req.send_request(options)
|
2357
|
+
end
|
2358
|
+
|
2359
|
+
# Updates the session for a given Q App `sessionId`. This is only valid
|
2360
|
+
# when at least one card of the session is in the `WAITING` state. Data
|
2361
|
+
# for each `WAITING` card can be provided as input. If inputs are not
|
2362
|
+
# provided, the call will be accepted but session will not move forward.
|
2363
|
+
# Inputs for cards that are not in the `WAITING` status will be ignored.
|
2364
|
+
#
|
2365
|
+
# @option params [required, String] :instance_id
|
2366
|
+
# The unique identifier of the Amazon Q Business application environment
|
2367
|
+
# instance.
|
2368
|
+
#
|
2369
|
+
# @option params [required, String] :session_id
|
2370
|
+
# The unique identifier of the Q App session to provide input for.
|
2371
|
+
#
|
2372
|
+
# @option params [Array<Types::CardValue>] :values
|
2373
|
+
# The input values to provide for the current state of the Q App
|
2374
|
+
# session.
|
2375
|
+
#
|
2376
|
+
# @return [Types::UpdateQAppSessionOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
2377
|
+
#
|
2378
|
+
# * {Types::UpdateQAppSessionOutput#session_id #session_id} => String
|
2379
|
+
# * {Types::UpdateQAppSessionOutput#session_arn #session_arn} => String
|
2380
|
+
#
|
2381
|
+
# @example Request syntax with placeholder values
|
2382
|
+
#
|
2383
|
+
# resp = client.update_q_app_session({
|
2384
|
+
# instance_id: "InstanceId", # required
|
2385
|
+
# session_id: "UUID", # required
|
2386
|
+
# values: [
|
2387
|
+
# {
|
2388
|
+
# card_id: "UUID", # required
|
2389
|
+
# value: "CardValueValueString", # required
|
2390
|
+
# },
|
2391
|
+
# ],
|
2392
|
+
# })
|
2393
|
+
#
|
2394
|
+
# @example Response structure
|
2395
|
+
#
|
2396
|
+
# resp.session_id #=> String
|
2397
|
+
# resp.session_arn #=> String
|
2398
|
+
#
|
2399
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/qapps-2023-11-27/UpdateQAppSession AWS API Documentation
|
2400
|
+
#
|
2401
|
+
# @overload update_q_app_session(params = {})
|
2402
|
+
# @param [Hash] params ({})
|
2403
|
+
def update_q_app_session(params = {}, options = {})
|
2404
|
+
req = build_request(:update_q_app_session, params)
|
2405
|
+
req.send_request(options)
|
2406
|
+
end
|
2407
|
+
|
2408
|
+
# @!endgroup
|
2409
|
+
|
2410
|
+
# @param params ({})
|
2411
|
+
# @api private
|
2412
|
+
def build_request(operation_name, params = {})
|
2413
|
+
handlers = @handlers.for(operation_name)
|
2414
|
+
context = Seahorse::Client::RequestContext.new(
|
2415
|
+
operation_name: operation_name,
|
2416
|
+
operation: config.api.operation(operation_name),
|
2417
|
+
client: self,
|
2418
|
+
params: params,
|
2419
|
+
config: config)
|
2420
|
+
context[:gem_name] = 'aws-sdk-qapps'
|
2421
|
+
context[:gem_version] = '1.0.0'
|
2422
|
+
Seahorse::Client::Request.new(handlers, context)
|
2423
|
+
end
|
2424
|
+
|
2425
|
+
# @api private
|
2426
|
+
# @deprecated
|
2427
|
+
def waiter_names
|
2428
|
+
[]
|
2429
|
+
end
|
2430
|
+
|
2431
|
+
class << self
|
2432
|
+
|
2433
|
+
# @api private
|
2434
|
+
attr_reader :identifier
|
2435
|
+
|
2436
|
+
# @api private
|
2437
|
+
def errors_module
|
2438
|
+
Errors
|
2439
|
+
end
|
2440
|
+
|
2441
|
+
end
|
2442
|
+
end
|
2443
|
+
end
|