aws-sdk-braket 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,303 @@
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/master/CONTRIBUTING.md
7
+ #
8
+ # WARNING ABOUT GENERATED CODE
9
+
10
+ module Aws::Braket
11
+ # @api private
12
+ module ClientApi
13
+
14
+ include Seahorse::Model
15
+
16
+ AccessDeniedException = Shapes::StructureShape.new(name: 'AccessDeniedException')
17
+ CancelQuantumTaskRequest = Shapes::StructureShape.new(name: 'CancelQuantumTaskRequest')
18
+ CancelQuantumTaskResponse = Shapes::StructureShape.new(name: 'CancelQuantumTaskResponse')
19
+ CancellationStatus = Shapes::StringShape.new(name: 'CancellationStatus')
20
+ ConflictException = Shapes::StructureShape.new(name: 'ConflictException')
21
+ CreateQuantumTaskRequest = Shapes::StructureShape.new(name: 'CreateQuantumTaskRequest')
22
+ CreateQuantumTaskRequestdeviceParametersJsonValue = Shapes::StringShape.new(name: 'CreateQuantumTaskRequestdeviceParametersJsonValue')
23
+ CreateQuantumTaskRequestoutputS3BucketString = Shapes::StringShape.new(name: 'CreateQuantumTaskRequestoutputS3BucketString')
24
+ CreateQuantumTaskRequestoutputS3KeyPrefixString = Shapes::StringShape.new(name: 'CreateQuantumTaskRequestoutputS3KeyPrefixString')
25
+ CreateQuantumTaskRequestshotsLong = Shapes::IntegerShape.new(name: 'CreateQuantumTaskRequestshotsLong')
26
+ CreateQuantumTaskResponse = Shapes::StructureShape.new(name: 'CreateQuantumTaskResponse')
27
+ DeviceArn = Shapes::StringShape.new(name: 'DeviceArn')
28
+ DeviceOfflineException = Shapes::StructureShape.new(name: 'DeviceOfflineException')
29
+ DeviceStatus = Shapes::StringShape.new(name: 'DeviceStatus')
30
+ DeviceSummary = Shapes::StructureShape.new(name: 'DeviceSummary')
31
+ DeviceSummaryList = Shapes::ListShape.new(name: 'DeviceSummaryList')
32
+ DeviceType = Shapes::StringShape.new(name: 'DeviceType')
33
+ GetDeviceRequest = Shapes::StructureShape.new(name: 'GetDeviceRequest')
34
+ GetDeviceResponse = Shapes::StructureShape.new(name: 'GetDeviceResponse')
35
+ GetQuantumTaskRequest = Shapes::StructureShape.new(name: 'GetQuantumTaskRequest')
36
+ GetQuantumTaskResponse = Shapes::StructureShape.new(name: 'GetQuantumTaskResponse')
37
+ InternalServiceException = Shapes::StructureShape.new(name: 'InternalServiceException')
38
+ JsonValue = Shapes::StringShape.new(name: 'JsonValue')
39
+ Long = Shapes::IntegerShape.new(name: 'Long')
40
+ QuantumTaskArn = Shapes::StringShape.new(name: 'QuantumTaskArn')
41
+ QuantumTaskStatus = Shapes::StringShape.new(name: 'QuantumTaskStatus')
42
+ QuantumTaskSummary = Shapes::StructureShape.new(name: 'QuantumTaskSummary')
43
+ QuantumTaskSummaryList = Shapes::ListShape.new(name: 'QuantumTaskSummaryList')
44
+ ResourceNotFoundException = Shapes::StructureShape.new(name: 'ResourceNotFoundException')
45
+ SearchDevicesFilter = Shapes::StructureShape.new(name: 'SearchDevicesFilter')
46
+ SearchDevicesFilternameString = Shapes::StringShape.new(name: 'SearchDevicesFilternameString')
47
+ SearchDevicesFiltervaluesString256List = Shapes::ListShape.new(name: 'SearchDevicesFiltervaluesString256List')
48
+ SearchDevicesRequest = Shapes::StructureShape.new(name: 'SearchDevicesRequest')
49
+ SearchDevicesRequestfiltersSearchDevicesFilterList = Shapes::ListShape.new(name: 'SearchDevicesRequestfiltersSearchDevicesFilterList')
50
+ SearchDevicesRequestmaxResultsInteger = Shapes::IntegerShape.new(name: 'SearchDevicesRequestmaxResultsInteger')
51
+ SearchDevicesResponse = Shapes::StructureShape.new(name: 'SearchDevicesResponse')
52
+ SearchQuantumTasksFilter = Shapes::StructureShape.new(name: 'SearchQuantumTasksFilter')
53
+ SearchQuantumTasksFilterOperator = Shapes::StringShape.new(name: 'SearchQuantumTasksFilterOperator')
54
+ SearchQuantumTasksFiltervaluesString256List = Shapes::ListShape.new(name: 'SearchQuantumTasksFiltervaluesString256List')
55
+ SearchQuantumTasksRequest = Shapes::StructureShape.new(name: 'SearchQuantumTasksRequest')
56
+ SearchQuantumTasksRequestfiltersSearchQuantumTasksFilterList = Shapes::ListShape.new(name: 'SearchQuantumTasksRequestfiltersSearchQuantumTasksFilterList')
57
+ SearchQuantumTasksRequestmaxResultsInteger = Shapes::IntegerShape.new(name: 'SearchQuantumTasksRequestmaxResultsInteger')
58
+ SearchQuantumTasksResponse = Shapes::StructureShape.new(name: 'SearchQuantumTasksResponse')
59
+ ServiceQuotaExceededException = Shapes::StructureShape.new(name: 'ServiceQuotaExceededException')
60
+ String = Shapes::StringShape.new(name: 'String')
61
+ String256 = Shapes::StringShape.new(name: 'String256')
62
+ String64 = Shapes::StringShape.new(name: 'String64')
63
+ SyntheticTimestamp_date_time = Shapes::TimestampShape.new(name: 'SyntheticTimestamp_date_time', timestampFormat: "iso8601")
64
+ ThrottlingException = Shapes::StructureShape.new(name: 'ThrottlingException')
65
+ ValidationException = Shapes::StructureShape.new(name: 'ValidationException')
66
+
67
+ AccessDeniedException.add_member(:message, Shapes::ShapeRef.new(shape: String, location_name: "message"))
68
+ AccessDeniedException.struct_class = Types::AccessDeniedException
69
+
70
+ CancelQuantumTaskRequest.add_member(:client_token, Shapes::ShapeRef.new(shape: String64, required: true, location_name: "clientToken", metadata: {"idempotencyToken"=>true}))
71
+ CancelQuantumTaskRequest.add_member(:quantum_task_arn, Shapes::ShapeRef.new(shape: QuantumTaskArn, required: true, location: "uri", location_name: "quantumTaskArn"))
72
+ CancelQuantumTaskRequest.struct_class = Types::CancelQuantumTaskRequest
73
+
74
+ CancelQuantumTaskResponse.add_member(:cancellation_status, Shapes::ShapeRef.new(shape: CancellationStatus, required: true, location_name: "cancellationStatus"))
75
+ CancelQuantumTaskResponse.add_member(:quantum_task_arn, Shapes::ShapeRef.new(shape: QuantumTaskArn, required: true, location_name: "quantumTaskArn"))
76
+ CancelQuantumTaskResponse.struct_class = Types::CancelQuantumTaskResponse
77
+
78
+ ConflictException.add_member(:message, Shapes::ShapeRef.new(shape: String, location_name: "message"))
79
+ ConflictException.struct_class = Types::ConflictException
80
+
81
+ CreateQuantumTaskRequest.add_member(:action, Shapes::ShapeRef.new(shape: JsonValue, required: true, location_name: "action", metadata: {"jsonvalue"=>true}))
82
+ CreateQuantumTaskRequest.add_member(:client_token, Shapes::ShapeRef.new(shape: String64, required: true, location_name: "clientToken", metadata: {"idempotencyToken"=>true}))
83
+ CreateQuantumTaskRequest.add_member(:device_arn, Shapes::ShapeRef.new(shape: DeviceArn, required: true, location_name: "deviceArn"))
84
+ CreateQuantumTaskRequest.add_member(:device_parameters, Shapes::ShapeRef.new(shape: CreateQuantumTaskRequestdeviceParametersJsonValue, location_name: "deviceParameters", metadata: {"jsonvalue"=>true}))
85
+ CreateQuantumTaskRequest.add_member(:output_s3_bucket, Shapes::ShapeRef.new(shape: CreateQuantumTaskRequestoutputS3BucketString, required: true, location_name: "outputS3Bucket"))
86
+ CreateQuantumTaskRequest.add_member(:output_s3_key_prefix, Shapes::ShapeRef.new(shape: CreateQuantumTaskRequestoutputS3KeyPrefixString, required: true, location_name: "outputS3KeyPrefix"))
87
+ CreateQuantumTaskRequest.add_member(:shots, Shapes::ShapeRef.new(shape: CreateQuantumTaskRequestshotsLong, required: true, location_name: "shots"))
88
+ CreateQuantumTaskRequest.struct_class = Types::CreateQuantumTaskRequest
89
+
90
+ CreateQuantumTaskResponse.add_member(:quantum_task_arn, Shapes::ShapeRef.new(shape: QuantumTaskArn, required: true, location_name: "quantumTaskArn"))
91
+ CreateQuantumTaskResponse.struct_class = Types::CreateQuantumTaskResponse
92
+
93
+ DeviceOfflineException.add_member(:message, Shapes::ShapeRef.new(shape: String, location_name: "message"))
94
+ DeviceOfflineException.struct_class = Types::DeviceOfflineException
95
+
96
+ DeviceSummary.add_member(:device_arn, Shapes::ShapeRef.new(shape: DeviceArn, required: true, location_name: "deviceArn"))
97
+ DeviceSummary.add_member(:device_name, Shapes::ShapeRef.new(shape: String, required: true, location_name: "deviceName"))
98
+ DeviceSummary.add_member(:device_status, Shapes::ShapeRef.new(shape: DeviceStatus, required: true, location_name: "deviceStatus"))
99
+ DeviceSummary.add_member(:device_type, Shapes::ShapeRef.new(shape: DeviceType, required: true, location_name: "deviceType"))
100
+ DeviceSummary.add_member(:provider_name, Shapes::ShapeRef.new(shape: String, required: true, location_name: "providerName"))
101
+ DeviceSummary.struct_class = Types::DeviceSummary
102
+
103
+ DeviceSummaryList.member = Shapes::ShapeRef.new(shape: DeviceSummary)
104
+
105
+ GetDeviceRequest.add_member(:device_arn, Shapes::ShapeRef.new(shape: DeviceArn, required: true, location: "uri", location_name: "deviceArn"))
106
+ GetDeviceRequest.struct_class = Types::GetDeviceRequest
107
+
108
+ GetDeviceResponse.add_member(:device_arn, Shapes::ShapeRef.new(shape: DeviceArn, required: true, location_name: "deviceArn"))
109
+ GetDeviceResponse.add_member(:device_capabilities, Shapes::ShapeRef.new(shape: JsonValue, required: true, location_name: "deviceCapabilities", metadata: {"jsonvalue"=>true}))
110
+ GetDeviceResponse.add_member(:device_name, Shapes::ShapeRef.new(shape: String, required: true, location_name: "deviceName"))
111
+ GetDeviceResponse.add_member(:device_status, Shapes::ShapeRef.new(shape: DeviceStatus, required: true, location_name: "deviceStatus"))
112
+ GetDeviceResponse.add_member(:device_type, Shapes::ShapeRef.new(shape: DeviceType, required: true, location_name: "deviceType"))
113
+ GetDeviceResponse.add_member(:provider_name, Shapes::ShapeRef.new(shape: String, required: true, location_name: "providerName"))
114
+ GetDeviceResponse.struct_class = Types::GetDeviceResponse
115
+
116
+ GetQuantumTaskRequest.add_member(:quantum_task_arn, Shapes::ShapeRef.new(shape: QuantumTaskArn, required: true, location: "uri", location_name: "quantumTaskArn"))
117
+ GetQuantumTaskRequest.struct_class = Types::GetQuantumTaskRequest
118
+
119
+ GetQuantumTaskResponse.add_member(:created_at, Shapes::ShapeRef.new(shape: SyntheticTimestamp_date_time, required: true, location_name: "createdAt"))
120
+ GetQuantumTaskResponse.add_member(:device_arn, Shapes::ShapeRef.new(shape: DeviceArn, required: true, location_name: "deviceArn"))
121
+ GetQuantumTaskResponse.add_member(:device_parameters, Shapes::ShapeRef.new(shape: JsonValue, required: true, location_name: "deviceParameters", metadata: {"jsonvalue"=>true}))
122
+ GetQuantumTaskResponse.add_member(:ended_at, Shapes::ShapeRef.new(shape: SyntheticTimestamp_date_time, location_name: "endedAt"))
123
+ GetQuantumTaskResponse.add_member(:failure_reason, Shapes::ShapeRef.new(shape: String, location_name: "failureReason"))
124
+ GetQuantumTaskResponse.add_member(:output_s3_bucket, Shapes::ShapeRef.new(shape: String, required: true, location_name: "outputS3Bucket"))
125
+ GetQuantumTaskResponse.add_member(:output_s3_directory, Shapes::ShapeRef.new(shape: String, required: true, location_name: "outputS3Directory"))
126
+ GetQuantumTaskResponse.add_member(:quantum_task_arn, Shapes::ShapeRef.new(shape: QuantumTaskArn, required: true, location_name: "quantumTaskArn"))
127
+ GetQuantumTaskResponse.add_member(:shots, Shapes::ShapeRef.new(shape: Long, required: true, location_name: "shots"))
128
+ GetQuantumTaskResponse.add_member(:status, Shapes::ShapeRef.new(shape: QuantumTaskStatus, required: true, location_name: "status"))
129
+ GetQuantumTaskResponse.struct_class = Types::GetQuantumTaskResponse
130
+
131
+ InternalServiceException.add_member(:message, Shapes::ShapeRef.new(shape: String, location_name: "message"))
132
+ InternalServiceException.struct_class = Types::InternalServiceException
133
+
134
+ QuantumTaskSummary.add_member(:created_at, Shapes::ShapeRef.new(shape: SyntheticTimestamp_date_time, required: true, location_name: "createdAt"))
135
+ QuantumTaskSummary.add_member(:device_arn, Shapes::ShapeRef.new(shape: DeviceArn, required: true, location_name: "deviceArn"))
136
+ QuantumTaskSummary.add_member(:ended_at, Shapes::ShapeRef.new(shape: SyntheticTimestamp_date_time, location_name: "endedAt"))
137
+ QuantumTaskSummary.add_member(:output_s3_bucket, Shapes::ShapeRef.new(shape: String, required: true, location_name: "outputS3Bucket"))
138
+ QuantumTaskSummary.add_member(:output_s3_directory, Shapes::ShapeRef.new(shape: String, required: true, location_name: "outputS3Directory"))
139
+ QuantumTaskSummary.add_member(:quantum_task_arn, Shapes::ShapeRef.new(shape: QuantumTaskArn, required: true, location_name: "quantumTaskArn"))
140
+ QuantumTaskSummary.add_member(:shots, Shapes::ShapeRef.new(shape: Long, required: true, location_name: "shots"))
141
+ QuantumTaskSummary.add_member(:status, Shapes::ShapeRef.new(shape: QuantumTaskStatus, required: true, location_name: "status"))
142
+ QuantumTaskSummary.struct_class = Types::QuantumTaskSummary
143
+
144
+ QuantumTaskSummaryList.member = Shapes::ShapeRef.new(shape: QuantumTaskSummary)
145
+
146
+ ResourceNotFoundException.add_member(:message, Shapes::ShapeRef.new(shape: String, location_name: "message"))
147
+ ResourceNotFoundException.struct_class = Types::ResourceNotFoundException
148
+
149
+ SearchDevicesFilter.add_member(:name, Shapes::ShapeRef.new(shape: SearchDevicesFilternameString, required: true, location_name: "name"))
150
+ SearchDevicesFilter.add_member(:values, Shapes::ShapeRef.new(shape: SearchDevicesFiltervaluesString256List, required: true, location_name: "values"))
151
+ SearchDevicesFilter.struct_class = Types::SearchDevicesFilter
152
+
153
+ SearchDevicesFiltervaluesString256List.member = Shapes::ShapeRef.new(shape: String256)
154
+
155
+ SearchDevicesRequest.add_member(:filters, Shapes::ShapeRef.new(shape: SearchDevicesRequestfiltersSearchDevicesFilterList, required: true, location_name: "filters"))
156
+ SearchDevicesRequest.add_member(:max_results, Shapes::ShapeRef.new(shape: SearchDevicesRequestmaxResultsInteger, location_name: "maxResults"))
157
+ SearchDevicesRequest.add_member(:next_token, Shapes::ShapeRef.new(shape: String, location_name: "nextToken"))
158
+ SearchDevicesRequest.struct_class = Types::SearchDevicesRequest
159
+
160
+ SearchDevicesRequestfiltersSearchDevicesFilterList.member = Shapes::ShapeRef.new(shape: SearchDevicesFilter)
161
+
162
+ SearchDevicesResponse.add_member(:devices, Shapes::ShapeRef.new(shape: DeviceSummaryList, required: true, location_name: "devices"))
163
+ SearchDevicesResponse.add_member(:next_token, Shapes::ShapeRef.new(shape: String, location_name: "nextToken"))
164
+ SearchDevicesResponse.struct_class = Types::SearchDevicesResponse
165
+
166
+ SearchQuantumTasksFilter.add_member(:name, Shapes::ShapeRef.new(shape: String64, required: true, location_name: "name"))
167
+ SearchQuantumTasksFilter.add_member(:operator, Shapes::ShapeRef.new(shape: SearchQuantumTasksFilterOperator, required: true, location_name: "operator"))
168
+ SearchQuantumTasksFilter.add_member(:values, Shapes::ShapeRef.new(shape: SearchQuantumTasksFiltervaluesString256List, required: true, location_name: "values"))
169
+ SearchQuantumTasksFilter.struct_class = Types::SearchQuantumTasksFilter
170
+
171
+ SearchQuantumTasksFiltervaluesString256List.member = Shapes::ShapeRef.new(shape: String256)
172
+
173
+ SearchQuantumTasksRequest.add_member(:filters, Shapes::ShapeRef.new(shape: SearchQuantumTasksRequestfiltersSearchQuantumTasksFilterList, required: true, location_name: "filters"))
174
+ SearchQuantumTasksRequest.add_member(:max_results, Shapes::ShapeRef.new(shape: SearchQuantumTasksRequestmaxResultsInteger, location_name: "maxResults"))
175
+ SearchQuantumTasksRequest.add_member(:next_token, Shapes::ShapeRef.new(shape: String, location_name: "nextToken"))
176
+ SearchQuantumTasksRequest.struct_class = Types::SearchQuantumTasksRequest
177
+
178
+ SearchQuantumTasksRequestfiltersSearchQuantumTasksFilterList.member = Shapes::ShapeRef.new(shape: SearchQuantumTasksFilter)
179
+
180
+ SearchQuantumTasksResponse.add_member(:next_token, Shapes::ShapeRef.new(shape: String, location_name: "nextToken"))
181
+ SearchQuantumTasksResponse.add_member(:quantum_tasks, Shapes::ShapeRef.new(shape: QuantumTaskSummaryList, required: true, location_name: "quantumTasks"))
182
+ SearchQuantumTasksResponse.struct_class = Types::SearchQuantumTasksResponse
183
+
184
+ ServiceQuotaExceededException.add_member(:message, Shapes::ShapeRef.new(shape: String, location_name: "message"))
185
+ ServiceQuotaExceededException.struct_class = Types::ServiceQuotaExceededException
186
+
187
+ ThrottlingException.add_member(:message, Shapes::ShapeRef.new(shape: String, location_name: "message"))
188
+ ThrottlingException.struct_class = Types::ThrottlingException
189
+
190
+ ValidationException.add_member(:message, Shapes::ShapeRef.new(shape: String, location_name: "message"))
191
+ ValidationException.struct_class = Types::ValidationException
192
+
193
+
194
+ # @api private
195
+ API = Seahorse::Model::Api.new.tap do |api|
196
+
197
+ api.version = "2019-09-01"
198
+
199
+ api.metadata = {
200
+ "apiVersion" => "2019-09-01",
201
+ "endpointPrefix" => "braket",
202
+ "jsonVersion" => "1.1",
203
+ "protocol" => "rest-json",
204
+ "serviceFullName" => "Braket",
205
+ "serviceId" => "Braket",
206
+ "signatureVersion" => "v4",
207
+ "signingName" => "braket",
208
+ "uid" => "braket-2019-09-01",
209
+ }
210
+
211
+ api.add_operation(:cancel_quantum_task, Seahorse::Model::Operation.new.tap do |o|
212
+ o.name = "CancelQuantumTask"
213
+ o.http_method = "PUT"
214
+ o.http_request_uri = "/quantum-task/{quantumTaskArn}/cancel"
215
+ o.input = Shapes::ShapeRef.new(shape: CancelQuantumTaskRequest)
216
+ o.output = Shapes::ShapeRef.new(shape: CancelQuantumTaskResponse)
217
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
218
+ o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
219
+ o.errors << Shapes::ShapeRef.new(shape: ConflictException)
220
+ o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
221
+ o.errors << Shapes::ShapeRef.new(shape: InternalServiceException)
222
+ o.errors << Shapes::ShapeRef.new(shape: ValidationException)
223
+ end)
224
+
225
+ api.add_operation(:create_quantum_task, Seahorse::Model::Operation.new.tap do |o|
226
+ o.name = "CreateQuantumTask"
227
+ o.http_method = "POST"
228
+ o.http_request_uri = "/quantum-task"
229
+ o.input = Shapes::ShapeRef.new(shape: CreateQuantumTaskRequest)
230
+ o.output = Shapes::ShapeRef.new(shape: CreateQuantumTaskResponse)
231
+ o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
232
+ o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
233
+ o.errors << Shapes::ShapeRef.new(shape: DeviceOfflineException)
234
+ o.errors << Shapes::ShapeRef.new(shape: InternalServiceException)
235
+ o.errors << Shapes::ShapeRef.new(shape: ServiceQuotaExceededException)
236
+ o.errors << Shapes::ShapeRef.new(shape: ValidationException)
237
+ end)
238
+
239
+ api.add_operation(:get_device, Seahorse::Model::Operation.new.tap do |o|
240
+ o.name = "GetDevice"
241
+ o.http_method = "GET"
242
+ o.http_request_uri = "/device/{deviceArn}"
243
+ o.input = Shapes::ShapeRef.new(shape: GetDeviceRequest)
244
+ o.output = Shapes::ShapeRef.new(shape: GetDeviceResponse)
245
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
246
+ o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
247
+ o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
248
+ o.errors << Shapes::ShapeRef.new(shape: InternalServiceException)
249
+ o.errors << Shapes::ShapeRef.new(shape: ValidationException)
250
+ end)
251
+
252
+ api.add_operation(:get_quantum_task, Seahorse::Model::Operation.new.tap do |o|
253
+ o.name = "GetQuantumTask"
254
+ o.http_method = "GET"
255
+ o.http_request_uri = "/quantum-task/{quantumTaskArn}"
256
+ o.input = Shapes::ShapeRef.new(shape: GetQuantumTaskRequest)
257
+ o.output = Shapes::ShapeRef.new(shape: GetQuantumTaskResponse)
258
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
259
+ o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
260
+ o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
261
+ o.errors << Shapes::ShapeRef.new(shape: InternalServiceException)
262
+ o.errors << Shapes::ShapeRef.new(shape: ValidationException)
263
+ end)
264
+
265
+ api.add_operation(:search_devices, Seahorse::Model::Operation.new.tap do |o|
266
+ o.name = "SearchDevices"
267
+ o.http_method = "POST"
268
+ o.http_request_uri = "/devices"
269
+ o.input = Shapes::ShapeRef.new(shape: SearchDevicesRequest)
270
+ o.output = Shapes::ShapeRef.new(shape: SearchDevicesResponse)
271
+ o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
272
+ o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
273
+ o.errors << Shapes::ShapeRef.new(shape: InternalServiceException)
274
+ o.errors << Shapes::ShapeRef.new(shape: ValidationException)
275
+ o[:pager] = Aws::Pager.new(
276
+ limit_key: "max_results",
277
+ tokens: {
278
+ "next_token" => "next_token"
279
+ }
280
+ )
281
+ end)
282
+
283
+ api.add_operation(:search_quantum_tasks, Seahorse::Model::Operation.new.tap do |o|
284
+ o.name = "SearchQuantumTasks"
285
+ o.http_method = "POST"
286
+ o.http_request_uri = "/quantum-tasks"
287
+ o.input = Shapes::ShapeRef.new(shape: SearchQuantumTasksRequest)
288
+ o.output = Shapes::ShapeRef.new(shape: SearchQuantumTasksResponse)
289
+ o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
290
+ o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
291
+ o.errors << Shapes::ShapeRef.new(shape: InternalServiceException)
292
+ o.errors << Shapes::ShapeRef.new(shape: ValidationException)
293
+ o[:pager] = Aws::Pager.new(
294
+ limit_key: "max_results",
295
+ tokens: {
296
+ "next_token" => "next_token"
297
+ }
298
+ )
299
+ end)
300
+ end
301
+
302
+ end
303
+ end
File without changes
@@ -0,0 +1,166 @@
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/master/CONTRIBUTING.md
7
+ #
8
+ # WARNING ABOUT GENERATED CODE
9
+
10
+ module Aws::Braket
11
+
12
+ # When Braket returns an error response, the Ruby SDK constructs and raises an error.
13
+ # These errors all extend Aws::Braket::Errors::ServiceError < {Aws::Errors::ServiceError}
14
+ #
15
+ # You can rescue all Braket errors using ServiceError:
16
+ #
17
+ # begin
18
+ # # do stuff
19
+ # rescue Aws::Braket::Errors::ServiceError
20
+ # # rescues all Braket API errors
21
+ # end
22
+ #
23
+ #
24
+ # ## Request Context
25
+ # ServiceError objects have a {Aws::Errors::ServiceError#context #context} method that returns
26
+ # information about the request that generated the error.
27
+ # See {Seahorse::Client::RequestContext} for more information.
28
+ #
29
+ # ## Error Classes
30
+ # * {AccessDeniedException}
31
+ # * {ConflictException}
32
+ # * {DeviceOfflineException}
33
+ # * {InternalServiceException}
34
+ # * {ResourceNotFoundException}
35
+ # * {ServiceQuotaExceededException}
36
+ # * {ThrottlingException}
37
+ # * {ValidationException}
38
+ #
39
+ # Additionally, error classes are dynamically generated for service errors based on the error code
40
+ # if they are not defined above.
41
+ module Errors
42
+
43
+ extend Aws::Errors::DynamicErrors
44
+
45
+ class AccessDeniedException < ServiceError
46
+
47
+ # @param [Seahorse::Client::RequestContext] context
48
+ # @param [String] message
49
+ # @param [Aws::Braket::Types::AccessDeniedException] data
50
+ def initialize(context, message, data = Aws::EmptyStructure.new)
51
+ super(context, message, data)
52
+ end
53
+
54
+ # @return [String]
55
+ def message
56
+ @message || @data[:message]
57
+ end
58
+ end
59
+
60
+ class ConflictException < ServiceError
61
+
62
+ # @param [Seahorse::Client::RequestContext] context
63
+ # @param [String] message
64
+ # @param [Aws::Braket::Types::ConflictException] data
65
+ def initialize(context, message, data = Aws::EmptyStructure.new)
66
+ super(context, message, data)
67
+ end
68
+
69
+ # @return [String]
70
+ def message
71
+ @message || @data[:message]
72
+ end
73
+ end
74
+
75
+ class DeviceOfflineException < ServiceError
76
+
77
+ # @param [Seahorse::Client::RequestContext] context
78
+ # @param [String] message
79
+ # @param [Aws::Braket::Types::DeviceOfflineException] data
80
+ def initialize(context, message, data = Aws::EmptyStructure.new)
81
+ super(context, message, data)
82
+ end
83
+
84
+ # @return [String]
85
+ def message
86
+ @message || @data[:message]
87
+ end
88
+ end
89
+
90
+ class InternalServiceException < ServiceError
91
+
92
+ # @param [Seahorse::Client::RequestContext] context
93
+ # @param [String] message
94
+ # @param [Aws::Braket::Types::InternalServiceException] data
95
+ def initialize(context, message, data = Aws::EmptyStructure.new)
96
+ super(context, message, data)
97
+ end
98
+
99
+ # @return [String]
100
+ def message
101
+ @message || @data[:message]
102
+ end
103
+ end
104
+
105
+ class ResourceNotFoundException < ServiceError
106
+
107
+ # @param [Seahorse::Client::RequestContext] context
108
+ # @param [String] message
109
+ # @param [Aws::Braket::Types::ResourceNotFoundException] data
110
+ def initialize(context, message, data = Aws::EmptyStructure.new)
111
+ super(context, message, data)
112
+ end
113
+
114
+ # @return [String]
115
+ def message
116
+ @message || @data[:message]
117
+ end
118
+ end
119
+
120
+ class ServiceQuotaExceededException < ServiceError
121
+
122
+ # @param [Seahorse::Client::RequestContext] context
123
+ # @param [String] message
124
+ # @param [Aws::Braket::Types::ServiceQuotaExceededException] data
125
+ def initialize(context, message, data = Aws::EmptyStructure.new)
126
+ super(context, message, data)
127
+ end
128
+
129
+ # @return [String]
130
+ def message
131
+ @message || @data[:message]
132
+ end
133
+ end
134
+
135
+ class ThrottlingException < ServiceError
136
+
137
+ # @param [Seahorse::Client::RequestContext] context
138
+ # @param [String] message
139
+ # @param [Aws::Braket::Types::ThrottlingException] data
140
+ def initialize(context, message, data = Aws::EmptyStructure.new)
141
+ super(context, message, data)
142
+ end
143
+
144
+ # @return [String]
145
+ def message
146
+ @message || @data[:message]
147
+ end
148
+ end
149
+
150
+ class ValidationException < ServiceError
151
+
152
+ # @param [Seahorse::Client::RequestContext] context
153
+ # @param [String] message
154
+ # @param [Aws::Braket::Types::ValidationException] data
155
+ def initialize(context, message, data = Aws::EmptyStructure.new)
156
+ super(context, message, data)
157
+ end
158
+
159
+ # @return [String]
160
+ def message
161
+ @message || @data[:message]
162
+ end
163
+ end
164
+
165
+ end
166
+ end