aws-sdk-workspaces 1.0.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: d1c92a9a5443a78e8834bf11af05473b13ec0947
4
+ data.tar.gz: adb99c1af7f28d70e0f134d3706dfd372d2b1755
5
+ SHA512:
6
+ metadata.gz: 0bdcf0c5788eaabe93f0da78e28293235598734c6999d087ed31ce00a9eeee8b2b8d6d15bb4a83e7d5eeb5294500d7d466c5a3ba79b551589c5f88ee73391378
7
+ data.tar.gz: 2689f9afdc7cfbe740fb67b0814688f30afaddc58ef0e341ac6be789fcce457d7cfc97ba08ebbb42cc318065cc64eb88bb008b39ccf70ba9f0943df2ff4a2bec
@@ -0,0 +1,47 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing for info on making contributions:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
8
+ require 'aws-sdk-core'
9
+ require 'aws-sigv4'
10
+
11
+ require_relative 'aws-sdk-workspaces/types'
12
+ require_relative 'aws-sdk-workspaces/client_api'
13
+ require_relative 'aws-sdk-workspaces/client'
14
+ require_relative 'aws-sdk-workspaces/errors'
15
+ require_relative 'aws-sdk-workspaces/resource'
16
+ require_relative 'aws-sdk-workspaces/customizations'
17
+
18
+ # This module provides support for Amazon WorkSpaces. This module is available in the
19
+ # `aws-sdk-workspaces` gem.
20
+ #
21
+ # # Client
22
+ #
23
+ # The {Client} class provides one method for each API operation. Operation
24
+ # methods each accept a hash of request parameters and return a response
25
+ # structure.
26
+ #
27
+ # See {Client} for more information.
28
+ #
29
+ # # Errors
30
+ #
31
+ # Errors returned from Amazon WorkSpaces all
32
+ # extend {Errors::ServiceError}.
33
+ #
34
+ # begin
35
+ # # do stuff
36
+ # rescue Aws::WorkSpaces::Errors::ServiceError
37
+ # # rescues all service API errors
38
+ # end
39
+ #
40
+ # See {Errors} for more information.
41
+ #
42
+ # @service
43
+ module Aws::WorkSpaces
44
+
45
+ GEM_VERSION = '1.0.0.rc1'
46
+
47
+ end
@@ -0,0 +1,742 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing for info on making contributions:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
8
+ require 'seahorse/client/plugins/content_length.rb'
9
+ require 'aws-sdk-core/plugins/credentials_configuration.rb'
10
+ require 'aws-sdk-core/plugins/logging.rb'
11
+ require 'aws-sdk-core/plugins/param_converter.rb'
12
+ require 'aws-sdk-core/plugins/param_validator.rb'
13
+ require 'aws-sdk-core/plugins/user_agent.rb'
14
+ require 'aws-sdk-core/plugins/helpful_socket_errors.rb'
15
+ require 'aws-sdk-core/plugins/retry_errors.rb'
16
+ require 'aws-sdk-core/plugins/global_configuration.rb'
17
+ require 'aws-sdk-core/plugins/regional_endpoint.rb'
18
+ require 'aws-sdk-core/plugins/response_paging.rb'
19
+ require 'aws-sdk-core/plugins/stub_responses.rb'
20
+ require 'aws-sdk-core/plugins/idempotency_token.rb'
21
+ require 'aws-sdk-core/plugins/signature_v4.rb'
22
+ require 'aws-sdk-core/plugins/protocols/json_rpc.rb'
23
+
24
+ Aws::Plugins::GlobalConfiguration.add_identifier(:workspaces)
25
+
26
+ module Aws
27
+ module WorkSpaces
28
+ class Client < Seahorse::Client::Base
29
+
30
+ include Aws::ClientStubs
31
+
32
+ @identifier = :workspaces
33
+
34
+ set_api(ClientApi::API)
35
+
36
+ add_plugin(Seahorse::Client::Plugins::ContentLength)
37
+ add_plugin(Aws::Plugins::CredentialsConfiguration)
38
+ add_plugin(Aws::Plugins::Logging)
39
+ add_plugin(Aws::Plugins::ParamConverter)
40
+ add_plugin(Aws::Plugins::ParamValidator)
41
+ add_plugin(Aws::Plugins::UserAgent)
42
+ add_plugin(Aws::Plugins::HelpfulSocketErrors)
43
+ add_plugin(Aws::Plugins::RetryErrors)
44
+ add_plugin(Aws::Plugins::GlobalConfiguration)
45
+ add_plugin(Aws::Plugins::RegionalEndpoint)
46
+ add_plugin(Aws::Plugins::ResponsePaging)
47
+ add_plugin(Aws::Plugins::StubResponses)
48
+ add_plugin(Aws::Plugins::IdempotencyToken)
49
+ add_plugin(Aws::Plugins::SignatureV4)
50
+ add_plugin(Aws::Plugins::Protocols::JsonRpc)
51
+
52
+ # @option options [required, Aws::CredentialProvider] :credentials
53
+ # Your AWS credentials. This can be an instance of any one of the
54
+ # following classes:
55
+ #
56
+ # * `Aws::Credentials` - Used for configuring static, non-refreshing
57
+ # credentials.
58
+ #
59
+ # * `Aws::InstanceProfileCredentials` - Used for loading credentials
60
+ # from an EC2 IMDS on an EC2 instance.
61
+ #
62
+ # * `Aws::SharedCredentials` - Used for loading credentials from a
63
+ # shared file, such as `~/.aws/config`.
64
+ #
65
+ # * `Aws::AssumeRoleCredentials` - Used when you need to assume a role.
66
+ #
67
+ # When `:credentials` are not configured directly, the following
68
+ # locations will be searched for credentials:
69
+ #
70
+ # * `Aws.config[:credentials]`
71
+ # * The `:access_key_id`, `:secret_access_key`, and `:session_token` options.
72
+ # * ENV['AWS_ACCESS_KEY_ID'], ENV['AWS_SECRET_ACCESS_KEY']
73
+ # * `~/.aws/credentials`
74
+ # * `~/.aws/config`
75
+ # * EC2 IMDS instance profile - When used by default, the timeouts are
76
+ # very aggressive. Construct and pass an instance of
77
+ # `Aws::InstanceProfileCredentails` to enable retries and extended
78
+ # timeouts.
79
+ # @option options [required, String] :region
80
+ # The AWS region to connect to. The configured `:region` is
81
+ # used to determine the service `:endpoint`. When not passed,
82
+ # a default `:region` is search for in the following locations:
83
+ #
84
+ # * `Aws.config[:region]`
85
+ # * `ENV['AWS_REGION']`
86
+ # * `ENV['AMAZON_REGION']`
87
+ # * `ENV['AWS_DEFAULT_REGION']`
88
+ # * `~/.aws/credentials`
89
+ # * `~/.aws/config`
90
+ # @option options [String] :access_key_id
91
+ # @option options [Boolean] :convert_params (true)
92
+ # When `true`, an attempt is made to coerce request parameters into
93
+ # the required types.
94
+ # @option options [String] :endpoint
95
+ # The client endpoint is normally constructed from the `:region`
96
+ # option. You should only configure an `:endpoint` when connecting
97
+ # to test endpoints. This should be avalid HTTP(S) URI.
98
+ # @option options [Aws::Log::Formatter] :log_formatter (Aws::Log::Formatter.default)
99
+ # The log formatter.
100
+ # @option options [Symbol] :log_level (:info)
101
+ # The log level to send messages to the `:logger` at.
102
+ # @option options [Logger] :logger
103
+ # The Logger instance to send log messages to. If this option
104
+ # is not set, logging will be disabled.
105
+ # @option options [String] :profile ("default")
106
+ # Used when loading credentials from the shared credentials file
107
+ # at HOME/.aws/credentials. When not specified, 'default' is used.
108
+ # @option options [Integer] :retry_limit (3)
109
+ # The maximum number of times to retry failed requests. Only
110
+ # ~ 500 level server errors and certain ~ 400 level client errors
111
+ # are retried. Generally, these are throttling errors, data
112
+ # checksum errors, networking errors, timeout errors and auth
113
+ # errors from expired credentials.
114
+ # @option options [String] :secret_access_key
115
+ # @option options [String] :session_token
116
+ # @option options [Boolean] :simple_json (false)
117
+ # Disables request parameter conversion, validation, and formatting.
118
+ # Also disable response data type conversions. This option is useful
119
+ # when you want to ensure the highest level of performance by
120
+ # avoiding overhead of walking request parameters and response data
121
+ # structures.
122
+ #
123
+ # When `:simple_json` is enabled, the request parameters hash must
124
+ # be formatted exactly as the DynamoDB API expects.
125
+ # @option options [Boolean] :stub_responses (false)
126
+ # Causes the client to return stubbed responses. By default
127
+ # fake responses are generated and returned. You can specify
128
+ # the response data to return or errors to raise by calling
129
+ # {ClientStubs#stub_responses}. See {ClientStubs} for more information.
130
+ #
131
+ # ** Please note ** When response stubbing is enabled, no HTTP
132
+ # requests are made, and retries are disabled.
133
+ # @option options [Boolean] :validate_params (true)
134
+ # When `true`, request parameters are validated before
135
+ # sending the request.
136
+ def initialize(*args)
137
+ super
138
+ end
139
+
140
+ # @!group API Operations
141
+
142
+ # Creates tags for a WorkSpace.
143
+ # @option params [required, String] :resource_id
144
+ # The resource ID of the request.
145
+ # @option params [required, Array<Types::Tag>] :tags
146
+ # The tags of the request.
147
+ # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
148
+ #
149
+ # @example Request syntax with placeholder values
150
+ # resp = client.create_tags({
151
+ # resource_id: "NonEmptyString", # required
152
+ # tags: [ # required
153
+ # {
154
+ # key: "TagKey", # required
155
+ # value: "TagValue",
156
+ # },
157
+ # ],
158
+ # })
159
+ # @overload create_tags(params = {})
160
+ # @param [Hash] params ({})
161
+ def create_tags(params = {}, options = {})
162
+ req = build_request(:create_tags, params)
163
+ req.send_request(options)
164
+ end
165
+
166
+ # Creates one or more WorkSpaces.
167
+ #
168
+ # <note markdown="1"> This operation is asynchronous and returns before the WorkSpaces are
169
+ # created.
170
+ #
171
+ # </note>
172
+ # @option params [required, Array<Types::WorkspaceRequest>] :workspaces
173
+ # An array of structures that specify the WorkSpaces to create.
174
+ # @return [Types::CreateWorkspacesResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
175
+ #
176
+ # * {Types::CreateWorkspacesResult#failed_requests #FailedRequests} => Array&lt;Types::FailedCreateWorkspaceRequest&gt;
177
+ # * {Types::CreateWorkspacesResult#pending_requests #PendingRequests} => Array&lt;Types::Workspace&gt;
178
+ #
179
+ # @example Request syntax with placeholder values
180
+ # resp = client.create_workspaces({
181
+ # workspaces: [ # required
182
+ # {
183
+ # directory_id: "DirectoryId", # required
184
+ # user_name: "UserName", # required
185
+ # bundle_id: "BundleId", # required
186
+ # volume_encryption_key: "VolumeEncryptionKey",
187
+ # user_volume_encryption_enabled: false,
188
+ # root_volume_encryption_enabled: false,
189
+ # workspace_properties: {
190
+ # running_mode: "AUTO_STOP", # accepts AUTO_STOP, ALWAYS_ON
191
+ # running_mode_auto_stop_timeout_in_minutes: 1,
192
+ # },
193
+ # tags: [
194
+ # {
195
+ # key: "TagKey", # required
196
+ # value: "TagValue",
197
+ # },
198
+ # ],
199
+ # },
200
+ # ],
201
+ # })
202
+ #
203
+ # @example Response structure
204
+ # resp.failed_requests #=> Array
205
+ # resp.failed_requests[0].workspace_request.directory_id #=> String
206
+ # resp.failed_requests[0].workspace_request.user_name #=> String
207
+ # resp.failed_requests[0].workspace_request.bundle_id #=> String
208
+ # resp.failed_requests[0].workspace_request.volume_encryption_key #=> String
209
+ # resp.failed_requests[0].workspace_request.user_volume_encryption_enabled #=> Boolean
210
+ # resp.failed_requests[0].workspace_request.root_volume_encryption_enabled #=> Boolean
211
+ # resp.failed_requests[0].workspace_request.workspace_properties.running_mode #=> String, one of "AUTO_STOP", "ALWAYS_ON"
212
+ # resp.failed_requests[0].workspace_request.workspace_properties.running_mode_auto_stop_timeout_in_minutes #=> Integer
213
+ # resp.failed_requests[0].workspace_request.tags #=> Array
214
+ # resp.failed_requests[0].workspace_request.tags[0].key #=> String
215
+ # resp.failed_requests[0].workspace_request.tags[0].value #=> String
216
+ # resp.failed_requests[0].error_code #=> String
217
+ # resp.failed_requests[0].error_message #=> String
218
+ # resp.pending_requests #=> Array
219
+ # resp.pending_requests[0].workspace_id #=> String
220
+ # resp.pending_requests[0].directory_id #=> String
221
+ # resp.pending_requests[0].user_name #=> String
222
+ # resp.pending_requests[0].ip_address #=> String
223
+ # resp.pending_requests[0].state #=> String, one of "PENDING", "AVAILABLE", "IMPAIRED", "UNHEALTHY", "REBOOTING", "STARTING", "REBUILDING", "MAINTENANCE", "TERMINATING", "TERMINATED", "SUSPENDED", "STOPPING", "STOPPED", "ERROR"
224
+ # resp.pending_requests[0].bundle_id #=> String
225
+ # resp.pending_requests[0].subnet_id #=> String
226
+ # resp.pending_requests[0].error_message #=> String
227
+ # resp.pending_requests[0].error_code #=> String
228
+ # resp.pending_requests[0].computer_name #=> String
229
+ # resp.pending_requests[0].volume_encryption_key #=> String
230
+ # resp.pending_requests[0].user_volume_encryption_enabled #=> Boolean
231
+ # resp.pending_requests[0].root_volume_encryption_enabled #=> Boolean
232
+ # resp.pending_requests[0].workspace_properties.running_mode #=> String, one of "AUTO_STOP", "ALWAYS_ON"
233
+ # resp.pending_requests[0].workspace_properties.running_mode_auto_stop_timeout_in_minutes #=> Integer
234
+ # @overload create_workspaces(params = {})
235
+ # @param [Hash] params ({})
236
+ def create_workspaces(params = {}, options = {})
237
+ req = build_request(:create_workspaces, params)
238
+ req.send_request(options)
239
+ end
240
+
241
+ # Deletes tags from a WorkSpace.
242
+ # @option params [required, String] :resource_id
243
+ # The resource ID of the request.
244
+ # @option params [required, Array<String>] :tag_keys
245
+ # The tag keys of the request.
246
+ # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
247
+ #
248
+ # @example Request syntax with placeholder values
249
+ # resp = client.delete_tags({
250
+ # resource_id: "NonEmptyString", # required
251
+ # tag_keys: ["NonEmptyString"], # required
252
+ # })
253
+ # @overload delete_tags(params = {})
254
+ # @param [Hash] params ({})
255
+ def delete_tags(params = {}, options = {})
256
+ req = build_request(:delete_tags, params)
257
+ req.send_request(options)
258
+ end
259
+
260
+ # Describes tags for a WorkSpace.
261
+ # @option params [required, String] :resource_id
262
+ # The resource ID of the request.
263
+ # @return [Types::DescribeTagsResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
264
+ #
265
+ # * {Types::DescribeTagsResult#tag_list #TagList} => Array&lt;Types::Tag&gt;
266
+ #
267
+ # @example Request syntax with placeholder values
268
+ # resp = client.describe_tags({
269
+ # resource_id: "NonEmptyString", # required
270
+ # })
271
+ #
272
+ # @example Response structure
273
+ # resp.tag_list #=> Array
274
+ # resp.tag_list[0].key #=> String
275
+ # resp.tag_list[0].value #=> String
276
+ # @overload describe_tags(params = {})
277
+ # @param [Hash] params ({})
278
+ def describe_tags(params = {}, options = {})
279
+ req = build_request(:describe_tags, params)
280
+ req.send_request(options)
281
+ end
282
+
283
+ # Obtains information about the WorkSpace bundles that are available to
284
+ # your account in the specified region.
285
+ #
286
+ # You can filter the results with either the `BundleIds` parameter, or
287
+ # the `Owner` parameter, but not both.
288
+ #
289
+ # This operation supports pagination with the use of the `NextToken`
290
+ # request and response parameters. If more results are available, the
291
+ # `NextToken` response member contains a token that you pass in the next
292
+ # call to this operation to retrieve the next set of items.
293
+ # @option params [Array<String>] :bundle_ids
294
+ # An array of strings that contains the identifiers of the bundles to
295
+ # retrieve. This parameter cannot be combined with any other filter
296
+ # parameter.
297
+ # @option params [String] :owner
298
+ # The owner of the bundles to retrieve. This parameter cannot be
299
+ # combined with any other filter parameter.
300
+ #
301
+ # This contains one of the following values:
302
+ #
303
+ # * null- Retrieves the bundles that belong to the account making the
304
+ # call.
305
+ #
306
+ # * `AMAZON`- Retrieves the bundles that are provided by AWS.
307
+ # @option params [String] :next_token
308
+ # The `NextToken` value from a previous call to this operation. Pass
309
+ # null if this is the first call.
310
+ # @return [Types::DescribeWorkspaceBundlesResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
311
+ #
312
+ # * {Types::DescribeWorkspaceBundlesResult#bundles #Bundles} => Array&lt;Types::WorkspaceBundle&gt;
313
+ # * {Types::DescribeWorkspaceBundlesResult#next_token #NextToken} => String
314
+ #
315
+ # @example Request syntax with placeholder values
316
+ # resp = client.describe_workspace_bundles({
317
+ # bundle_ids: ["BundleId"],
318
+ # owner: "BundleOwner",
319
+ # next_token: "PaginationToken",
320
+ # })
321
+ #
322
+ # @example Response structure
323
+ # resp.bundles #=> Array
324
+ # resp.bundles[0].bundle_id #=> String
325
+ # resp.bundles[0].name #=> String
326
+ # resp.bundles[0].owner #=> String
327
+ # resp.bundles[0].description #=> String
328
+ # resp.bundles[0].user_storage.capacity #=> String
329
+ # resp.bundles[0].compute_type.name #=> String, one of "VALUE", "STANDARD", "PERFORMANCE"
330
+ # resp.next_token #=> String
331
+ # @overload describe_workspace_bundles(params = {})
332
+ # @param [Hash] params ({})
333
+ def describe_workspace_bundles(params = {}, options = {})
334
+ req = build_request(:describe_workspace_bundles, params)
335
+ req.send_request(options)
336
+ end
337
+
338
+ # Retrieves information about the AWS Directory Service directories in
339
+ # the region that are registered with Amazon WorkSpaces and are
340
+ # available to your account.
341
+ #
342
+ # This operation supports pagination with the use of the `NextToken`
343
+ # request and response parameters. If more results are available, the
344
+ # `NextToken` response member contains a token that you pass in the next
345
+ # call to this operation to retrieve the next set of items.
346
+ # @option params [Array<String>] :directory_ids
347
+ # An array of strings that contains the directory identifiers to
348
+ # retrieve information for. If this member is null, all directories are
349
+ # retrieved.
350
+ # @option params [String] :next_token
351
+ # The `NextToken` value from a previous call to this operation. Pass
352
+ # null if this is the first call.
353
+ # @return [Types::DescribeWorkspaceDirectoriesResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
354
+ #
355
+ # * {Types::DescribeWorkspaceDirectoriesResult#directories #Directories} => Array&lt;Types::WorkspaceDirectory&gt;
356
+ # * {Types::DescribeWorkspaceDirectoriesResult#next_token #NextToken} => String
357
+ #
358
+ # @example Request syntax with placeholder values
359
+ # resp = client.describe_workspace_directories({
360
+ # directory_ids: ["DirectoryId"],
361
+ # next_token: "PaginationToken",
362
+ # })
363
+ #
364
+ # @example Response structure
365
+ # resp.directories #=> Array
366
+ # resp.directories[0].directory_id #=> String
367
+ # resp.directories[0].alias #=> String
368
+ # resp.directories[0].directory_name #=> String
369
+ # resp.directories[0].registration_code #=> String
370
+ # resp.directories[0].subnet_ids #=> Array
371
+ # resp.directories[0].subnet_ids[0] #=> String
372
+ # resp.directories[0].dns_ip_addresses #=> Array
373
+ # resp.directories[0].dns_ip_addresses[0] #=> String
374
+ # resp.directories[0].customer_user_name #=> String
375
+ # resp.directories[0].iam_role_id #=> String
376
+ # resp.directories[0].directory_type #=> String, one of "SIMPLE_AD", "AD_CONNECTOR"
377
+ # resp.directories[0].workspace_security_group_id #=> String
378
+ # resp.directories[0].state #=> String, one of "REGISTERING", "REGISTERED", "DEREGISTERING", "DEREGISTERED", "ERROR"
379
+ # resp.directories[0].workspace_creation_properties.enable_work_docs #=> Boolean
380
+ # resp.directories[0].workspace_creation_properties.enable_internet_access #=> Boolean
381
+ # resp.directories[0].workspace_creation_properties.default_ou #=> String
382
+ # resp.directories[0].workspace_creation_properties.custom_security_group_id #=> String
383
+ # resp.directories[0].workspace_creation_properties.user_enabled_as_local_administrator #=> Boolean
384
+ # resp.next_token #=> String
385
+ # @overload describe_workspace_directories(params = {})
386
+ # @param [Hash] params ({})
387
+ def describe_workspace_directories(params = {}, options = {})
388
+ req = build_request(:describe_workspace_directories, params)
389
+ req.send_request(options)
390
+ end
391
+
392
+ # Obtains information about the specified WorkSpaces.
393
+ #
394
+ # Only one of the filter parameters, such as `BundleId`, `DirectoryId`,
395
+ # or `WorkspaceIds`, can be specified at a time.
396
+ #
397
+ # This operation supports pagination with the use of the `NextToken`
398
+ # request and response parameters. If more results are available, the
399
+ # `NextToken` response member contains a token that you pass in the next
400
+ # call to this operation to retrieve the next set of items.
401
+ # @option params [Array<String>] :workspace_ids
402
+ # An array of strings that contain the identifiers of the WorkSpaces for
403
+ # which to retrieve information. This parameter cannot be combined with
404
+ # any other filter parameter.
405
+ #
406
+ # Because the CreateWorkspaces operation is asynchronous, the identifier
407
+ # it returns is not immediately available. If you immediately call
408
+ # DescribeWorkspaces with this identifier, no information is returned.
409
+ # @option params [String] :directory_id
410
+ # Specifies the directory identifier to which to limit the WorkSpaces.
411
+ # Optionally, you can specify a specific directory user with the
412
+ # `UserName` parameter. This parameter cannot be combined with any other
413
+ # filter parameter.
414
+ # @option params [String] :user_name
415
+ # Used with the `DirectoryId` parameter to specify the directory user
416
+ # for whom to obtain the WorkSpace.
417
+ # @option params [String] :bundle_id
418
+ # The identifier of a bundle to obtain the WorkSpaces for. All
419
+ # WorkSpaces that are created from this bundle will be retrieved. This
420
+ # parameter cannot be combined with any other filter parameter.
421
+ # @option params [Integer] :limit
422
+ # The maximum number of items to return.
423
+ # @option params [String] :next_token
424
+ # The `NextToken` value from a previous call to this operation. Pass
425
+ # null if this is the first call.
426
+ # @return [Types::DescribeWorkspacesResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
427
+ #
428
+ # * {Types::DescribeWorkspacesResult#workspaces #Workspaces} => Array&lt;Types::Workspace&gt;
429
+ # * {Types::DescribeWorkspacesResult#next_token #NextToken} => String
430
+ #
431
+ # @example Request syntax with placeholder values
432
+ # resp = client.describe_workspaces({
433
+ # workspace_ids: ["WorkspaceId"],
434
+ # directory_id: "DirectoryId",
435
+ # user_name: "UserName",
436
+ # bundle_id: "BundleId",
437
+ # limit: 1,
438
+ # next_token: "PaginationToken",
439
+ # })
440
+ #
441
+ # @example Response structure
442
+ # resp.workspaces #=> Array
443
+ # resp.workspaces[0].workspace_id #=> String
444
+ # resp.workspaces[0].directory_id #=> String
445
+ # resp.workspaces[0].user_name #=> String
446
+ # resp.workspaces[0].ip_address #=> String
447
+ # resp.workspaces[0].state #=> String, one of "PENDING", "AVAILABLE", "IMPAIRED", "UNHEALTHY", "REBOOTING", "STARTING", "REBUILDING", "MAINTENANCE", "TERMINATING", "TERMINATED", "SUSPENDED", "STOPPING", "STOPPED", "ERROR"
448
+ # resp.workspaces[0].bundle_id #=> String
449
+ # resp.workspaces[0].subnet_id #=> String
450
+ # resp.workspaces[0].error_message #=> String
451
+ # resp.workspaces[0].error_code #=> String
452
+ # resp.workspaces[0].computer_name #=> String
453
+ # resp.workspaces[0].volume_encryption_key #=> String
454
+ # resp.workspaces[0].user_volume_encryption_enabled #=> Boolean
455
+ # resp.workspaces[0].root_volume_encryption_enabled #=> Boolean
456
+ # resp.workspaces[0].workspace_properties.running_mode #=> String, one of "AUTO_STOP", "ALWAYS_ON"
457
+ # resp.workspaces[0].workspace_properties.running_mode_auto_stop_timeout_in_minutes #=> Integer
458
+ # resp.next_token #=> String
459
+ # @overload describe_workspaces(params = {})
460
+ # @param [Hash] params ({})
461
+ def describe_workspaces(params = {}, options = {})
462
+ req = build_request(:describe_workspaces, params)
463
+ req.send_request(options)
464
+ end
465
+
466
+ # Describes the connection status of a specified WorkSpace.
467
+ # @option params [Array<String>] :workspace_ids
468
+ # An array of strings that contain the identifiers of the WorkSpaces.
469
+ # @option params [String] :next_token
470
+ # The next token of the request.
471
+ # @return [Types::DescribeWorkspacesConnectionStatusResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
472
+ #
473
+ # * {Types::DescribeWorkspacesConnectionStatusResult#workspaces_connection_status #WorkspacesConnectionStatus} => Array&lt;Types::WorkspaceConnectionStatus&gt;
474
+ # * {Types::DescribeWorkspacesConnectionStatusResult#next_token #NextToken} => String
475
+ #
476
+ # @example Request syntax with placeholder values
477
+ # resp = client.describe_workspaces_connection_status({
478
+ # workspace_ids: ["WorkspaceId"],
479
+ # next_token: "PaginationToken",
480
+ # })
481
+ #
482
+ # @example Response structure
483
+ # resp.workspaces_connection_status #=> Array
484
+ # resp.workspaces_connection_status[0].workspace_id #=> String
485
+ # resp.workspaces_connection_status[0].connection_state #=> String, one of "CONNECTED", "DISCONNECTED", "UNKNOWN"
486
+ # resp.workspaces_connection_status[0].connection_state_check_timestamp #=> Time
487
+ # resp.workspaces_connection_status[0].last_known_user_connection_timestamp #=> Time
488
+ # resp.next_token #=> String
489
+ # @overload describe_workspaces_connection_status(params = {})
490
+ # @param [Hash] params ({})
491
+ def describe_workspaces_connection_status(params = {}, options = {})
492
+ req = build_request(:describe_workspaces_connection_status, params)
493
+ req.send_request(options)
494
+ end
495
+
496
+ # Modifies the WorkSpace properties, including the RunningMode and
497
+ # AutoStop time.
498
+ # @option params [required, String] :workspace_id
499
+ # The ID of the WorkSpace.
500
+ # @option params [required, Types::WorkspaceProperties] :workspace_properties
501
+ # The WorkSpace properties of the request.
502
+ # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
503
+ #
504
+ # @example Request syntax with placeholder values
505
+ # resp = client.modify_workspace_properties({
506
+ # workspace_id: "WorkspaceId", # required
507
+ # workspace_properties: { # required
508
+ # running_mode: "AUTO_STOP", # accepts AUTO_STOP, ALWAYS_ON
509
+ # running_mode_auto_stop_timeout_in_minutes: 1,
510
+ # },
511
+ # })
512
+ # @overload modify_workspace_properties(params = {})
513
+ # @param [Hash] params ({})
514
+ def modify_workspace_properties(params = {}, options = {})
515
+ req = build_request(:modify_workspace_properties, params)
516
+ req.send_request(options)
517
+ end
518
+
519
+ # Reboots the specified WorkSpaces.
520
+ #
521
+ # To be able to reboot a WorkSpace, the WorkSpace must have a **State**
522
+ # of `AVAILABLE`, `IMPAIRED`, or `INOPERABLE`.
523
+ #
524
+ # <note markdown="1"> This operation is asynchronous and returns before the WorkSpaces have
525
+ # rebooted.
526
+ #
527
+ # </note>
528
+ # @option params [required, Array<Types::RebootRequest>] :reboot_workspace_requests
529
+ # An array of structures that specify the WorkSpaces to reboot.
530
+ # @return [Types::RebootWorkspacesResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
531
+ #
532
+ # * {Types::RebootWorkspacesResult#failed_requests #FailedRequests} => Array&lt;Types::FailedWorkspaceChangeRequest&gt;
533
+ #
534
+ # @example Request syntax with placeholder values
535
+ # resp = client.reboot_workspaces({
536
+ # reboot_workspace_requests: [ # required
537
+ # {
538
+ # workspace_id: "WorkspaceId", # required
539
+ # },
540
+ # ],
541
+ # })
542
+ #
543
+ # @example Response structure
544
+ # resp.failed_requests #=> Array
545
+ # resp.failed_requests[0].workspace_id #=> String
546
+ # resp.failed_requests[0].error_code #=> String
547
+ # resp.failed_requests[0].error_message #=> String
548
+ # @overload reboot_workspaces(params = {})
549
+ # @param [Hash] params ({})
550
+ def reboot_workspaces(params = {}, options = {})
551
+ req = build_request(:reboot_workspaces, params)
552
+ req.send_request(options)
553
+ end
554
+
555
+ # Rebuilds the specified WorkSpaces.
556
+ #
557
+ # Rebuilding a WorkSpace is a potentially destructive action that can
558
+ # result in the loss of data. Rebuilding a WorkSpace causes the
559
+ # following to occur:
560
+ #
561
+ # * The system is restored to the image of the bundle that the WorkSpace
562
+ # is created from. Any applications that have been installed, or
563
+ # system settings that have been made since the WorkSpace was created
564
+ # will be lost.
565
+ #
566
+ # * The data drive (D drive) is re-created from the last automatic
567
+ # snapshot taken of the data drive. The current contents of the data
568
+ # drive are overwritten. Automatic snapshots of the data drive are
569
+ # taken every 12 hours, so the snapshot can be as much as 12 hours
570
+ # old.
571
+ #
572
+ # To be able to rebuild a WorkSpace, the WorkSpace must have a **State**
573
+ # of `AVAILABLE` or `ERROR`.
574
+ #
575
+ # <note markdown="1"> This operation is asynchronous and returns before the WorkSpaces have
576
+ # been completely rebuilt.
577
+ #
578
+ # </note>
579
+ # @option params [required, Array<Types::RebuildRequest>] :rebuild_workspace_requests
580
+ # An array of structures that specify the WorkSpaces to rebuild.
581
+ # @return [Types::RebuildWorkspacesResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
582
+ #
583
+ # * {Types::RebuildWorkspacesResult#failed_requests #FailedRequests} => Array&lt;Types::FailedWorkspaceChangeRequest&gt;
584
+ #
585
+ # @example Request syntax with placeholder values
586
+ # resp = client.rebuild_workspaces({
587
+ # rebuild_workspace_requests: [ # required
588
+ # {
589
+ # workspace_id: "WorkspaceId", # required
590
+ # },
591
+ # ],
592
+ # })
593
+ #
594
+ # @example Response structure
595
+ # resp.failed_requests #=> Array
596
+ # resp.failed_requests[0].workspace_id #=> String
597
+ # resp.failed_requests[0].error_code #=> String
598
+ # resp.failed_requests[0].error_message #=> String
599
+ # @overload rebuild_workspaces(params = {})
600
+ # @param [Hash] params ({})
601
+ def rebuild_workspaces(params = {}, options = {})
602
+ req = build_request(:rebuild_workspaces, params)
603
+ req.send_request(options)
604
+ end
605
+
606
+ # Starts the specified WorkSpaces. The API only works with WorkSpaces
607
+ # that have RunningMode configured as AutoStop and the State set to
608
+ # “STOPPED.”
609
+ # @option params [required, Array<Types::StartRequest>] :start_workspace_requests
610
+ # The requests.
611
+ # @return [Types::StartWorkspacesResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
612
+ #
613
+ # * {Types::StartWorkspacesResult#failed_requests #FailedRequests} => Array&lt;Types::FailedWorkspaceChangeRequest&gt;
614
+ #
615
+ # @example Request syntax with placeholder values
616
+ # resp = client.start_workspaces({
617
+ # start_workspace_requests: [ # required
618
+ # {
619
+ # workspace_id: "WorkspaceId",
620
+ # },
621
+ # ],
622
+ # })
623
+ #
624
+ # @example Response structure
625
+ # resp.failed_requests #=> Array
626
+ # resp.failed_requests[0].workspace_id #=> String
627
+ # resp.failed_requests[0].error_code #=> String
628
+ # resp.failed_requests[0].error_message #=> String
629
+ # @overload start_workspaces(params = {})
630
+ # @param [Hash] params ({})
631
+ def start_workspaces(params = {}, options = {})
632
+ req = build_request(:start_workspaces, params)
633
+ req.send_request(options)
634
+ end
635
+
636
+ # Stops the specified WorkSpaces. The API only works with WorkSpaces
637
+ # that have RunningMode configured as AutoStop and the State set to
638
+ # AVAILABLE, IMPAIRED, UNHEALTHY, or ERROR.
639
+ # @option params [required, Array<Types::StopRequest>] :stop_workspace_requests
640
+ # The requests.
641
+ # @return [Types::StopWorkspacesResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
642
+ #
643
+ # * {Types::StopWorkspacesResult#failed_requests #FailedRequests} => Array&lt;Types::FailedWorkspaceChangeRequest&gt;
644
+ #
645
+ # @example Request syntax with placeholder values
646
+ # resp = client.stop_workspaces({
647
+ # stop_workspace_requests: [ # required
648
+ # {
649
+ # workspace_id: "WorkspaceId",
650
+ # },
651
+ # ],
652
+ # })
653
+ #
654
+ # @example Response structure
655
+ # resp.failed_requests #=> Array
656
+ # resp.failed_requests[0].workspace_id #=> String
657
+ # resp.failed_requests[0].error_code #=> String
658
+ # resp.failed_requests[0].error_message #=> String
659
+ # @overload stop_workspaces(params = {})
660
+ # @param [Hash] params ({})
661
+ def stop_workspaces(params = {}, options = {})
662
+ req = build_request(:stop_workspaces, params)
663
+ req.send_request(options)
664
+ end
665
+
666
+ # Terminates the specified WorkSpaces.
667
+ #
668
+ # Terminating a WorkSpace is a permanent action and cannot be undone.
669
+ # The user's data is not maintained and will be destroyed. If you need
670
+ # to archive any user data, contact Amazon Web Services before
671
+ # terminating the WorkSpace.
672
+ #
673
+ # You can terminate a WorkSpace that is in any state except `SUSPENDED`.
674
+ #
675
+ # <note markdown="1"> This operation is asynchronous and returns before the WorkSpaces have
676
+ # been completely terminated.
677
+ #
678
+ # </note>
679
+ # @option params [required, Array<Types::TerminateRequest>] :terminate_workspace_requests
680
+ # An array of structures that specify the WorkSpaces to terminate.
681
+ # @return [Types::TerminateWorkspacesResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
682
+ #
683
+ # * {Types::TerminateWorkspacesResult#failed_requests #FailedRequests} => Array&lt;Types::FailedWorkspaceChangeRequest&gt;
684
+ #
685
+ # @example Request syntax with placeholder values
686
+ # resp = client.terminate_workspaces({
687
+ # terminate_workspace_requests: [ # required
688
+ # {
689
+ # workspace_id: "WorkspaceId", # required
690
+ # },
691
+ # ],
692
+ # })
693
+ #
694
+ # @example Response structure
695
+ # resp.failed_requests #=> Array
696
+ # resp.failed_requests[0].workspace_id #=> String
697
+ # resp.failed_requests[0].error_code #=> String
698
+ # resp.failed_requests[0].error_message #=> String
699
+ # @overload terminate_workspaces(params = {})
700
+ # @param [Hash] params ({})
701
+ def terminate_workspaces(params = {}, options = {})
702
+ req = build_request(:terminate_workspaces, params)
703
+ req.send_request(options)
704
+ end
705
+
706
+ # @!endgroup
707
+
708
+ # @param params ({})
709
+ # @api private
710
+ def build_request(operation_name, params = {})
711
+ handlers = @handlers.for(operation_name)
712
+ context = Seahorse::Client::RequestContext.new(
713
+ operation_name: operation_name,
714
+ operation: config.api.operation(operation_name),
715
+ client: self,
716
+ params: params,
717
+ config: config)
718
+ context[:gem_name] = 'aws-sdk-workspaces'
719
+ context[:gem_version] = '1.0.0.rc1'
720
+ Seahorse::Client::Request.new(handlers, context)
721
+ end
722
+
723
+ # @api private
724
+ # @deprecated
725
+ def waiter_names
726
+ []
727
+ end
728
+
729
+ class << self
730
+
731
+ # @api private
732
+ attr_reader :identifier
733
+
734
+ # @api private
735
+ def errors_module
736
+ Errors
737
+ end
738
+
739
+ end
740
+ end
741
+ end
742
+ end