Menu
Amazon WorkSpaces Service
API Reference (API Version 2015-04-08)

CreateWorkspaces

Creates one or more WorkSpaces.

Note

This operation is asynchronous and returns before the WorkSpaces are created.

Request Syntax

Copy
{ "Workspaces": [ { "BundleId": "string", "DirectoryId": "string", "RootVolumeEncryptionEnabled": boolean, "Tags": [ { "Key": "string", "Value": "string" } ], "UserName": "string", "UserVolumeEncryptionEnabled": boolean, "VolumeEncryptionKey": "string", "WorkspaceProperties": { "RunningMode": "string", "RunningModeAutoStopTimeoutInMinutes": number } } ] }

Request Parameters

The request accepts the following data in JSON format.

Workspaces

An array of structures that specify the WorkSpaces to create.

Type: Array of WorkspaceRequest objects

Array Members: Minimum number of 1 item. Maximum number of 25 items.

Required: Yes

Response Syntax

Copy
{ "FailedRequests": [ { "ErrorCode": "string", "ErrorMessage": "string", "WorkspaceRequest": { "BundleId": "string", "DirectoryId": "string", "RootVolumeEncryptionEnabled": boolean, "Tags": [ { "Key": "string", "Value": "string" } ], "UserName": "string", "UserVolumeEncryptionEnabled": boolean, "VolumeEncryptionKey": "string", "WorkspaceProperties": { "RunningMode": "string", "RunningModeAutoStopTimeoutInMinutes": number } } } ], "PendingRequests": [ { "BundleId": "string", "ComputerName": "string", "DirectoryId": "string", "ErrorCode": "string", "ErrorMessage": "string", "IpAddress": "string", "RootVolumeEncryptionEnabled": boolean, "State": "string", "SubnetId": "string", "UserName": "string", "UserVolumeEncryptionEnabled": boolean, "VolumeEncryptionKey": "string", "WorkspaceId": "string", "WorkspaceProperties": { "RunningMode": "string", "RunningModeAutoStopTimeoutInMinutes": number } } ] }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

FailedRequests

An array of structures that represent the WorkSpaces that could not be created.

Type: Array of FailedCreateWorkspaceRequest objects

PendingRequests

An array of structures that represent the WorkSpaces that were created.

Because this operation is asynchronous, the identifier in WorkspaceId is not immediately available. If you immediately call DescribeWorkspaces with this identifier, no information will be returned.

Type: Array of Workspace objects

Errors

For information about the errors that are common to all actions, see Common Errors.

InvalidParameterValuesException

One or more parameter values are not valid.

HTTP Status Code: 400

ResourceLimitExceededException

Your resource limits have been exceeded.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: