rusoto_imagebuilder/
generated.rs

1// =================================================================
2//
3//                           * WARNING *
4//
5//                    This file is generated!
6//
7//  Changes made to this file will be overwritten. If changes are
8//  required to the generated code, the service_crategen project
9//  must be updated to generate the changes.
10//
11// =================================================================
12
13use std::error::Error;
14use std::fmt;
15
16use async_trait::async_trait;
17use rusoto_core::credential::ProvideAwsCredentials;
18use rusoto_core::region;
19use rusoto_core::request::{BufferedHttpResponse, DispatchSignedRequest};
20use rusoto_core::{Client, RusotoError};
21
22use rusoto_core::param::{Params, ServiceParams};
23use rusoto_core::proto;
24use rusoto_core::signature::SignedRequest;
25#[allow(unused_imports)]
26use serde::{Deserialize, Serialize};
27use serde_json;
28/// <p> Details of an EC2 AMI. </p>
29#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
30#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
31pub struct Ami {
32    /// <p>The description of the EC2 AMI. </p>
33    #[serde(rename = "description")]
34    #[serde(skip_serializing_if = "Option::is_none")]
35    pub description: Option<String>,
36    /// <p>The AMI ID of the EC2 AMI. </p>
37    #[serde(rename = "image")]
38    #[serde(skip_serializing_if = "Option::is_none")]
39    pub image: Option<String>,
40    /// <p>The name of the EC2 AMI. </p>
41    #[serde(rename = "name")]
42    #[serde(skip_serializing_if = "Option::is_none")]
43    pub name: Option<String>,
44    /// <p>The AWS Region of the EC2 AMI. </p>
45    #[serde(rename = "region")]
46    #[serde(skip_serializing_if = "Option::is_none")]
47    pub region: Option<String>,
48    #[serde(rename = "state")]
49    #[serde(skip_serializing_if = "Option::is_none")]
50    pub state: Option<ImageState>,
51}
52
53/// <p> Define and configure the output AMIs of the pipeline. </p>
54#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
55pub struct AmiDistributionConfiguration {
56    /// <p>The tags to apply to AMIs distributed to this Region. </p>
57    #[serde(rename = "amiTags")]
58    #[serde(skip_serializing_if = "Option::is_none")]
59    pub ami_tags: Option<::std::collections::HashMap<String, String>>,
60    /// <p>The description of the distribution configuration. </p>
61    #[serde(rename = "description")]
62    #[serde(skip_serializing_if = "Option::is_none")]
63    pub description: Option<String>,
64    /// <p> The KMS key identifier used to encrypt the distributed image. </p>
65    #[serde(rename = "kmsKeyId")]
66    #[serde(skip_serializing_if = "Option::is_none")]
67    pub kms_key_id: Option<String>,
68    /// <p> Launch permissions can be used to configure which AWS accounts can use the AMI to launch instances. </p>
69    #[serde(rename = "launchPermission")]
70    #[serde(skip_serializing_if = "Option::is_none")]
71    pub launch_permission: Option<LaunchPermissionConfiguration>,
72    /// <p>The name of the distribution configuration. </p>
73    #[serde(rename = "name")]
74    #[serde(skip_serializing_if = "Option::is_none")]
75    pub name: Option<String>,
76}
77
78#[derive(Clone, Debug, Default, PartialEq, Serialize)]
79#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
80pub struct CancelImageCreationRequest {
81    /// <p>The idempotency token used to make this request idempotent.</p>
82    #[serde(rename = "clientToken")]
83    pub client_token: String,
84    /// <p>The Amazon Resource Name (ARN) of the image whose creation you want to cancel.</p>
85    #[serde(rename = "imageBuildVersionArn")]
86    pub image_build_version_arn: String,
87}
88
89#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
90#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
91pub struct CancelImageCreationResponse {
92    /// <p>The idempotency token used to make this request idempotent.</p>
93    #[serde(rename = "clientToken")]
94    #[serde(skip_serializing_if = "Option::is_none")]
95    pub client_token: Option<String>,
96    /// <p>The Amazon Resource Name (ARN) of the image whose creation has been cancelled.</p>
97    #[serde(rename = "imageBuildVersionArn")]
98    #[serde(skip_serializing_if = "Option::is_none")]
99    pub image_build_version_arn: Option<String>,
100    /// <p>The request ID that uniquely identifies this request.</p>
101    #[serde(rename = "requestId")]
102    #[serde(skip_serializing_if = "Option::is_none")]
103    pub request_id: Option<String>,
104}
105
106/// <p>A detailed view of a component.</p>
107#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
108#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
109pub struct Component {
110    /// <p>The Amazon Resource Name (ARN) of the component.</p>
111    #[serde(rename = "arn")]
112    #[serde(skip_serializing_if = "Option::is_none")]
113    pub arn: Option<String>,
114    /// <p>The change description of the component.</p>
115    #[serde(rename = "changeDescription")]
116    #[serde(skip_serializing_if = "Option::is_none")]
117    pub change_description: Option<String>,
118    /// <p>The data of the component.</p>
119    #[serde(rename = "data")]
120    #[serde(skip_serializing_if = "Option::is_none")]
121    pub data: Option<String>,
122    /// <p>The date that the component was created.</p>
123    #[serde(rename = "dateCreated")]
124    #[serde(skip_serializing_if = "Option::is_none")]
125    pub date_created: Option<String>,
126    /// <p>The description of the component.</p>
127    #[serde(rename = "description")]
128    #[serde(skip_serializing_if = "Option::is_none")]
129    pub description: Option<String>,
130    /// <p>The encryption status of the component.</p>
131    #[serde(rename = "encrypted")]
132    #[serde(skip_serializing_if = "Option::is_none")]
133    pub encrypted: Option<bool>,
134    /// <p>The KMS key identifier used to encrypt the component.</p>
135    #[serde(rename = "kmsKeyId")]
136    #[serde(skip_serializing_if = "Option::is_none")]
137    pub kms_key_id: Option<String>,
138    /// <p>The name of the component.</p>
139    #[serde(rename = "name")]
140    #[serde(skip_serializing_if = "Option::is_none")]
141    pub name: Option<String>,
142    /// <p>The owner of the component.</p>
143    #[serde(rename = "owner")]
144    #[serde(skip_serializing_if = "Option::is_none")]
145    pub owner: Option<String>,
146    /// <p>The platform of the component.</p>
147    #[serde(rename = "platform")]
148    #[serde(skip_serializing_if = "Option::is_none")]
149    pub platform: Option<String>,
150    /// <p>The operating system (OS) version supported by the component. If the OS information is available, a prefix match is performed against the parent image OS version during image recipe creation. </p>
151    #[serde(rename = "supportedOsVersions")]
152    #[serde(skip_serializing_if = "Option::is_none")]
153    pub supported_os_versions: Option<Vec<String>>,
154    /// <p>The tags associated with the component.</p>
155    #[serde(rename = "tags")]
156    #[serde(skip_serializing_if = "Option::is_none")]
157    pub tags: Option<::std::collections::HashMap<String, String>>,
158    /// <p>The type of the component denotes whether the component is used to build the image or only to test it.</p>
159    #[serde(rename = "type")]
160    #[serde(skip_serializing_if = "Option::is_none")]
161    pub type_: Option<String>,
162    /// <p>The version of the component.</p>
163    #[serde(rename = "version")]
164    #[serde(skip_serializing_if = "Option::is_none")]
165    pub version: Option<String>,
166}
167
168/// <p> Configuration details of the component. </p>
169#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
170pub struct ComponentConfiguration {
171    /// <p>The Amazon Resource Name (ARN) of the component. </p>
172    #[serde(rename = "componentArn")]
173    pub component_arn: String,
174}
175
176/// <p>A high-level summary of a component.</p>
177#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
178#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
179pub struct ComponentSummary {
180    /// <p>The Amazon Resource Name (ARN) of the component.</p>
181    #[serde(rename = "arn")]
182    #[serde(skip_serializing_if = "Option::is_none")]
183    pub arn: Option<String>,
184    /// <p>The change description of the component.</p>
185    #[serde(rename = "changeDescription")]
186    #[serde(skip_serializing_if = "Option::is_none")]
187    pub change_description: Option<String>,
188    /// <p>The date that the component was created.</p>
189    #[serde(rename = "dateCreated")]
190    #[serde(skip_serializing_if = "Option::is_none")]
191    pub date_created: Option<String>,
192    /// <p>The description of the component.</p>
193    #[serde(rename = "description")]
194    #[serde(skip_serializing_if = "Option::is_none")]
195    pub description: Option<String>,
196    /// <p>The name of the component.</p>
197    #[serde(rename = "name")]
198    #[serde(skip_serializing_if = "Option::is_none")]
199    pub name: Option<String>,
200    /// <p>The owner of the component.</p>
201    #[serde(rename = "owner")]
202    #[serde(skip_serializing_if = "Option::is_none")]
203    pub owner: Option<String>,
204    /// <p>The platform of the component.</p>
205    #[serde(rename = "platform")]
206    #[serde(skip_serializing_if = "Option::is_none")]
207    pub platform: Option<String>,
208    /// <p>The operating system (OS) version supported by the component. If the OS information is available, a prefix match is performed against the parent image OS version during image recipe creation. </p>
209    #[serde(rename = "supportedOsVersions")]
210    #[serde(skip_serializing_if = "Option::is_none")]
211    pub supported_os_versions: Option<Vec<String>>,
212    /// <p>The tags associated with the component.</p>
213    #[serde(rename = "tags")]
214    #[serde(skip_serializing_if = "Option::is_none")]
215    pub tags: Option<::std::collections::HashMap<String, String>>,
216    /// <p>The type of the component denotes whether the component is used to build the image or only to test it.</p>
217    #[serde(rename = "type")]
218    #[serde(skip_serializing_if = "Option::is_none")]
219    pub type_: Option<String>,
220    /// <p>The version of the component.</p>
221    #[serde(rename = "version")]
222    #[serde(skip_serializing_if = "Option::is_none")]
223    pub version: Option<String>,
224}
225
226/// <p>A high-level overview of a component semantic version.</p>
227#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
228#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
229pub struct ComponentVersion {
230    /// <p>The Amazon Resource Name (ARN) of the component.</p>
231    #[serde(rename = "arn")]
232    #[serde(skip_serializing_if = "Option::is_none")]
233    pub arn: Option<String>,
234    /// <p>The date that the component was created.</p>
235    #[serde(rename = "dateCreated")]
236    #[serde(skip_serializing_if = "Option::is_none")]
237    pub date_created: Option<String>,
238    /// <p>The description of the component.</p>
239    #[serde(rename = "description")]
240    #[serde(skip_serializing_if = "Option::is_none")]
241    pub description: Option<String>,
242    /// <p>The name of the component.</p>
243    #[serde(rename = "name")]
244    #[serde(skip_serializing_if = "Option::is_none")]
245    pub name: Option<String>,
246    /// <p>The owner of the component.</p>
247    #[serde(rename = "owner")]
248    #[serde(skip_serializing_if = "Option::is_none")]
249    pub owner: Option<String>,
250    /// <p>The platform of the component.</p>
251    #[serde(rename = "platform")]
252    #[serde(skip_serializing_if = "Option::is_none")]
253    pub platform: Option<String>,
254    /// <p> The operating system (OS) version supported by the component. If the OS information is available, a prefix match is performed against the parent image OS version during image recipe creation. </p>
255    #[serde(rename = "supportedOsVersions")]
256    #[serde(skip_serializing_if = "Option::is_none")]
257    pub supported_os_versions: Option<Vec<String>>,
258    /// <p>The type of the component denotes whether the component is used to build the image or only to test it.</p>
259    #[serde(rename = "type")]
260    #[serde(skip_serializing_if = "Option::is_none")]
261    pub type_: Option<String>,
262    /// <p>The semantic version of the component.</p>
263    #[serde(rename = "version")]
264    #[serde(skip_serializing_if = "Option::is_none")]
265    pub version: Option<String>,
266}
267
268#[derive(Clone, Debug, Default, PartialEq, Serialize)]
269#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
270pub struct CreateComponentRequest {
271    /// <p>The change description of the component. Describes what change has been made in this version, or what makes this version different from other versions of this component.</p>
272    #[serde(rename = "changeDescription")]
273    #[serde(skip_serializing_if = "Option::is_none")]
274    pub change_description: Option<String>,
275    /// <p>The idempotency token of the component.</p>
276    #[serde(rename = "clientToken")]
277    pub client_token: String,
278    /// <p>The data of the component. Used to specify the data inline. Either <code>data</code> or <code>uri</code> can be used to specify the data within the component.</p>
279    #[serde(rename = "data")]
280    #[serde(skip_serializing_if = "Option::is_none")]
281    pub data: Option<String>,
282    /// <p>The description of the component. Describes the contents of the component.</p>
283    #[serde(rename = "description")]
284    #[serde(skip_serializing_if = "Option::is_none")]
285    pub description: Option<String>,
286    /// <p>The ID of the KMS key that should be used to encrypt this component.</p>
287    #[serde(rename = "kmsKeyId")]
288    #[serde(skip_serializing_if = "Option::is_none")]
289    pub kms_key_id: Option<String>,
290    /// <p>The name of the component.</p>
291    #[serde(rename = "name")]
292    pub name: String,
293    /// <p>The platform of the component.</p>
294    #[serde(rename = "platform")]
295    pub platform: String,
296    /// <p>The semantic version of the component. This version follows the semantic version syntax. For example, major.minor.patch. This could be versioned like software (2.0.1) or like a date (2019.12.01).</p>
297    #[serde(rename = "semanticVersion")]
298    pub semantic_version: String,
299    /// <p> The operating system (OS) version supported by the component. If the OS information is available, a prefix match is performed against the parent image OS version during image recipe creation. </p>
300    #[serde(rename = "supportedOsVersions")]
301    #[serde(skip_serializing_if = "Option::is_none")]
302    pub supported_os_versions: Option<Vec<String>>,
303    /// <p>The tags of the component.</p>
304    #[serde(rename = "tags")]
305    #[serde(skip_serializing_if = "Option::is_none")]
306    pub tags: Option<::std::collections::HashMap<String, String>>,
307    /// <p>The uri of the component. Must be an S3 URL and the requester must have permission to access the S3 bucket. If you use S3, you can specify component content up to your service quota. Either <code>data</code> or <code>uri</code> can be used to specify the data within the component.</p>
308    #[serde(rename = "uri")]
309    #[serde(skip_serializing_if = "Option::is_none")]
310    pub uri: Option<String>,
311}
312
313#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
314#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
315pub struct CreateComponentResponse {
316    /// <p>The idempotency token used to make this request idempotent.</p>
317    #[serde(rename = "clientToken")]
318    #[serde(skip_serializing_if = "Option::is_none")]
319    pub client_token: Option<String>,
320    /// <p>The Amazon Resource Name (ARN) of the component that was created by this request.</p>
321    #[serde(rename = "componentBuildVersionArn")]
322    #[serde(skip_serializing_if = "Option::is_none")]
323    pub component_build_version_arn: Option<String>,
324    /// <p>The request ID that uniquely identifies this request.</p>
325    #[serde(rename = "requestId")]
326    #[serde(skip_serializing_if = "Option::is_none")]
327    pub request_id: Option<String>,
328}
329
330#[derive(Clone, Debug, Default, PartialEq, Serialize)]
331#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
332pub struct CreateDistributionConfigurationRequest {
333    /// <p> The idempotency token of the distribution configuration. </p>
334    #[serde(rename = "clientToken")]
335    pub client_token: String,
336    /// <p> The description of the distribution configuration. </p>
337    #[serde(rename = "description")]
338    #[serde(skip_serializing_if = "Option::is_none")]
339    pub description: Option<String>,
340    /// <p> The distributions of the distribution configuration. </p>
341    #[serde(rename = "distributions")]
342    pub distributions: Vec<Distribution>,
343    /// <p> The name of the distribution configuration. </p>
344    #[serde(rename = "name")]
345    pub name: String,
346    /// <p> The tags of the distribution configuration. </p>
347    #[serde(rename = "tags")]
348    #[serde(skip_serializing_if = "Option::is_none")]
349    pub tags: Option<::std::collections::HashMap<String, String>>,
350}
351
352#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
353#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
354pub struct CreateDistributionConfigurationResponse {
355    /// <p> The idempotency token used to make this request idempotent. </p>
356    #[serde(rename = "clientToken")]
357    #[serde(skip_serializing_if = "Option::is_none")]
358    pub client_token: Option<String>,
359    /// <p> The Amazon Resource Name (ARN) of the distribution configuration that was created by this request. </p>
360    #[serde(rename = "distributionConfigurationArn")]
361    #[serde(skip_serializing_if = "Option::is_none")]
362    pub distribution_configuration_arn: Option<String>,
363    /// <p> The request ID that uniquely identifies this request. </p>
364    #[serde(rename = "requestId")]
365    #[serde(skip_serializing_if = "Option::is_none")]
366    pub request_id: Option<String>,
367}
368
369#[derive(Clone, Debug, Default, PartialEq, Serialize)]
370#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
371pub struct CreateImagePipelineRequest {
372    /// <p> The idempotency token used to make this request idempotent. </p>
373    #[serde(rename = "clientToken")]
374    pub client_token: String,
375    /// <p> The description of the image pipeline. </p>
376    #[serde(rename = "description")]
377    #[serde(skip_serializing_if = "Option::is_none")]
378    pub description: Option<String>,
379    /// <p> The Amazon Resource Name (ARN) of the distribution configuration that will be used to configure and distribute images created by this image pipeline. </p>
380    #[serde(rename = "distributionConfigurationArn")]
381    #[serde(skip_serializing_if = "Option::is_none")]
382    pub distribution_configuration_arn: Option<String>,
383    /// <p> Collects additional information about the image being created, including the operating system (OS) version and package list. This information is used to enhance the overall experience of using EC2 Image Builder. Enabled by default. </p>
384    #[serde(rename = "enhancedImageMetadataEnabled")]
385    #[serde(skip_serializing_if = "Option::is_none")]
386    pub enhanced_image_metadata_enabled: Option<bool>,
387    /// <p> The Amazon Resource Name (ARN) of the image recipe that will be used to configure images created by this image pipeline. </p>
388    #[serde(rename = "imageRecipeArn")]
389    pub image_recipe_arn: String,
390    /// <p> The image test configuration of the image pipeline. </p>
391    #[serde(rename = "imageTestsConfiguration")]
392    #[serde(skip_serializing_if = "Option::is_none")]
393    pub image_tests_configuration: Option<ImageTestsConfiguration>,
394    /// <p> The Amazon Resource Name (ARN) of the infrastructure configuration that will be used to build images created by this image pipeline. </p>
395    #[serde(rename = "infrastructureConfigurationArn")]
396    pub infrastructure_configuration_arn: String,
397    /// <p> The name of the image pipeline. </p>
398    #[serde(rename = "name")]
399    pub name: String,
400    /// <p> The schedule of the image pipeline. </p>
401    #[serde(rename = "schedule")]
402    #[serde(skip_serializing_if = "Option::is_none")]
403    pub schedule: Option<Schedule>,
404    /// <p> The status of the image pipeline. </p>
405    #[serde(rename = "status")]
406    #[serde(skip_serializing_if = "Option::is_none")]
407    pub status: Option<String>,
408    /// <p> The tags of the image pipeline. </p>
409    #[serde(rename = "tags")]
410    #[serde(skip_serializing_if = "Option::is_none")]
411    pub tags: Option<::std::collections::HashMap<String, String>>,
412}
413
414#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
415#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
416pub struct CreateImagePipelineResponse {
417    /// <p> The idempotency token used to make this request idempotent. </p>
418    #[serde(rename = "clientToken")]
419    #[serde(skip_serializing_if = "Option::is_none")]
420    pub client_token: Option<String>,
421    /// <p> The Amazon Resource Name (ARN) of the image pipeline that was created by this request. </p>
422    #[serde(rename = "imagePipelineArn")]
423    #[serde(skip_serializing_if = "Option::is_none")]
424    pub image_pipeline_arn: Option<String>,
425    /// <p> The request ID that uniquely identifies this request. </p>
426    #[serde(rename = "requestId")]
427    #[serde(skip_serializing_if = "Option::is_none")]
428    pub request_id: Option<String>,
429}
430
431#[derive(Clone, Debug, Default, PartialEq, Serialize)]
432#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
433pub struct CreateImageRecipeRequest {
434    /// <p>The block device mappings of the image recipe. </p>
435    #[serde(rename = "blockDeviceMappings")]
436    #[serde(skip_serializing_if = "Option::is_none")]
437    pub block_device_mappings: Option<Vec<InstanceBlockDeviceMapping>>,
438    /// <p>The idempotency token used to make this request idempotent. </p>
439    #[serde(rename = "clientToken")]
440    pub client_token: String,
441    /// <p>The components of the image recipe. </p>
442    #[serde(rename = "components")]
443    pub components: Vec<ComponentConfiguration>,
444    /// <p> The description of the image recipe. </p>
445    #[serde(rename = "description")]
446    #[serde(skip_serializing_if = "Option::is_none")]
447    pub description: Option<String>,
448    /// <p> The name of the image recipe. </p>
449    #[serde(rename = "name")]
450    pub name: String,
451    /// <p>The parent image of the image recipe. The value of the string can be the ARN of the parent image or an AMI ID. The format for the ARN follows this example: <code>arn:aws:imagebuilder:us-west-2:aws:image/windows-server-2016-english-full-base-x86/2019.x.x</code>. The ARN ends with <code>/20xx.x.x</code>, which communicates to EC2 Image Builder that you want to use the latest AMI created in 20xx (year). You can provide the specific version that you want to use, or you can use a wildcard in all of the fields. If you enter an AMI ID for the string value, you must have access to the AMI, and the AMI must be in the same Region in which you are using Image Builder. </p>
452    #[serde(rename = "parentImage")]
453    pub parent_image: String,
454    /// <p>The semantic version of the image recipe. </p>
455    #[serde(rename = "semanticVersion")]
456    pub semantic_version: String,
457    /// <p> The tags of the image recipe. </p>
458    #[serde(rename = "tags")]
459    #[serde(skip_serializing_if = "Option::is_none")]
460    pub tags: Option<::std::collections::HashMap<String, String>>,
461    /// <p>The working directory to be used during build and test workflows.</p>
462    #[serde(rename = "workingDirectory")]
463    #[serde(skip_serializing_if = "Option::is_none")]
464    pub working_directory: Option<String>,
465}
466
467#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
468#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
469pub struct CreateImageRecipeResponse {
470    /// <p>The idempotency token used to make this request idempotent. </p>
471    #[serde(rename = "clientToken")]
472    #[serde(skip_serializing_if = "Option::is_none")]
473    pub client_token: Option<String>,
474    /// <p>The Amazon Resource Name (ARN) of the image recipe that was created by this request. </p>
475    #[serde(rename = "imageRecipeArn")]
476    #[serde(skip_serializing_if = "Option::is_none")]
477    pub image_recipe_arn: Option<String>,
478    /// <p>The request ID that uniquely identifies this request. </p>
479    #[serde(rename = "requestId")]
480    #[serde(skip_serializing_if = "Option::is_none")]
481    pub request_id: Option<String>,
482}
483
484#[derive(Clone, Debug, Default, PartialEq, Serialize)]
485#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
486pub struct CreateImageRequest {
487    /// <p> The idempotency token used to make this request idempotent. </p>
488    #[serde(rename = "clientToken")]
489    pub client_token: String,
490    /// <p> The Amazon Resource Name (ARN) of the distribution configuration that defines and configures the outputs of your pipeline. </p>
491    #[serde(rename = "distributionConfigurationArn")]
492    #[serde(skip_serializing_if = "Option::is_none")]
493    pub distribution_configuration_arn: Option<String>,
494    /// <p> Collects additional information about the image being created, including the operating system (OS) version and package list. This information is used to enhance the overall experience of using EC2 Image Builder. Enabled by default. </p>
495    #[serde(rename = "enhancedImageMetadataEnabled")]
496    #[serde(skip_serializing_if = "Option::is_none")]
497    pub enhanced_image_metadata_enabled: Option<bool>,
498    /// <p> The Amazon Resource Name (ARN) of the image recipe that defines how images are configured, tested, and assessed. </p>
499    #[serde(rename = "imageRecipeArn")]
500    pub image_recipe_arn: String,
501    /// <p> The image tests configuration of the image. </p>
502    #[serde(rename = "imageTestsConfiguration")]
503    #[serde(skip_serializing_if = "Option::is_none")]
504    pub image_tests_configuration: Option<ImageTestsConfiguration>,
505    /// <p> The Amazon Resource Name (ARN) of the infrastructure configuration that defines the environment in which your image will be built and tested. </p>
506    #[serde(rename = "infrastructureConfigurationArn")]
507    pub infrastructure_configuration_arn: String,
508    /// <p> The tags of the image. </p>
509    #[serde(rename = "tags")]
510    #[serde(skip_serializing_if = "Option::is_none")]
511    pub tags: Option<::std::collections::HashMap<String, String>>,
512}
513
514#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
515#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
516pub struct CreateImageResponse {
517    /// <p> The idempotency token used to make this request idempotent. </p>
518    #[serde(rename = "clientToken")]
519    #[serde(skip_serializing_if = "Option::is_none")]
520    pub client_token: Option<String>,
521    /// <p> The Amazon Resource Name (ARN) of the image that was created by this request. </p>
522    #[serde(rename = "imageBuildVersionArn")]
523    #[serde(skip_serializing_if = "Option::is_none")]
524    pub image_build_version_arn: Option<String>,
525    /// <p> The request ID that uniquely identifies this request. </p>
526    #[serde(rename = "requestId")]
527    #[serde(skip_serializing_if = "Option::is_none")]
528    pub request_id: Option<String>,
529}
530
531#[derive(Clone, Debug, Default, PartialEq, Serialize)]
532#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
533pub struct CreateInfrastructureConfigurationRequest {
534    /// <p>The idempotency token used to make this request idempotent. </p>
535    #[serde(rename = "clientToken")]
536    pub client_token: String,
537    /// <p>The description of the infrastructure configuration. </p>
538    #[serde(rename = "description")]
539    #[serde(skip_serializing_if = "Option::is_none")]
540    pub description: Option<String>,
541    /// <p>The instance profile to associate with the instance used to customize your EC2 AMI. </p>
542    #[serde(rename = "instanceProfileName")]
543    pub instance_profile_name: String,
544    /// <p>The instance types of the infrastructure configuration. You can specify one or more instance types to use for this build. The service will pick one of these instance types based on availability. </p>
545    #[serde(rename = "instanceTypes")]
546    #[serde(skip_serializing_if = "Option::is_none")]
547    pub instance_types: Option<Vec<String>>,
548    /// <p>The key pair of the infrastructure configuration. This can be used to log on to and debug the instance used to create your image. </p>
549    #[serde(rename = "keyPair")]
550    #[serde(skip_serializing_if = "Option::is_none")]
551    pub key_pair: Option<String>,
552    /// <p>The logging configuration of the infrastructure configuration. </p>
553    #[serde(rename = "logging")]
554    #[serde(skip_serializing_if = "Option::is_none")]
555    pub logging: Option<Logging>,
556    /// <p>The name of the infrastructure configuration. </p>
557    #[serde(rename = "name")]
558    pub name: String,
559    /// <p>The tags attached to the resource created by Image Builder.</p>
560    #[serde(rename = "resourceTags")]
561    #[serde(skip_serializing_if = "Option::is_none")]
562    pub resource_tags: Option<::std::collections::HashMap<String, String>>,
563    /// <p>The security group IDs to associate with the instance used to customize your EC2 AMI. </p>
564    #[serde(rename = "securityGroupIds")]
565    #[serde(skip_serializing_if = "Option::is_none")]
566    pub security_group_ids: Option<Vec<String>>,
567    /// <p>The SNS topic on which to send image build events. </p>
568    #[serde(rename = "snsTopicArn")]
569    #[serde(skip_serializing_if = "Option::is_none")]
570    pub sns_topic_arn: Option<String>,
571    /// <p>The subnet ID in which to place the instance used to customize your EC2 AMI. </p>
572    #[serde(rename = "subnetId")]
573    #[serde(skip_serializing_if = "Option::is_none")]
574    pub subnet_id: Option<String>,
575    /// <p>The tags of the infrastructure configuration. </p>
576    #[serde(rename = "tags")]
577    #[serde(skip_serializing_if = "Option::is_none")]
578    pub tags: Option<::std::collections::HashMap<String, String>>,
579    /// <p>The terminate instance on failure setting of the infrastructure configuration. Set to false if you want Image Builder to retain the instance used to configure your AMI if the build or test phase of your workflow fails. </p>
580    #[serde(rename = "terminateInstanceOnFailure")]
581    #[serde(skip_serializing_if = "Option::is_none")]
582    pub terminate_instance_on_failure: Option<bool>,
583}
584
585#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
586#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
587pub struct CreateInfrastructureConfigurationResponse {
588    /// <p>The idempotency token used to make this request idempotent. </p>
589    #[serde(rename = "clientToken")]
590    #[serde(skip_serializing_if = "Option::is_none")]
591    pub client_token: Option<String>,
592    /// <p>The Amazon Resource Name (ARN) of the infrastructure configuration that was created by this request. </p>
593    #[serde(rename = "infrastructureConfigurationArn")]
594    #[serde(skip_serializing_if = "Option::is_none")]
595    pub infrastructure_configuration_arn: Option<String>,
596    /// <p>The request ID that uniquely identifies this request. </p>
597    #[serde(rename = "requestId")]
598    #[serde(skip_serializing_if = "Option::is_none")]
599    pub request_id: Option<String>,
600}
601
602#[derive(Clone, Debug, Default, PartialEq, Serialize)]
603#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
604pub struct DeleteComponentRequest {
605    /// <p>The Amazon Resource Name (ARN) of the component build version to delete. </p>
606    #[serde(rename = "componentBuildVersionArn")]
607    pub component_build_version_arn: String,
608}
609
610#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
611#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
612pub struct DeleteComponentResponse {
613    /// <p>The Amazon Resource Name (ARN) of the component build version that was deleted. </p>
614    #[serde(rename = "componentBuildVersionArn")]
615    #[serde(skip_serializing_if = "Option::is_none")]
616    pub component_build_version_arn: Option<String>,
617    /// <p>The request ID that uniquely identifies this request. </p>
618    #[serde(rename = "requestId")]
619    #[serde(skip_serializing_if = "Option::is_none")]
620    pub request_id: Option<String>,
621}
622
623#[derive(Clone, Debug, Default, PartialEq, Serialize)]
624#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
625pub struct DeleteDistributionConfigurationRequest {
626    /// <p>The Amazon Resource Name (ARN) of the distribution configuration to delete. </p>
627    #[serde(rename = "distributionConfigurationArn")]
628    pub distribution_configuration_arn: String,
629}
630
631#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
632#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
633pub struct DeleteDistributionConfigurationResponse {
634    /// <p>The Amazon Resource Name (ARN) of the distribution configuration that was deleted. </p>
635    #[serde(rename = "distributionConfigurationArn")]
636    #[serde(skip_serializing_if = "Option::is_none")]
637    pub distribution_configuration_arn: Option<String>,
638    /// <p>The request ID that uniquely identifies this request. </p>
639    #[serde(rename = "requestId")]
640    #[serde(skip_serializing_if = "Option::is_none")]
641    pub request_id: Option<String>,
642}
643
644#[derive(Clone, Debug, Default, PartialEq, Serialize)]
645#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
646pub struct DeleteImagePipelineRequest {
647    /// <p>The Amazon Resource Name (ARN) of the image pipeline to delete. </p>
648    #[serde(rename = "imagePipelineArn")]
649    pub image_pipeline_arn: String,
650}
651
652#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
653#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
654pub struct DeleteImagePipelineResponse {
655    /// <p>The Amazon Resource Name (ARN) of the image pipeline that was deleted. </p>
656    #[serde(rename = "imagePipelineArn")]
657    #[serde(skip_serializing_if = "Option::is_none")]
658    pub image_pipeline_arn: Option<String>,
659    /// <p>The request ID that uniquely identifies this request. </p>
660    #[serde(rename = "requestId")]
661    #[serde(skip_serializing_if = "Option::is_none")]
662    pub request_id: Option<String>,
663}
664
665#[derive(Clone, Debug, Default, PartialEq, Serialize)]
666#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
667pub struct DeleteImageRecipeRequest {
668    /// <p>The Amazon Resource Name (ARN) of the image recipe to delete. </p>
669    #[serde(rename = "imageRecipeArn")]
670    pub image_recipe_arn: String,
671}
672
673#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
674#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
675pub struct DeleteImageRecipeResponse {
676    /// <p>The Amazon Resource Name (ARN) of the image recipe that was deleted. </p>
677    #[serde(rename = "imageRecipeArn")]
678    #[serde(skip_serializing_if = "Option::is_none")]
679    pub image_recipe_arn: Option<String>,
680    /// <p>The request ID that uniquely identifies this request. </p>
681    #[serde(rename = "requestId")]
682    #[serde(skip_serializing_if = "Option::is_none")]
683    pub request_id: Option<String>,
684}
685
686#[derive(Clone, Debug, Default, PartialEq, Serialize)]
687#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
688pub struct DeleteImageRequest {
689    /// <p>The Amazon Resource Name (ARN) of the image to delete. </p>
690    #[serde(rename = "imageBuildVersionArn")]
691    pub image_build_version_arn: String,
692}
693
694#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
695#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
696pub struct DeleteImageResponse {
697    /// <p>The Amazon Resource Name (ARN) of the image that was deleted. </p>
698    #[serde(rename = "imageBuildVersionArn")]
699    #[serde(skip_serializing_if = "Option::is_none")]
700    pub image_build_version_arn: Option<String>,
701    /// <p>The request ID that uniquely identifies this request. </p>
702    #[serde(rename = "requestId")]
703    #[serde(skip_serializing_if = "Option::is_none")]
704    pub request_id: Option<String>,
705}
706
707#[derive(Clone, Debug, Default, PartialEq, Serialize)]
708#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
709pub struct DeleteInfrastructureConfigurationRequest {
710    /// <p>The Amazon Resource Name (ARN) of the infrastructure configuration to delete. </p>
711    #[serde(rename = "infrastructureConfigurationArn")]
712    pub infrastructure_configuration_arn: String,
713}
714
715#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
716#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
717pub struct DeleteInfrastructureConfigurationResponse {
718    /// <p>The Amazon Resource Name (ARN) of the infrastructure configuration that was deleted. </p>
719    #[serde(rename = "infrastructureConfigurationArn")]
720    #[serde(skip_serializing_if = "Option::is_none")]
721    pub infrastructure_configuration_arn: Option<String>,
722    /// <p>The request ID that uniquely identifies this request. </p>
723    #[serde(rename = "requestId")]
724    #[serde(skip_serializing_if = "Option::is_none")]
725    pub request_id: Option<String>,
726}
727
728/// <p> Defines the settings for a specific Region. </p>
729#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
730pub struct Distribution {
731    /// <p>The specific AMI settings (for example, launch permissions, AMI tags). </p>
732    #[serde(rename = "amiDistributionConfiguration")]
733    #[serde(skip_serializing_if = "Option::is_none")]
734    pub ami_distribution_configuration: Option<AmiDistributionConfiguration>,
735    /// <p>The License Manager Configuration to associate with the AMI in the specified Region.</p>
736    #[serde(rename = "licenseConfigurationArns")]
737    #[serde(skip_serializing_if = "Option::is_none")]
738    pub license_configuration_arns: Option<Vec<String>>,
739    /// <p>The target Region. </p>
740    #[serde(rename = "region")]
741    pub region: String,
742}
743
744/// <p>A distribution configuration.</p>
745#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
746#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
747pub struct DistributionConfiguration {
748    /// <p>The Amazon Resource Name (ARN) of the distribution configuration.</p>
749    #[serde(rename = "arn")]
750    #[serde(skip_serializing_if = "Option::is_none")]
751    pub arn: Option<String>,
752    /// <p>The date on which this distribution configuration was created.</p>
753    #[serde(rename = "dateCreated")]
754    #[serde(skip_serializing_if = "Option::is_none")]
755    pub date_created: Option<String>,
756    /// <p>The date on which this distribution configuration was last updated.</p>
757    #[serde(rename = "dateUpdated")]
758    #[serde(skip_serializing_if = "Option::is_none")]
759    pub date_updated: Option<String>,
760    /// <p>The description of the distribution configuration.</p>
761    #[serde(rename = "description")]
762    #[serde(skip_serializing_if = "Option::is_none")]
763    pub description: Option<String>,
764    /// <p>The distributions of the distribution configuration.</p>
765    #[serde(rename = "distributions")]
766    #[serde(skip_serializing_if = "Option::is_none")]
767    pub distributions: Option<Vec<Distribution>>,
768    /// <p>The name of the distribution configuration.</p>
769    #[serde(rename = "name")]
770    #[serde(skip_serializing_if = "Option::is_none")]
771    pub name: Option<String>,
772    /// <p>The tags of the distribution configuration.</p>
773    #[serde(rename = "tags")]
774    #[serde(skip_serializing_if = "Option::is_none")]
775    pub tags: Option<::std::collections::HashMap<String, String>>,
776    /// <p>The maximum duration in minutes for this distribution configuration.</p>
777    #[serde(rename = "timeoutMinutes")]
778    pub timeout_minutes: i64,
779}
780
781/// <p>A high-level overview of a distribution configuration.</p>
782#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
783#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
784pub struct DistributionConfigurationSummary {
785    /// <p>The Amazon Resource Name (ARN) of the distribution configuration.</p>
786    #[serde(rename = "arn")]
787    #[serde(skip_serializing_if = "Option::is_none")]
788    pub arn: Option<String>,
789    /// <p>The date on which the distribution configuration was created.</p>
790    #[serde(rename = "dateCreated")]
791    #[serde(skip_serializing_if = "Option::is_none")]
792    pub date_created: Option<String>,
793    /// <p>The date on which the distribution configuration was updated.</p>
794    #[serde(rename = "dateUpdated")]
795    #[serde(skip_serializing_if = "Option::is_none")]
796    pub date_updated: Option<String>,
797    /// <p>The description of the distribution configuration.</p>
798    #[serde(rename = "description")]
799    #[serde(skip_serializing_if = "Option::is_none")]
800    pub description: Option<String>,
801    /// <p>The name of the distribution configuration.</p>
802    #[serde(rename = "name")]
803    #[serde(skip_serializing_if = "Option::is_none")]
804    pub name: Option<String>,
805    /// <p>The tags associated with the distribution configuration.</p>
806    #[serde(rename = "tags")]
807    #[serde(skip_serializing_if = "Option::is_none")]
808    pub tags: Option<::std::collections::HashMap<String, String>>,
809}
810
811/// <p>Amazon EBS-specific block device mapping specifications.</p>
812#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
813pub struct EbsInstanceBlockDeviceSpecification {
814    /// <p>Use to configure delete on termination of the associated device.</p>
815    #[serde(rename = "deleteOnTermination")]
816    #[serde(skip_serializing_if = "Option::is_none")]
817    pub delete_on_termination: Option<bool>,
818    /// <p>Use to configure device encryption.</p>
819    #[serde(rename = "encrypted")]
820    #[serde(skip_serializing_if = "Option::is_none")]
821    pub encrypted: Option<bool>,
822    /// <p>Use to configure device IOPS.</p>
823    #[serde(rename = "iops")]
824    #[serde(skip_serializing_if = "Option::is_none")]
825    pub iops: Option<i64>,
826    /// <p>Use to configure the KMS key to use when encrypting the device.</p>
827    #[serde(rename = "kmsKeyId")]
828    #[serde(skip_serializing_if = "Option::is_none")]
829    pub kms_key_id: Option<String>,
830    /// <p>The snapshot that defines the device contents.</p>
831    #[serde(rename = "snapshotId")]
832    #[serde(skip_serializing_if = "Option::is_none")]
833    pub snapshot_id: Option<String>,
834    /// <p>Use to override the device's volume size.</p>
835    #[serde(rename = "volumeSize")]
836    #[serde(skip_serializing_if = "Option::is_none")]
837    pub volume_size: Option<i64>,
838    /// <p>Use to override the device's volume type.</p>
839    #[serde(rename = "volumeType")]
840    #[serde(skip_serializing_if = "Option::is_none")]
841    pub volume_type: Option<String>,
842}
843
844/// <p>A filter name and value pair that is used to return a more specific list of results from a list operation. Filters can be used to match a set of resources by specific criteria, such as tags, attributes, or IDs. </p>
845#[derive(Clone, Debug, Default, PartialEq, Serialize)]
846#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
847pub struct Filter {
848    /// <p>The name of the filter. Filter names are case-sensitive. </p>
849    #[serde(rename = "name")]
850    #[serde(skip_serializing_if = "Option::is_none")]
851    pub name: Option<String>,
852    /// <p>The filter values. Filter values are case-sensitive. </p>
853    #[serde(rename = "values")]
854    #[serde(skip_serializing_if = "Option::is_none")]
855    pub values: Option<Vec<String>>,
856}
857
858#[derive(Clone, Debug, Default, PartialEq, Serialize)]
859#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
860pub struct GetComponentPolicyRequest {
861    /// <p>The Amazon Resource Name (ARN) of the component whose policy you want to retrieve. </p>
862    #[serde(rename = "componentArn")]
863    pub component_arn: String,
864}
865
866#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
867#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
868pub struct GetComponentPolicyResponse {
869    /// <p>The component policy. </p>
870    #[serde(rename = "policy")]
871    #[serde(skip_serializing_if = "Option::is_none")]
872    pub policy: Option<String>,
873    /// <p>The request ID that uniquely identifies this request. </p>
874    #[serde(rename = "requestId")]
875    #[serde(skip_serializing_if = "Option::is_none")]
876    pub request_id: Option<String>,
877}
878
879#[derive(Clone, Debug, Default, PartialEq, Serialize)]
880#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
881pub struct GetComponentRequest {
882    /// <p>The Amazon Resource Name (ARN) of the component that you want to retrieve. Regex requires "/\d+$" suffix.</p>
883    #[serde(rename = "componentBuildVersionArn")]
884    pub component_build_version_arn: String,
885}
886
887#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
888#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
889pub struct GetComponentResponse {
890    /// <p>The component object associated with the specified ARN. </p>
891    #[serde(rename = "component")]
892    #[serde(skip_serializing_if = "Option::is_none")]
893    pub component: Option<Component>,
894    /// <p>The request ID that uniquely identifies this request. </p>
895    #[serde(rename = "requestId")]
896    #[serde(skip_serializing_if = "Option::is_none")]
897    pub request_id: Option<String>,
898}
899
900#[derive(Clone, Debug, Default, PartialEq, Serialize)]
901#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
902pub struct GetDistributionConfigurationRequest {
903    /// <p>The Amazon Resource Name (ARN) of the distribution configuration that you want to retrieve. </p>
904    #[serde(rename = "distributionConfigurationArn")]
905    pub distribution_configuration_arn: String,
906}
907
908#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
909#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
910pub struct GetDistributionConfigurationResponse {
911    /// <p>The distribution configuration object. </p>
912    #[serde(rename = "distributionConfiguration")]
913    #[serde(skip_serializing_if = "Option::is_none")]
914    pub distribution_configuration: Option<DistributionConfiguration>,
915    /// <p>The request ID that uniquely identifies this request. </p>
916    #[serde(rename = "requestId")]
917    #[serde(skip_serializing_if = "Option::is_none")]
918    pub request_id: Option<String>,
919}
920
921#[derive(Clone, Debug, Default, PartialEq, Serialize)]
922#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
923pub struct GetImagePipelineRequest {
924    /// <p>The Amazon Resource Name (ARN) of the image pipeline that you want to retrieve. </p>
925    #[serde(rename = "imagePipelineArn")]
926    pub image_pipeline_arn: String,
927}
928
929#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
930#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
931pub struct GetImagePipelineResponse {
932    /// <p>The image pipeline object. </p>
933    #[serde(rename = "imagePipeline")]
934    #[serde(skip_serializing_if = "Option::is_none")]
935    pub image_pipeline: Option<ImagePipeline>,
936    /// <p>The request ID that uniquely identifies this request. </p>
937    #[serde(rename = "requestId")]
938    #[serde(skip_serializing_if = "Option::is_none")]
939    pub request_id: Option<String>,
940}
941
942#[derive(Clone, Debug, Default, PartialEq, Serialize)]
943#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
944pub struct GetImagePolicyRequest {
945    /// <p>The Amazon Resource Name (ARN) of the image whose policy you want to retrieve. </p>
946    #[serde(rename = "imageArn")]
947    pub image_arn: String,
948}
949
950#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
951#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
952pub struct GetImagePolicyResponse {
953    /// <p>The image policy object. </p>
954    #[serde(rename = "policy")]
955    #[serde(skip_serializing_if = "Option::is_none")]
956    pub policy: Option<String>,
957    /// <p>The request ID that uniquely identifies this request. </p>
958    #[serde(rename = "requestId")]
959    #[serde(skip_serializing_if = "Option::is_none")]
960    pub request_id: Option<String>,
961}
962
963#[derive(Clone, Debug, Default, PartialEq, Serialize)]
964#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
965pub struct GetImageRecipePolicyRequest {
966    /// <p>The Amazon Resource Name (ARN) of the image recipe whose policy you want to retrieve. </p>
967    #[serde(rename = "imageRecipeArn")]
968    pub image_recipe_arn: String,
969}
970
971#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
972#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
973pub struct GetImageRecipePolicyResponse {
974    /// <p>The image recipe policy object. </p>
975    #[serde(rename = "policy")]
976    #[serde(skip_serializing_if = "Option::is_none")]
977    pub policy: Option<String>,
978    /// <p>The request ID that uniquely identifies this request. </p>
979    #[serde(rename = "requestId")]
980    #[serde(skip_serializing_if = "Option::is_none")]
981    pub request_id: Option<String>,
982}
983
984#[derive(Clone, Debug, Default, PartialEq, Serialize)]
985#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
986pub struct GetImageRecipeRequest {
987    /// <p>The Amazon Resource Name (ARN) of the image recipe that you want to retrieve. </p>
988    #[serde(rename = "imageRecipeArn")]
989    pub image_recipe_arn: String,
990}
991
992#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
993#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
994pub struct GetImageRecipeResponse {
995    /// <p>The image recipe object. </p>
996    #[serde(rename = "imageRecipe")]
997    #[serde(skip_serializing_if = "Option::is_none")]
998    pub image_recipe: Option<ImageRecipe>,
999    /// <p>The request ID that uniquely identifies this request. </p>
1000    #[serde(rename = "requestId")]
1001    #[serde(skip_serializing_if = "Option::is_none")]
1002    pub request_id: Option<String>,
1003}
1004
1005#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1006#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1007pub struct GetImageRequest {
1008    /// <p>The Amazon Resource Name (ARN) of the image that you want to retrieve. </p>
1009    #[serde(rename = "imageBuildVersionArn")]
1010    pub image_build_version_arn: String,
1011}
1012
1013#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1014#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1015pub struct GetImageResponse {
1016    /// <p>The image object. </p>
1017    #[serde(rename = "image")]
1018    #[serde(skip_serializing_if = "Option::is_none")]
1019    pub image: Option<Image>,
1020    /// <p>The request ID that uniquely identifies this request. </p>
1021    #[serde(rename = "requestId")]
1022    #[serde(skip_serializing_if = "Option::is_none")]
1023    pub request_id: Option<String>,
1024}
1025
1026/// <p> GetInfrastructureConfiguration request object. </p>
1027#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1028#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1029pub struct GetInfrastructureConfigurationRequest {
1030    /// <p>The Amazon Resource Name (ARN) of the infrastructure configuration that you want to retrieve. </p>
1031    #[serde(rename = "infrastructureConfigurationArn")]
1032    pub infrastructure_configuration_arn: String,
1033}
1034
1035/// <p>GetInfrastructureConfiguration response object. </p>
1036#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1037#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1038pub struct GetInfrastructureConfigurationResponse {
1039    /// <p>The infrastructure configuration object. </p>
1040    #[serde(rename = "infrastructureConfiguration")]
1041    #[serde(skip_serializing_if = "Option::is_none")]
1042    pub infrastructure_configuration: Option<InfrastructureConfiguration>,
1043    /// <p>The request ID that uniquely identifies this request. </p>
1044    #[serde(rename = "requestId")]
1045    #[serde(skip_serializing_if = "Option::is_none")]
1046    pub request_id: Option<String>,
1047}
1048
1049/// <p>An image build version.</p>
1050#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1051#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1052pub struct Image {
1053    /// <p>The Amazon Resource Name (ARN) of the image.</p>
1054    #[serde(rename = "arn")]
1055    #[serde(skip_serializing_if = "Option::is_none")]
1056    pub arn: Option<String>,
1057    /// <p>The date on which this image was created.</p>
1058    #[serde(rename = "dateCreated")]
1059    #[serde(skip_serializing_if = "Option::is_none")]
1060    pub date_created: Option<String>,
1061    /// <p>The distribution configuration used when creating this image.</p>
1062    #[serde(rename = "distributionConfiguration")]
1063    #[serde(skip_serializing_if = "Option::is_none")]
1064    pub distribution_configuration: Option<DistributionConfiguration>,
1065    /// <p> Collects additional information about the image being created, including the operating system (OS) version and package list. This information is used to enhance the overall experience of using EC2 Image Builder. Enabled by default. </p>
1066    #[serde(rename = "enhancedImageMetadataEnabled")]
1067    #[serde(skip_serializing_if = "Option::is_none")]
1068    pub enhanced_image_metadata_enabled: Option<bool>,
1069    /// <p>The image recipe used when creating the image.</p>
1070    #[serde(rename = "imageRecipe")]
1071    #[serde(skip_serializing_if = "Option::is_none")]
1072    pub image_recipe: Option<ImageRecipe>,
1073    /// <p>The image tests configuration used when creating this image.</p>
1074    #[serde(rename = "imageTestsConfiguration")]
1075    #[serde(skip_serializing_if = "Option::is_none")]
1076    pub image_tests_configuration: Option<ImageTestsConfiguration>,
1077    /// <p>The infrastructure used when creating this image.</p>
1078    #[serde(rename = "infrastructureConfiguration")]
1079    #[serde(skip_serializing_if = "Option::is_none")]
1080    pub infrastructure_configuration: Option<InfrastructureConfiguration>,
1081    /// <p>The name of the image.</p>
1082    #[serde(rename = "name")]
1083    #[serde(skip_serializing_if = "Option::is_none")]
1084    pub name: Option<String>,
1085    /// <p>The operating system version of the instance. For example, Amazon Linux 2, Ubuntu 18, or Microsoft Windows Server 2019. </p>
1086    #[serde(rename = "osVersion")]
1087    #[serde(skip_serializing_if = "Option::is_none")]
1088    pub os_version: Option<String>,
1089    /// <p>The output resources produced when creating this image.</p>
1090    #[serde(rename = "outputResources")]
1091    #[serde(skip_serializing_if = "Option::is_none")]
1092    pub output_resources: Option<OutputResources>,
1093    /// <p>The platform of the image.</p>
1094    #[serde(rename = "platform")]
1095    #[serde(skip_serializing_if = "Option::is_none")]
1096    pub platform: Option<String>,
1097    /// <p>The Amazon Resource Name (ARN) of the image pipeline that created this image.</p>
1098    #[serde(rename = "sourcePipelineArn")]
1099    #[serde(skip_serializing_if = "Option::is_none")]
1100    pub source_pipeline_arn: Option<String>,
1101    /// <p>The name of the image pipeline that created this image.</p>
1102    #[serde(rename = "sourcePipelineName")]
1103    #[serde(skip_serializing_if = "Option::is_none")]
1104    pub source_pipeline_name: Option<String>,
1105    /// <p>The state of the image.</p>
1106    #[serde(rename = "state")]
1107    #[serde(skip_serializing_if = "Option::is_none")]
1108    pub state: Option<ImageState>,
1109    /// <p>The tags of the image.</p>
1110    #[serde(rename = "tags")]
1111    #[serde(skip_serializing_if = "Option::is_none")]
1112    pub tags: Option<::std::collections::HashMap<String, String>>,
1113    /// <p>The semantic version of the image.</p>
1114    #[serde(rename = "version")]
1115    #[serde(skip_serializing_if = "Option::is_none")]
1116    pub version: Option<String>,
1117}
1118
1119/// <p>Details of an image pipeline.</p>
1120#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1121#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1122pub struct ImagePipeline {
1123    /// <p>The Amazon Resource Name (ARN) of the image pipeline.</p>
1124    #[serde(rename = "arn")]
1125    #[serde(skip_serializing_if = "Option::is_none")]
1126    pub arn: Option<String>,
1127    /// <p>The date on which this image pipeline was created.</p>
1128    #[serde(rename = "dateCreated")]
1129    #[serde(skip_serializing_if = "Option::is_none")]
1130    pub date_created: Option<String>,
1131    /// <p>The date on which this image pipeline was last run.</p>
1132    #[serde(rename = "dateLastRun")]
1133    #[serde(skip_serializing_if = "Option::is_none")]
1134    pub date_last_run: Option<String>,
1135    /// <p>The date on which this image pipeline will next be run.</p>
1136    #[serde(rename = "dateNextRun")]
1137    #[serde(skip_serializing_if = "Option::is_none")]
1138    pub date_next_run: Option<String>,
1139    /// <p>The date on which this image pipeline was last updated.</p>
1140    #[serde(rename = "dateUpdated")]
1141    #[serde(skip_serializing_if = "Option::is_none")]
1142    pub date_updated: Option<String>,
1143    /// <p>The description of the image pipeline.</p>
1144    #[serde(rename = "description")]
1145    #[serde(skip_serializing_if = "Option::is_none")]
1146    pub description: Option<String>,
1147    /// <p>The Amazon Resource Name (ARN) of the distribution configuration associated with this image pipeline.</p>
1148    #[serde(rename = "distributionConfigurationArn")]
1149    #[serde(skip_serializing_if = "Option::is_none")]
1150    pub distribution_configuration_arn: Option<String>,
1151    /// <p> Collects additional information about the image being created, including the operating system (OS) version and package list. This information is used to enhance the overall experience of using EC2 Image Builder. Enabled by default. </p>
1152    #[serde(rename = "enhancedImageMetadataEnabled")]
1153    #[serde(skip_serializing_if = "Option::is_none")]
1154    pub enhanced_image_metadata_enabled: Option<bool>,
1155    /// <p>The Amazon Resource Name (ARN) of the image recipe associated with this image pipeline.</p>
1156    #[serde(rename = "imageRecipeArn")]
1157    #[serde(skip_serializing_if = "Option::is_none")]
1158    pub image_recipe_arn: Option<String>,
1159    /// <p>The image tests configuration of the image pipeline.</p>
1160    #[serde(rename = "imageTestsConfiguration")]
1161    #[serde(skip_serializing_if = "Option::is_none")]
1162    pub image_tests_configuration: Option<ImageTestsConfiguration>,
1163    /// <p>The Amazon Resource Name (ARN) of the infrastructure configuration associated with this image pipeline.</p>
1164    #[serde(rename = "infrastructureConfigurationArn")]
1165    #[serde(skip_serializing_if = "Option::is_none")]
1166    pub infrastructure_configuration_arn: Option<String>,
1167    /// <p>The name of the image pipeline.</p>
1168    #[serde(rename = "name")]
1169    #[serde(skip_serializing_if = "Option::is_none")]
1170    pub name: Option<String>,
1171    /// <p>The platform of the image pipeline.</p>
1172    #[serde(rename = "platform")]
1173    #[serde(skip_serializing_if = "Option::is_none")]
1174    pub platform: Option<String>,
1175    /// <p>The schedule of the image pipeline.</p>
1176    #[serde(rename = "schedule")]
1177    #[serde(skip_serializing_if = "Option::is_none")]
1178    pub schedule: Option<Schedule>,
1179    /// <p>The status of the image pipeline.</p>
1180    #[serde(rename = "status")]
1181    #[serde(skip_serializing_if = "Option::is_none")]
1182    pub status: Option<String>,
1183    /// <p>The tags of this image pipeline.</p>
1184    #[serde(rename = "tags")]
1185    #[serde(skip_serializing_if = "Option::is_none")]
1186    pub tags: Option<::std::collections::HashMap<String, String>>,
1187}
1188
1189/// <p>An image recipe.</p>
1190#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1191#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1192pub struct ImageRecipe {
1193    /// <p>The Amazon Resource Name (ARN) of the image recipe.</p>
1194    #[serde(rename = "arn")]
1195    #[serde(skip_serializing_if = "Option::is_none")]
1196    pub arn: Option<String>,
1197    /// <p>The block device mappings to apply when creating images from this recipe.</p>
1198    #[serde(rename = "blockDeviceMappings")]
1199    #[serde(skip_serializing_if = "Option::is_none")]
1200    pub block_device_mappings: Option<Vec<InstanceBlockDeviceMapping>>,
1201    /// <p>The components of the image recipe.</p>
1202    #[serde(rename = "components")]
1203    #[serde(skip_serializing_if = "Option::is_none")]
1204    pub components: Option<Vec<ComponentConfiguration>>,
1205    /// <p>The date on which this image recipe was created.</p>
1206    #[serde(rename = "dateCreated")]
1207    #[serde(skip_serializing_if = "Option::is_none")]
1208    pub date_created: Option<String>,
1209    /// <p>The description of the image recipe.</p>
1210    #[serde(rename = "description")]
1211    #[serde(skip_serializing_if = "Option::is_none")]
1212    pub description: Option<String>,
1213    /// <p>The name of the image recipe.</p>
1214    #[serde(rename = "name")]
1215    #[serde(skip_serializing_if = "Option::is_none")]
1216    pub name: Option<String>,
1217    /// <p>The owner of the image recipe.</p>
1218    #[serde(rename = "owner")]
1219    #[serde(skip_serializing_if = "Option::is_none")]
1220    pub owner: Option<String>,
1221    /// <p>The parent image of the image recipe.</p>
1222    #[serde(rename = "parentImage")]
1223    #[serde(skip_serializing_if = "Option::is_none")]
1224    pub parent_image: Option<String>,
1225    /// <p>The platform of the image recipe.</p>
1226    #[serde(rename = "platform")]
1227    #[serde(skip_serializing_if = "Option::is_none")]
1228    pub platform: Option<String>,
1229    /// <p>The tags of the image recipe.</p>
1230    #[serde(rename = "tags")]
1231    #[serde(skip_serializing_if = "Option::is_none")]
1232    pub tags: Option<::std::collections::HashMap<String, String>>,
1233    /// <p>The version of the image recipe.</p>
1234    #[serde(rename = "version")]
1235    #[serde(skip_serializing_if = "Option::is_none")]
1236    pub version: Option<String>,
1237    /// <p>The working directory to be used during build and test workflows.</p>
1238    #[serde(rename = "workingDirectory")]
1239    #[serde(skip_serializing_if = "Option::is_none")]
1240    pub working_directory: Option<String>,
1241}
1242
1243/// <p>A summary of an image recipe.</p>
1244#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1245#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1246pub struct ImageRecipeSummary {
1247    /// <p>The Amazon Resource Name (ARN) of the image recipe.</p>
1248    #[serde(rename = "arn")]
1249    #[serde(skip_serializing_if = "Option::is_none")]
1250    pub arn: Option<String>,
1251    /// <p>The date on which this image recipe was created.</p>
1252    #[serde(rename = "dateCreated")]
1253    #[serde(skip_serializing_if = "Option::is_none")]
1254    pub date_created: Option<String>,
1255    /// <p>The name of the image recipe.</p>
1256    #[serde(rename = "name")]
1257    #[serde(skip_serializing_if = "Option::is_none")]
1258    pub name: Option<String>,
1259    /// <p>The owner of the image recipe.</p>
1260    #[serde(rename = "owner")]
1261    #[serde(skip_serializing_if = "Option::is_none")]
1262    pub owner: Option<String>,
1263    /// <p>The parent image of the image recipe.</p>
1264    #[serde(rename = "parentImage")]
1265    #[serde(skip_serializing_if = "Option::is_none")]
1266    pub parent_image: Option<String>,
1267    /// <p>The platform of the image recipe.</p>
1268    #[serde(rename = "platform")]
1269    #[serde(skip_serializing_if = "Option::is_none")]
1270    pub platform: Option<String>,
1271    /// <p>The tags of the image recipe.</p>
1272    #[serde(rename = "tags")]
1273    #[serde(skip_serializing_if = "Option::is_none")]
1274    pub tags: Option<::std::collections::HashMap<String, String>>,
1275}
1276
1277/// <p> Image state shows the image status and the reason for that status. </p>
1278#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1279#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1280pub struct ImageState {
1281    /// <p>The reason for the image's status. </p>
1282    #[serde(rename = "reason")]
1283    #[serde(skip_serializing_if = "Option::is_none")]
1284    pub reason: Option<String>,
1285    /// <p>The status of the image. </p>
1286    #[serde(rename = "status")]
1287    #[serde(skip_serializing_if = "Option::is_none")]
1288    pub status: Option<String>,
1289}
1290
1291/// <p>An image summary.</p>
1292#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1293#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1294pub struct ImageSummary {
1295    /// <p>The Amazon Resource Name (ARN) of the image.</p>
1296    #[serde(rename = "arn")]
1297    #[serde(skip_serializing_if = "Option::is_none")]
1298    pub arn: Option<String>,
1299    /// <p>The date on which this image was created.</p>
1300    #[serde(rename = "dateCreated")]
1301    #[serde(skip_serializing_if = "Option::is_none")]
1302    pub date_created: Option<String>,
1303    /// <p>The name of the image.</p>
1304    #[serde(rename = "name")]
1305    #[serde(skip_serializing_if = "Option::is_none")]
1306    pub name: Option<String>,
1307    /// <p>The operating system version of the instance. For example, Amazon Linux 2, Ubuntu 18, or Microsoft Windows Server 2019. </p>
1308    #[serde(rename = "osVersion")]
1309    #[serde(skip_serializing_if = "Option::is_none")]
1310    pub os_version: Option<String>,
1311    /// <p>The output resources produced when creating this image.</p>
1312    #[serde(rename = "outputResources")]
1313    #[serde(skip_serializing_if = "Option::is_none")]
1314    pub output_resources: Option<OutputResources>,
1315    /// <p>The owner of the image.</p>
1316    #[serde(rename = "owner")]
1317    #[serde(skip_serializing_if = "Option::is_none")]
1318    pub owner: Option<String>,
1319    /// <p>The platform of the image.</p>
1320    #[serde(rename = "platform")]
1321    #[serde(skip_serializing_if = "Option::is_none")]
1322    pub platform: Option<String>,
1323    /// <p>The state of the image.</p>
1324    #[serde(rename = "state")]
1325    #[serde(skip_serializing_if = "Option::is_none")]
1326    pub state: Option<ImageState>,
1327    /// <p>The tags of the image.</p>
1328    #[serde(rename = "tags")]
1329    #[serde(skip_serializing_if = "Option::is_none")]
1330    pub tags: Option<::std::collections::HashMap<String, String>>,
1331    /// <p>The version of the image.</p>
1332    #[serde(rename = "version")]
1333    #[serde(skip_serializing_if = "Option::is_none")]
1334    pub version: Option<String>,
1335}
1336
1337/// <p>Image tests configuration.</p>
1338#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1339pub struct ImageTestsConfiguration {
1340    /// <p>Defines if tests should be executed when building this image.</p>
1341    #[serde(rename = "imageTestsEnabled")]
1342    #[serde(skip_serializing_if = "Option::is_none")]
1343    pub image_tests_enabled: Option<bool>,
1344    /// <p>The maximum time in minutes that tests are permitted to run.</p>
1345    #[serde(rename = "timeoutMinutes")]
1346    #[serde(skip_serializing_if = "Option::is_none")]
1347    pub timeout_minutes: Option<i64>,
1348}
1349
1350/// <p>An image semantic version.</p>
1351#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1352#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1353pub struct ImageVersion {
1354    /// <p>The Amazon Resource Name (ARN) of the image semantic version.</p>
1355    #[serde(rename = "arn")]
1356    #[serde(skip_serializing_if = "Option::is_none")]
1357    pub arn: Option<String>,
1358    /// <p>The date at which this image semantic version was created.</p>
1359    #[serde(rename = "dateCreated")]
1360    #[serde(skip_serializing_if = "Option::is_none")]
1361    pub date_created: Option<String>,
1362    /// <p>The name of the image semantic version.</p>
1363    #[serde(rename = "name")]
1364    #[serde(skip_serializing_if = "Option::is_none")]
1365    pub name: Option<String>,
1366    /// <p> The operating system version of the instance. For example, Amazon Linux 2, Ubuntu 18, or Microsoft Windows Server 2019. </p>
1367    #[serde(rename = "osVersion")]
1368    #[serde(skip_serializing_if = "Option::is_none")]
1369    pub os_version: Option<String>,
1370    /// <p>The owner of the image semantic version.</p>
1371    #[serde(rename = "owner")]
1372    #[serde(skip_serializing_if = "Option::is_none")]
1373    pub owner: Option<String>,
1374    /// <p>The platform of the image semantic version.</p>
1375    #[serde(rename = "platform")]
1376    #[serde(skip_serializing_if = "Option::is_none")]
1377    pub platform: Option<String>,
1378    /// <p>The semantic version of the image semantic version.</p>
1379    #[serde(rename = "version")]
1380    #[serde(skip_serializing_if = "Option::is_none")]
1381    pub version: Option<String>,
1382}
1383
1384#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1385#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1386pub struct ImportComponentRequest {
1387    /// <p>The change description of the component. Describes what change has been made in this version, or what makes this version different from other versions of this component. </p>
1388    #[serde(rename = "changeDescription")]
1389    #[serde(skip_serializing_if = "Option::is_none")]
1390    pub change_description: Option<String>,
1391    /// <p>The idempotency token of the component. </p>
1392    #[serde(rename = "clientToken")]
1393    pub client_token: String,
1394    /// <p>The data of the component. Used to specify the data inline. Either <code>data</code> or <code>uri</code> can be used to specify the data within the component.</p>
1395    #[serde(rename = "data")]
1396    #[serde(skip_serializing_if = "Option::is_none")]
1397    pub data: Option<String>,
1398    /// <p>The description of the component. Describes the contents of the component. </p>
1399    #[serde(rename = "description")]
1400    #[serde(skip_serializing_if = "Option::is_none")]
1401    pub description: Option<String>,
1402    /// <p>The format of the resource that you want to import as a component. </p>
1403    #[serde(rename = "format")]
1404    pub format: String,
1405    /// <p>The ID of the KMS key that should be used to encrypt this component. </p>
1406    #[serde(rename = "kmsKeyId")]
1407    #[serde(skip_serializing_if = "Option::is_none")]
1408    pub kms_key_id: Option<String>,
1409    /// <p> The name of the component. </p>
1410    #[serde(rename = "name")]
1411    pub name: String,
1412    /// <p>The platform of the component. </p>
1413    #[serde(rename = "platform")]
1414    pub platform: String,
1415    /// <p>The semantic version of the component. This version follows the semantic version syntax. For example, major.minor.patch. This could be versioned like software (2.0.1) or like a date (2019.12.01).</p>
1416    #[serde(rename = "semanticVersion")]
1417    pub semantic_version: String,
1418    /// <p>The tags of the component. </p>
1419    #[serde(rename = "tags")]
1420    #[serde(skip_serializing_if = "Option::is_none")]
1421    pub tags: Option<::std::collections::HashMap<String, String>>,
1422    /// <p>The type of the component denotes whether the component is used to build the image or only to test it. </p>
1423    #[serde(rename = "type")]
1424    pub type_: String,
1425    /// <p>The uri of the component. Must be an S3 URL and the requester must have permission to access the S3 bucket. If you use S3, you can specify component content up to your service quota. Either <code>data</code> or <code>uri</code> can be used to specify the data within the component. </p>
1426    #[serde(rename = "uri")]
1427    #[serde(skip_serializing_if = "Option::is_none")]
1428    pub uri: Option<String>,
1429}
1430
1431#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1432#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1433pub struct ImportComponentResponse {
1434    /// <p>The idempotency token used to make this request idempotent. </p>
1435    #[serde(rename = "clientToken")]
1436    #[serde(skip_serializing_if = "Option::is_none")]
1437    pub client_token: Option<String>,
1438    /// <p>The Amazon Resource Name (ARN) of the imported component. </p>
1439    #[serde(rename = "componentBuildVersionArn")]
1440    #[serde(skip_serializing_if = "Option::is_none")]
1441    pub component_build_version_arn: Option<String>,
1442    /// <p>The request ID that uniquely identifies this request. </p>
1443    #[serde(rename = "requestId")]
1444    #[serde(skip_serializing_if = "Option::is_none")]
1445    pub request_id: Option<String>,
1446}
1447
1448/// <p>Details of the infrastructure configuration.</p>
1449#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1450#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1451pub struct InfrastructureConfiguration {
1452    /// <p>The Amazon Resource Name (ARN) of the infrastructure configuration.</p>
1453    #[serde(rename = "arn")]
1454    #[serde(skip_serializing_if = "Option::is_none")]
1455    pub arn: Option<String>,
1456    /// <p>The date on which the infrastructure configuration was created.</p>
1457    #[serde(rename = "dateCreated")]
1458    #[serde(skip_serializing_if = "Option::is_none")]
1459    pub date_created: Option<String>,
1460    /// <p>The date on which the infrastructure configuration was last updated.</p>
1461    #[serde(rename = "dateUpdated")]
1462    #[serde(skip_serializing_if = "Option::is_none")]
1463    pub date_updated: Option<String>,
1464    /// <p>The description of the infrastructure configuration.</p>
1465    #[serde(rename = "description")]
1466    #[serde(skip_serializing_if = "Option::is_none")]
1467    pub description: Option<String>,
1468    /// <p>The instance profile of the infrastructure configuration.</p>
1469    #[serde(rename = "instanceProfileName")]
1470    #[serde(skip_serializing_if = "Option::is_none")]
1471    pub instance_profile_name: Option<String>,
1472    /// <p>The instance types of the infrastructure configuration.</p>
1473    #[serde(rename = "instanceTypes")]
1474    #[serde(skip_serializing_if = "Option::is_none")]
1475    pub instance_types: Option<Vec<String>>,
1476    /// <p>The EC2 key pair of the infrastructure configuration.</p>
1477    #[serde(rename = "keyPair")]
1478    #[serde(skip_serializing_if = "Option::is_none")]
1479    pub key_pair: Option<String>,
1480    /// <p>The logging configuration of the infrastructure configuration.</p>
1481    #[serde(rename = "logging")]
1482    #[serde(skip_serializing_if = "Option::is_none")]
1483    pub logging: Option<Logging>,
1484    /// <p>The name of the infrastructure configuration.</p>
1485    #[serde(rename = "name")]
1486    #[serde(skip_serializing_if = "Option::is_none")]
1487    pub name: Option<String>,
1488    /// <p>The tags attached to the resource created by Image Builder.</p>
1489    #[serde(rename = "resourceTags")]
1490    #[serde(skip_serializing_if = "Option::is_none")]
1491    pub resource_tags: Option<::std::collections::HashMap<String, String>>,
1492    /// <p>The security group IDs of the infrastructure configuration.</p>
1493    #[serde(rename = "securityGroupIds")]
1494    #[serde(skip_serializing_if = "Option::is_none")]
1495    pub security_group_ids: Option<Vec<String>>,
1496    /// <p>The SNS topic Amazon Resource Name (ARN) of the infrastructure configuration.</p>
1497    #[serde(rename = "snsTopicArn")]
1498    #[serde(skip_serializing_if = "Option::is_none")]
1499    pub sns_topic_arn: Option<String>,
1500    /// <p>The subnet ID of the infrastructure configuration.</p>
1501    #[serde(rename = "subnetId")]
1502    #[serde(skip_serializing_if = "Option::is_none")]
1503    pub subnet_id: Option<String>,
1504    /// <p>The tags of the infrastructure configuration.</p>
1505    #[serde(rename = "tags")]
1506    #[serde(skip_serializing_if = "Option::is_none")]
1507    pub tags: Option<::std::collections::HashMap<String, String>>,
1508    /// <p>The terminate instance on failure configuration of the infrastructure configuration.</p>
1509    #[serde(rename = "terminateInstanceOnFailure")]
1510    #[serde(skip_serializing_if = "Option::is_none")]
1511    pub terminate_instance_on_failure: Option<bool>,
1512}
1513
1514/// <p>The infrastructure used when building EC2 AMIs.</p>
1515#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1516#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1517pub struct InfrastructureConfigurationSummary {
1518    /// <p>The Amazon Resource Name (ARN) of the infrastructure configuration.</p>
1519    #[serde(rename = "arn")]
1520    #[serde(skip_serializing_if = "Option::is_none")]
1521    pub arn: Option<String>,
1522    /// <p>The date on which the infrastructure configuration was created.</p>
1523    #[serde(rename = "dateCreated")]
1524    #[serde(skip_serializing_if = "Option::is_none")]
1525    pub date_created: Option<String>,
1526    /// <p>The date on which the infrastructure configuration was last updated.</p>
1527    #[serde(rename = "dateUpdated")]
1528    #[serde(skip_serializing_if = "Option::is_none")]
1529    pub date_updated: Option<String>,
1530    /// <p>The description of the infrastructure configuration.</p>
1531    #[serde(rename = "description")]
1532    #[serde(skip_serializing_if = "Option::is_none")]
1533    pub description: Option<String>,
1534    /// <p>The name of the infrastructure configuration.</p>
1535    #[serde(rename = "name")]
1536    #[serde(skip_serializing_if = "Option::is_none")]
1537    pub name: Option<String>,
1538    /// <p>The tags attached to the image created by Image Builder.</p>
1539    #[serde(rename = "resourceTags")]
1540    #[serde(skip_serializing_if = "Option::is_none")]
1541    pub resource_tags: Option<::std::collections::HashMap<String, String>>,
1542    /// <p>The tags of the infrastructure configuration.</p>
1543    #[serde(rename = "tags")]
1544    #[serde(skip_serializing_if = "Option::is_none")]
1545    pub tags: Option<::std::collections::HashMap<String, String>>,
1546}
1547
1548/// <p>Defines block device mappings for the instance used to configure your image.</p>
1549#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1550pub struct InstanceBlockDeviceMapping {
1551    /// <p>The device to which these mappings apply.</p>
1552    #[serde(rename = "deviceName")]
1553    #[serde(skip_serializing_if = "Option::is_none")]
1554    pub device_name: Option<String>,
1555    /// <p>Use to manage Amazon EBS-specific configuration for this mapping.</p>
1556    #[serde(rename = "ebs")]
1557    #[serde(skip_serializing_if = "Option::is_none")]
1558    pub ebs: Option<EbsInstanceBlockDeviceSpecification>,
1559    /// <p>Use to remove a mapping from the parent image.</p>
1560    #[serde(rename = "noDevice")]
1561    #[serde(skip_serializing_if = "Option::is_none")]
1562    pub no_device: Option<String>,
1563    /// <p>Use to manage instance ephemeral devices.</p>
1564    #[serde(rename = "virtualName")]
1565    #[serde(skip_serializing_if = "Option::is_none")]
1566    pub virtual_name: Option<String>,
1567}
1568
1569/// <p>Describes the configuration for a launch permission. The launch permission modification request is sent to the <a href="https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyImageAttribute.html">EC2 ModifyImageAttribute</a> API on behalf of the user for each Region they have selected to distribute the AMI. To make an AMI public, set the launch permission authorized accounts to <code>all</code>. See the examples for making an AMI public at <a href="https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyImageAttribute.html">EC2 ModifyImageAttribute</a>. </p>
1570#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1571pub struct LaunchPermissionConfiguration {
1572    /// <p>The name of the group. </p>
1573    #[serde(rename = "userGroups")]
1574    #[serde(skip_serializing_if = "Option::is_none")]
1575    pub user_groups: Option<Vec<String>>,
1576    /// <p>The AWS account ID. </p>
1577    #[serde(rename = "userIds")]
1578    #[serde(skip_serializing_if = "Option::is_none")]
1579    pub user_ids: Option<Vec<String>>,
1580}
1581
1582#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1583#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1584pub struct ListComponentBuildVersionsRequest {
1585    /// <p>The component version Amazon Resource Name (ARN) whose versions you want to list. </p>
1586    #[serde(rename = "componentVersionArn")]
1587    pub component_version_arn: String,
1588    /// <p>The maximum items to return in a request. </p>
1589    #[serde(rename = "maxResults")]
1590    #[serde(skip_serializing_if = "Option::is_none")]
1591    pub max_results: Option<i64>,
1592    /// <p>A token to specify where to start paginating. This is the NextToken from a previously truncated response. </p>
1593    #[serde(rename = "nextToken")]
1594    #[serde(skip_serializing_if = "Option::is_none")]
1595    pub next_token: Option<String>,
1596}
1597
1598#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1599#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1600pub struct ListComponentBuildVersionsResponse {
1601    /// <p>The list of component summaries for the specified semantic version. </p>
1602    #[serde(rename = "componentSummaryList")]
1603    #[serde(skip_serializing_if = "Option::is_none")]
1604    pub component_summary_list: Option<Vec<ComponentSummary>>,
1605    /// <p>The next token used for paginated responses. When this is not empty, there are additional elements that the service has not included in this request. Use this token with the next request to retrieve additional objects. </p>
1606    #[serde(rename = "nextToken")]
1607    #[serde(skip_serializing_if = "Option::is_none")]
1608    pub next_token: Option<String>,
1609    /// <p>The request ID that uniquely identifies this request. </p>
1610    #[serde(rename = "requestId")]
1611    #[serde(skip_serializing_if = "Option::is_none")]
1612    pub request_id: Option<String>,
1613}
1614
1615#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1616#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1617pub struct ListComponentsRequest {
1618    /// <p>The filters. </p>
1619    #[serde(rename = "filters")]
1620    #[serde(skip_serializing_if = "Option::is_none")]
1621    pub filters: Option<Vec<Filter>>,
1622    /// <p>The maximum items to return in a request. </p>
1623    #[serde(rename = "maxResults")]
1624    #[serde(skip_serializing_if = "Option::is_none")]
1625    pub max_results: Option<i64>,
1626    /// <p>A token to specify where to start paginating. This is the NextToken from a previously truncated response. </p>
1627    #[serde(rename = "nextToken")]
1628    #[serde(skip_serializing_if = "Option::is_none")]
1629    pub next_token: Option<String>,
1630    /// <p>The owner defines which components you want to list. By default, this request will only show components owned by your account. You can use this field to specify if you want to view components owned by yourself, by Amazon, or those components that have been shared with you by other customers. </p>
1631    #[serde(rename = "owner")]
1632    #[serde(skip_serializing_if = "Option::is_none")]
1633    pub owner: Option<String>,
1634}
1635
1636#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1637#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1638pub struct ListComponentsResponse {
1639    /// <p>The list of component semantic versions. </p>
1640    #[serde(rename = "componentVersionList")]
1641    #[serde(skip_serializing_if = "Option::is_none")]
1642    pub component_version_list: Option<Vec<ComponentVersion>>,
1643    /// <p>The next token used for paginated responses. When this is not empty, there are additional elements that the service has not included in this request. Use this token with the next request to retrieve additional objects. </p>
1644    #[serde(rename = "nextToken")]
1645    #[serde(skip_serializing_if = "Option::is_none")]
1646    pub next_token: Option<String>,
1647    /// <p>The request ID that uniquely identifies this request. </p>
1648    #[serde(rename = "requestId")]
1649    #[serde(skip_serializing_if = "Option::is_none")]
1650    pub request_id: Option<String>,
1651}
1652
1653#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1654#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1655pub struct ListDistributionConfigurationsRequest {
1656    /// <p>The filters. </p>
1657    #[serde(rename = "filters")]
1658    #[serde(skip_serializing_if = "Option::is_none")]
1659    pub filters: Option<Vec<Filter>>,
1660    /// <p>The maximum items to return in a request. </p>
1661    #[serde(rename = "maxResults")]
1662    #[serde(skip_serializing_if = "Option::is_none")]
1663    pub max_results: Option<i64>,
1664    /// <p>A token to specify where to start paginating. This is the NextToken from a previously truncated response. </p>
1665    #[serde(rename = "nextToken")]
1666    #[serde(skip_serializing_if = "Option::is_none")]
1667    pub next_token: Option<String>,
1668}
1669
1670#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1671#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1672pub struct ListDistributionConfigurationsResponse {
1673    /// <p>The list of distributions. </p>
1674    #[serde(rename = "distributionConfigurationSummaryList")]
1675    #[serde(skip_serializing_if = "Option::is_none")]
1676    pub distribution_configuration_summary_list: Option<Vec<DistributionConfigurationSummary>>,
1677    /// <p>The next token used for paginated responses. When this is not empty, there are additional elements that the service has not included in this request. Use this token with the next request to retrieve additional objects. </p>
1678    #[serde(rename = "nextToken")]
1679    #[serde(skip_serializing_if = "Option::is_none")]
1680    pub next_token: Option<String>,
1681    /// <p>The request ID that uniquely identifies this request. </p>
1682    #[serde(rename = "requestId")]
1683    #[serde(skip_serializing_if = "Option::is_none")]
1684    pub request_id: Option<String>,
1685}
1686
1687#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1688#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1689pub struct ListImageBuildVersionsRequest {
1690    /// <p>The filters. </p>
1691    #[serde(rename = "filters")]
1692    #[serde(skip_serializing_if = "Option::is_none")]
1693    pub filters: Option<Vec<Filter>>,
1694    /// <p>The Amazon Resource Name (ARN) of the image whose build versions you want to retrieve. </p>
1695    #[serde(rename = "imageVersionArn")]
1696    pub image_version_arn: String,
1697    /// <p>The maximum items to return in a request. </p>
1698    #[serde(rename = "maxResults")]
1699    #[serde(skip_serializing_if = "Option::is_none")]
1700    pub max_results: Option<i64>,
1701    /// <p>A token to specify where to start paginating. This is the NextToken from a previously truncated response. </p>
1702    #[serde(rename = "nextToken")]
1703    #[serde(skip_serializing_if = "Option::is_none")]
1704    pub next_token: Option<String>,
1705}
1706
1707#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1708#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1709pub struct ListImageBuildVersionsResponse {
1710    /// <p>The list of image build versions. </p>
1711    #[serde(rename = "imageSummaryList")]
1712    #[serde(skip_serializing_if = "Option::is_none")]
1713    pub image_summary_list: Option<Vec<ImageSummary>>,
1714    /// <p>The next token used for paginated responses. When this is not empty, there are additional elements that the service has not included in this request. Use this token with the next request to retrieve additional objects. </p>
1715    #[serde(rename = "nextToken")]
1716    #[serde(skip_serializing_if = "Option::is_none")]
1717    pub next_token: Option<String>,
1718    /// <p>The request ID that uniquely identifies this request. </p>
1719    #[serde(rename = "requestId")]
1720    #[serde(skip_serializing_if = "Option::is_none")]
1721    pub request_id: Option<String>,
1722}
1723
1724#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1725#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1726pub struct ListImagePipelineImagesRequest {
1727    /// <p>The filters. </p>
1728    #[serde(rename = "filters")]
1729    #[serde(skip_serializing_if = "Option::is_none")]
1730    pub filters: Option<Vec<Filter>>,
1731    /// <p>The Amazon Resource Name (ARN) of the image pipeline whose images you want to view. </p>
1732    #[serde(rename = "imagePipelineArn")]
1733    pub image_pipeline_arn: String,
1734    /// <p>The maximum items to return in a request. </p>
1735    #[serde(rename = "maxResults")]
1736    #[serde(skip_serializing_if = "Option::is_none")]
1737    pub max_results: Option<i64>,
1738    /// <p>A token to specify where to start paginating. This is the NextToken from a previously truncated response. </p>
1739    #[serde(rename = "nextToken")]
1740    #[serde(skip_serializing_if = "Option::is_none")]
1741    pub next_token: Option<String>,
1742}
1743
1744#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1745#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1746pub struct ListImagePipelineImagesResponse {
1747    /// <p>The list of images built by this pipeline. </p>
1748    #[serde(rename = "imageSummaryList")]
1749    #[serde(skip_serializing_if = "Option::is_none")]
1750    pub image_summary_list: Option<Vec<ImageSummary>>,
1751    /// <p>The next token used for paginated responses. When this is not empty, there are additional elements that the service has not included in this request. Use this token with the next request to retrieve additional objects. </p>
1752    #[serde(rename = "nextToken")]
1753    #[serde(skip_serializing_if = "Option::is_none")]
1754    pub next_token: Option<String>,
1755    /// <p>The request ID that uniquely identifies this request. </p>
1756    #[serde(rename = "requestId")]
1757    #[serde(skip_serializing_if = "Option::is_none")]
1758    pub request_id: Option<String>,
1759}
1760
1761#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1762#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1763pub struct ListImagePipelinesRequest {
1764    /// <p>The filters. </p>
1765    #[serde(rename = "filters")]
1766    #[serde(skip_serializing_if = "Option::is_none")]
1767    pub filters: Option<Vec<Filter>>,
1768    /// <p>The maximum items to return in a request. </p>
1769    #[serde(rename = "maxResults")]
1770    #[serde(skip_serializing_if = "Option::is_none")]
1771    pub max_results: Option<i64>,
1772    /// <p>A token to specify where to start paginating. This is the NextToken from a previously truncated response. </p>
1773    #[serde(rename = "nextToken")]
1774    #[serde(skip_serializing_if = "Option::is_none")]
1775    pub next_token: Option<String>,
1776}
1777
1778#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1779#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1780pub struct ListImagePipelinesResponse {
1781    /// <p>The list of image pipelines. </p>
1782    #[serde(rename = "imagePipelineList")]
1783    #[serde(skip_serializing_if = "Option::is_none")]
1784    pub image_pipeline_list: Option<Vec<ImagePipeline>>,
1785    /// <p>The next token used for paginated responses. When this is not empty, there are additional elements that the service has not included in this request. Use this token with the next request to retrieve additional objects. </p>
1786    #[serde(rename = "nextToken")]
1787    #[serde(skip_serializing_if = "Option::is_none")]
1788    pub next_token: Option<String>,
1789    /// <p>The request ID that uniquely identifies this request. </p>
1790    #[serde(rename = "requestId")]
1791    #[serde(skip_serializing_if = "Option::is_none")]
1792    pub request_id: Option<String>,
1793}
1794
1795#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1796#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1797pub struct ListImageRecipesRequest {
1798    /// <p>The filters. </p>
1799    #[serde(rename = "filters")]
1800    #[serde(skip_serializing_if = "Option::is_none")]
1801    pub filters: Option<Vec<Filter>>,
1802    /// <p>The maximum items to return in a request. </p>
1803    #[serde(rename = "maxResults")]
1804    #[serde(skip_serializing_if = "Option::is_none")]
1805    pub max_results: Option<i64>,
1806    /// <p>A token to specify where to start paginating. This is the NextToken from a previously truncated response. </p>
1807    #[serde(rename = "nextToken")]
1808    #[serde(skip_serializing_if = "Option::is_none")]
1809    pub next_token: Option<String>,
1810    /// <p>The owner defines which image recipes you want to list. By default, this request will only show image recipes owned by your account. You can use this field to specify if you want to view image recipes owned by yourself, by Amazon, or those image recipes that have been shared with you by other customers. </p>
1811    #[serde(rename = "owner")]
1812    #[serde(skip_serializing_if = "Option::is_none")]
1813    pub owner: Option<String>,
1814}
1815
1816#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1817#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1818pub struct ListImageRecipesResponse {
1819    /// <p>The list of image pipelines. </p>
1820    #[serde(rename = "imageRecipeSummaryList")]
1821    #[serde(skip_serializing_if = "Option::is_none")]
1822    pub image_recipe_summary_list: Option<Vec<ImageRecipeSummary>>,
1823    /// <p>The next token used for paginated responses. When this is not empty, there are additional elements that the service has not included in this request. Use this token with the next request to retrieve additional objects. </p>
1824    #[serde(rename = "nextToken")]
1825    #[serde(skip_serializing_if = "Option::is_none")]
1826    pub next_token: Option<String>,
1827    /// <p>The request ID that uniquely identifies this request. </p>
1828    #[serde(rename = "requestId")]
1829    #[serde(skip_serializing_if = "Option::is_none")]
1830    pub request_id: Option<String>,
1831}
1832
1833#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1834#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1835pub struct ListImagesRequest {
1836    /// <p>The filters. </p>
1837    #[serde(rename = "filters")]
1838    #[serde(skip_serializing_if = "Option::is_none")]
1839    pub filters: Option<Vec<Filter>>,
1840    /// <p>The maximum items to return in a request. </p>
1841    #[serde(rename = "maxResults")]
1842    #[serde(skip_serializing_if = "Option::is_none")]
1843    pub max_results: Option<i64>,
1844    /// <p>A token to specify where to start paginating. This is the NextToken from a previously truncated response. </p>
1845    #[serde(rename = "nextToken")]
1846    #[serde(skip_serializing_if = "Option::is_none")]
1847    pub next_token: Option<String>,
1848    /// <p>The owner defines which images you want to list. By default, this request will only show images owned by your account. You can use this field to specify if you want to view images owned by yourself, by Amazon, or those images that have been shared with you by other customers. </p>
1849    #[serde(rename = "owner")]
1850    #[serde(skip_serializing_if = "Option::is_none")]
1851    pub owner: Option<String>,
1852}
1853
1854#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1855#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1856pub struct ListImagesResponse {
1857    /// <p>The list of image semantic versions. </p>
1858    #[serde(rename = "imageVersionList")]
1859    #[serde(skip_serializing_if = "Option::is_none")]
1860    pub image_version_list: Option<Vec<ImageVersion>>,
1861    /// <p>The next token used for paginated responses. When this is not empty, there are additional elements that the service has not included in this request. Use this token with the next request to retrieve additional objects. </p>
1862    #[serde(rename = "nextToken")]
1863    #[serde(skip_serializing_if = "Option::is_none")]
1864    pub next_token: Option<String>,
1865    /// <p>The request ID that uniquely identifies this request. </p>
1866    #[serde(rename = "requestId")]
1867    #[serde(skip_serializing_if = "Option::is_none")]
1868    pub request_id: Option<String>,
1869}
1870
1871#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1872#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1873pub struct ListInfrastructureConfigurationsRequest {
1874    /// <p>The filters. </p>
1875    #[serde(rename = "filters")]
1876    #[serde(skip_serializing_if = "Option::is_none")]
1877    pub filters: Option<Vec<Filter>>,
1878    /// <p>The maximum items to return in a request. </p>
1879    #[serde(rename = "maxResults")]
1880    #[serde(skip_serializing_if = "Option::is_none")]
1881    pub max_results: Option<i64>,
1882    /// <p>A token to specify where to start paginating. This is the NextToken from a previously truncated response. </p>
1883    #[serde(rename = "nextToken")]
1884    #[serde(skip_serializing_if = "Option::is_none")]
1885    pub next_token: Option<String>,
1886}
1887
1888#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1889#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1890pub struct ListInfrastructureConfigurationsResponse {
1891    /// <p>The list of infrastructure configurations. </p>
1892    #[serde(rename = "infrastructureConfigurationSummaryList")]
1893    #[serde(skip_serializing_if = "Option::is_none")]
1894    pub infrastructure_configuration_summary_list: Option<Vec<InfrastructureConfigurationSummary>>,
1895    /// <p>The next token used for paginated responses. When this is not empty, there are additional elements that the service has not included in this request. Use this token with the next request to retrieve additional objects.</p>
1896    #[serde(rename = "nextToken")]
1897    #[serde(skip_serializing_if = "Option::is_none")]
1898    pub next_token: Option<String>,
1899    /// <p>The request ID that uniquely identifies this request. </p>
1900    #[serde(rename = "requestId")]
1901    #[serde(skip_serializing_if = "Option::is_none")]
1902    pub request_id: Option<String>,
1903}
1904
1905#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1906#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1907pub struct ListTagsForResourceRequest {
1908    /// <p>The Amazon Resource Name (ARN) of the resource whose tags you want to retrieve. </p>
1909    #[serde(rename = "resourceArn")]
1910    pub resource_arn: String,
1911}
1912
1913#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1914#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1915pub struct ListTagsForResourceResponse {
1916    /// <p>The tags for the specified resource. </p>
1917    #[serde(rename = "tags")]
1918    #[serde(skip_serializing_if = "Option::is_none")]
1919    pub tags: Option<::std::collections::HashMap<String, String>>,
1920}
1921
1922/// <p>Logging configuration defines where Image Builder uploads your logs.</p>
1923#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1924pub struct Logging {
1925    /// <p>The Amazon S3 logging configuration.</p>
1926    #[serde(rename = "s3Logs")]
1927    #[serde(skip_serializing_if = "Option::is_none")]
1928    pub s_3_logs: Option<S3Logs>,
1929}
1930
1931/// <p>The resources produced by this image. </p>
1932#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1933#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1934pub struct OutputResources {
1935    /// <p>The EC2 AMIs created by this image. </p>
1936    #[serde(rename = "amis")]
1937    #[serde(skip_serializing_if = "Option::is_none")]
1938    pub amis: Option<Vec<Ami>>,
1939}
1940
1941#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1942#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1943pub struct PutComponentPolicyRequest {
1944    /// <p>The Amazon Resource Name (ARN) of the component that this policy should be applied to. </p>
1945    #[serde(rename = "componentArn")]
1946    pub component_arn: String,
1947    /// <p>The policy to apply. </p>
1948    #[serde(rename = "policy")]
1949    pub policy: String,
1950}
1951
1952#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1953#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1954pub struct PutComponentPolicyResponse {
1955    /// <p>The Amazon Resource Name (ARN) of the component that this policy was applied to. </p>
1956    #[serde(rename = "componentArn")]
1957    #[serde(skip_serializing_if = "Option::is_none")]
1958    pub component_arn: Option<String>,
1959    /// <p>The request ID that uniquely identifies this request. </p>
1960    #[serde(rename = "requestId")]
1961    #[serde(skip_serializing_if = "Option::is_none")]
1962    pub request_id: Option<String>,
1963}
1964
1965#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1966#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1967pub struct PutImagePolicyRequest {
1968    /// <p>The Amazon Resource Name (ARN) of the image that this policy should be applied to. </p>
1969    #[serde(rename = "imageArn")]
1970    pub image_arn: String,
1971    /// <p>The policy to apply. </p>
1972    #[serde(rename = "policy")]
1973    pub policy: String,
1974}
1975
1976#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1977#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1978pub struct PutImagePolicyResponse {
1979    /// <p>The Amazon Resource Name (ARN) of the image that this policy was applied to. </p>
1980    #[serde(rename = "imageArn")]
1981    #[serde(skip_serializing_if = "Option::is_none")]
1982    pub image_arn: Option<String>,
1983    /// <p>The request ID that uniquely identifies this request. </p>
1984    #[serde(rename = "requestId")]
1985    #[serde(skip_serializing_if = "Option::is_none")]
1986    pub request_id: Option<String>,
1987}
1988
1989#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1990#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1991pub struct PutImageRecipePolicyRequest {
1992    /// <p>The Amazon Resource Name (ARN) of the image recipe that this policy should be applied to. </p>
1993    #[serde(rename = "imageRecipeArn")]
1994    pub image_recipe_arn: String,
1995    /// <p>The policy to apply. </p>
1996    #[serde(rename = "policy")]
1997    pub policy: String,
1998}
1999
2000#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2001#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2002pub struct PutImageRecipePolicyResponse {
2003    /// <p>The Amazon Resource Name (ARN) of the image recipe that this policy was applied to. </p>
2004    #[serde(rename = "imageRecipeArn")]
2005    #[serde(skip_serializing_if = "Option::is_none")]
2006    pub image_recipe_arn: Option<String>,
2007    /// <p>The request ID that uniquely identifies this request. </p>
2008    #[serde(rename = "requestId")]
2009    #[serde(skip_serializing_if = "Option::is_none")]
2010    pub request_id: Option<String>,
2011}
2012
2013/// <p>Amazon S3 logging configuration.</p>
2014#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2015pub struct S3Logs {
2016    /// <p>The Amazon S3 bucket in which to store the logs.</p>
2017    #[serde(rename = "s3BucketName")]
2018    #[serde(skip_serializing_if = "Option::is_none")]
2019    pub s_3_bucket_name: Option<String>,
2020    /// <p>The Amazon S3 path in which to store the logs.</p>
2021    #[serde(rename = "s3KeyPrefix")]
2022    #[serde(skip_serializing_if = "Option::is_none")]
2023    pub s_3_key_prefix: Option<String>,
2024}
2025
2026/// <p>A schedule configures how often and when a pipeline will automatically create a new image. </p>
2027#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2028pub struct Schedule {
2029    /// <p>The condition configures when the pipeline should trigger a new image build. When the <code>pipelineExecutionStartCondition</code> is set to <code>EXPRESSION_MATCH_AND_DEPENDENCY_UPDATES_AVAILABLE</code>, EC2 Image Builder will build a new image only when there are known changes pending. When it is set to <code>EXPRESSION_MATCH_ONLY</code>, it will build a new image every time the CRON expression matches the current time.</p>
2030    #[serde(rename = "pipelineExecutionStartCondition")]
2031    #[serde(skip_serializing_if = "Option::is_none")]
2032    pub pipeline_execution_start_condition: Option<String>,
2033    /// <p>The expression determines how often EC2 Image Builder evaluates your <code>pipelineExecutionStartCondition</code>.</p>
2034    #[serde(rename = "scheduleExpression")]
2035    #[serde(skip_serializing_if = "Option::is_none")]
2036    pub schedule_expression: Option<String>,
2037}
2038
2039#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2040#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2041pub struct StartImagePipelineExecutionRequest {
2042    /// <p>The idempotency token used to make this request idempotent. </p>
2043    #[serde(rename = "clientToken")]
2044    pub client_token: String,
2045    /// <p>The Amazon Resource Name (ARN) of the image pipeline that you want to manually invoke. </p>
2046    #[serde(rename = "imagePipelineArn")]
2047    pub image_pipeline_arn: String,
2048}
2049
2050#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2051#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2052pub struct StartImagePipelineExecutionResponse {
2053    /// <p>The idempotency token used to make this request idempotent.</p>
2054    #[serde(rename = "clientToken")]
2055    #[serde(skip_serializing_if = "Option::is_none")]
2056    pub client_token: Option<String>,
2057    /// <p>The Amazon Resource Name (ARN) of the image that was created by this request.</p>
2058    #[serde(rename = "imageBuildVersionArn")]
2059    #[serde(skip_serializing_if = "Option::is_none")]
2060    pub image_build_version_arn: Option<String>,
2061    /// <p>The request ID that uniquely identifies this request. </p>
2062    #[serde(rename = "requestId")]
2063    #[serde(skip_serializing_if = "Option::is_none")]
2064    pub request_id: Option<String>,
2065}
2066
2067#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2068#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2069pub struct TagResourceRequest {
2070    /// <p>The Amazon Resource Name (ARN) of the resource that you want to tag. </p>
2071    #[serde(rename = "resourceArn")]
2072    pub resource_arn: String,
2073    /// <p>The tags to apply to the resource. </p>
2074    #[serde(rename = "tags")]
2075    pub tags: ::std::collections::HashMap<String, String>,
2076}
2077
2078#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2079#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2080pub struct TagResourceResponse {}
2081
2082#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2083#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2084pub struct UntagResourceRequest {
2085    /// <p>The Amazon Resource Name (ARN) of the resource that you want to untag. </p>
2086    #[serde(rename = "resourceArn")]
2087    pub resource_arn: String,
2088    /// <p>The tag keys to remove from the resource. </p>
2089    #[serde(rename = "tagKeys")]
2090    pub tag_keys: Vec<String>,
2091}
2092
2093#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2094#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2095pub struct UntagResourceResponse {}
2096
2097#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2098#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2099pub struct UpdateDistributionConfigurationRequest {
2100    /// <p>The idempotency token of the distribution configuration. </p>
2101    #[serde(rename = "clientToken")]
2102    pub client_token: String,
2103    /// <p>The description of the distribution configuration. </p>
2104    #[serde(rename = "description")]
2105    #[serde(skip_serializing_if = "Option::is_none")]
2106    pub description: Option<String>,
2107    /// <p>The Amazon Resource Name (ARN) of the distribution configuration that you want to update. </p>
2108    #[serde(rename = "distributionConfigurationArn")]
2109    pub distribution_configuration_arn: String,
2110    /// <p>The distributions of the distribution configuration. </p>
2111    #[serde(rename = "distributions")]
2112    pub distributions: Vec<Distribution>,
2113}
2114
2115#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2116#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2117pub struct UpdateDistributionConfigurationResponse {
2118    /// <p>The idempotency token used to make this request idempotent. </p>
2119    #[serde(rename = "clientToken")]
2120    #[serde(skip_serializing_if = "Option::is_none")]
2121    pub client_token: Option<String>,
2122    /// <p>The Amazon Resource Name (ARN) of the distribution configuration that was updated by this request. </p>
2123    #[serde(rename = "distributionConfigurationArn")]
2124    #[serde(skip_serializing_if = "Option::is_none")]
2125    pub distribution_configuration_arn: Option<String>,
2126    /// <p>The request ID that uniquely identifies this request. </p>
2127    #[serde(rename = "requestId")]
2128    #[serde(skip_serializing_if = "Option::is_none")]
2129    pub request_id: Option<String>,
2130}
2131
2132#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2133#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2134pub struct UpdateImagePipelineRequest {
2135    /// <p>The idempotency token used to make this request idempotent. </p>
2136    #[serde(rename = "clientToken")]
2137    pub client_token: String,
2138    /// <p>The description of the image pipeline. </p>
2139    #[serde(rename = "description")]
2140    #[serde(skip_serializing_if = "Option::is_none")]
2141    pub description: Option<String>,
2142    /// <p>The Amazon Resource Name (ARN) of the distribution configuration that will be used to configure and distribute images updated by this image pipeline. </p>
2143    #[serde(rename = "distributionConfigurationArn")]
2144    #[serde(skip_serializing_if = "Option::is_none")]
2145    pub distribution_configuration_arn: Option<String>,
2146    /// <p> Collects additional information about the image being created, including the operating system (OS) version and package list. This information is used to enhance the overall experience of using EC2 Image Builder. Enabled by default. </p>
2147    #[serde(rename = "enhancedImageMetadataEnabled")]
2148    #[serde(skip_serializing_if = "Option::is_none")]
2149    pub enhanced_image_metadata_enabled: Option<bool>,
2150    /// <p>The Amazon Resource Name (ARN) of the image pipeline that you want to update. </p>
2151    #[serde(rename = "imagePipelineArn")]
2152    pub image_pipeline_arn: String,
2153    /// <p>The Amazon Resource Name (ARN) of the image recipe that will be used to configure images updated by this image pipeline. </p>
2154    #[serde(rename = "imageRecipeArn")]
2155    pub image_recipe_arn: String,
2156    /// <p>The image test configuration of the image pipeline. </p>
2157    #[serde(rename = "imageTestsConfiguration")]
2158    #[serde(skip_serializing_if = "Option::is_none")]
2159    pub image_tests_configuration: Option<ImageTestsConfiguration>,
2160    /// <p>The Amazon Resource Name (ARN) of the infrastructure configuration that will be used to build images updated by this image pipeline. </p>
2161    #[serde(rename = "infrastructureConfigurationArn")]
2162    pub infrastructure_configuration_arn: String,
2163    /// <p>The schedule of the image pipeline. </p>
2164    #[serde(rename = "schedule")]
2165    #[serde(skip_serializing_if = "Option::is_none")]
2166    pub schedule: Option<Schedule>,
2167    /// <p>The status of the image pipeline. </p>
2168    #[serde(rename = "status")]
2169    #[serde(skip_serializing_if = "Option::is_none")]
2170    pub status: Option<String>,
2171}
2172
2173#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2174#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2175pub struct UpdateImagePipelineResponse {
2176    /// <p>The idempotency token used to make this request idempotent. </p>
2177    #[serde(rename = "clientToken")]
2178    #[serde(skip_serializing_if = "Option::is_none")]
2179    pub client_token: Option<String>,
2180    /// <p>The Amazon Resource Name (ARN) of the image pipeline that was updated by this request. </p>
2181    #[serde(rename = "imagePipelineArn")]
2182    #[serde(skip_serializing_if = "Option::is_none")]
2183    pub image_pipeline_arn: Option<String>,
2184    /// <p>The request ID that uniquely identifies this request. </p>
2185    #[serde(rename = "requestId")]
2186    #[serde(skip_serializing_if = "Option::is_none")]
2187    pub request_id: Option<String>,
2188}
2189
2190#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2191#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2192pub struct UpdateInfrastructureConfigurationRequest {
2193    /// <p>The idempotency token used to make this request idempotent. </p>
2194    #[serde(rename = "clientToken")]
2195    pub client_token: String,
2196    /// <p>The description of the infrastructure configuration. </p>
2197    #[serde(rename = "description")]
2198    #[serde(skip_serializing_if = "Option::is_none")]
2199    pub description: Option<String>,
2200    /// <p>The Amazon Resource Name (ARN) of the infrastructure configuration that you want to update. </p>
2201    #[serde(rename = "infrastructureConfigurationArn")]
2202    pub infrastructure_configuration_arn: String,
2203    /// <p>The instance profile to associate with the instance used to customize your EC2 AMI. </p>
2204    #[serde(rename = "instanceProfileName")]
2205    pub instance_profile_name: String,
2206    /// <p>The instance types of the infrastructure configuration. You can specify one or more instance types to use for this build. The service will pick one of these instance types based on availability. </p>
2207    #[serde(rename = "instanceTypes")]
2208    #[serde(skip_serializing_if = "Option::is_none")]
2209    pub instance_types: Option<Vec<String>>,
2210    /// <p>The key pair of the infrastructure configuration. This can be used to log on to and debug the instance used to create your image. </p>
2211    #[serde(rename = "keyPair")]
2212    #[serde(skip_serializing_if = "Option::is_none")]
2213    pub key_pair: Option<String>,
2214    /// <p>The logging configuration of the infrastructure configuration. </p>
2215    #[serde(rename = "logging")]
2216    #[serde(skip_serializing_if = "Option::is_none")]
2217    pub logging: Option<Logging>,
2218    /// <p>The tags attached to the resource created by Image Builder.</p>
2219    #[serde(rename = "resourceTags")]
2220    #[serde(skip_serializing_if = "Option::is_none")]
2221    pub resource_tags: Option<::std::collections::HashMap<String, String>>,
2222    /// <p>The security group IDs to associate with the instance used to customize your EC2 AMI. </p>
2223    #[serde(rename = "securityGroupIds")]
2224    #[serde(skip_serializing_if = "Option::is_none")]
2225    pub security_group_ids: Option<Vec<String>>,
2226    /// <p>The SNS topic on which to send image build events. </p>
2227    #[serde(rename = "snsTopicArn")]
2228    #[serde(skip_serializing_if = "Option::is_none")]
2229    pub sns_topic_arn: Option<String>,
2230    /// <p>The subnet ID to place the instance used to customize your EC2 AMI in. </p>
2231    #[serde(rename = "subnetId")]
2232    #[serde(skip_serializing_if = "Option::is_none")]
2233    pub subnet_id: Option<String>,
2234    /// <p>The terminate instance on failure setting of the infrastructure configuration. Set to false if you want Image Builder to retain the instance used to configure your AMI if the build or test phase of your workflow fails. </p>
2235    #[serde(rename = "terminateInstanceOnFailure")]
2236    #[serde(skip_serializing_if = "Option::is_none")]
2237    pub terminate_instance_on_failure: Option<bool>,
2238}
2239
2240#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2241#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2242pub struct UpdateInfrastructureConfigurationResponse {
2243    /// <p>The idempotency token used to make this request idempotent. </p>
2244    #[serde(rename = "clientToken")]
2245    #[serde(skip_serializing_if = "Option::is_none")]
2246    pub client_token: Option<String>,
2247    /// <p>The Amazon Resource Name (ARN) of the infrastructure configuration that was updated by this request. </p>
2248    #[serde(rename = "infrastructureConfigurationArn")]
2249    #[serde(skip_serializing_if = "Option::is_none")]
2250    pub infrastructure_configuration_arn: Option<String>,
2251    /// <p>The request ID that uniquely identifies this request. </p>
2252    #[serde(rename = "requestId")]
2253    #[serde(skip_serializing_if = "Option::is_none")]
2254    pub request_id: Option<String>,
2255}
2256
2257/// Errors returned by CancelImageCreation
2258#[derive(Debug, PartialEq)]
2259pub enum CancelImageCreationError {
2260    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
2261    CallRateLimitExceeded(String),
2262    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
2263    Client(String),
2264    /// <p>You are not authorized to perform the requested operation.</p>
2265    Forbidden(String),
2266    /// <p>You have specified a client token for an operation using parameter values that differ from a previous request that used the same client token.</p>
2267    IdempotentParameterMismatch(String),
2268    /// <p>You have made a request for an action that is not supported by the service.</p>
2269    InvalidRequest(String),
2270    /// <p>The resource that you are trying to operate on is currently in use. Review the message details and retry later.</p>
2271    ResourceInUse(String),
2272    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
2273    Service(String),
2274    /// <p>The service is unable to process your request at this time.</p>
2275    ServiceUnavailable(String),
2276}
2277
2278impl CancelImageCreationError {
2279    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CancelImageCreationError> {
2280        if let Some(err) = proto::json::Error::parse_rest(&res) {
2281            match err.typ.as_str() {
2282                "CallRateLimitExceededException" => {
2283                    return RusotoError::Service(CancelImageCreationError::CallRateLimitExceeded(
2284                        err.msg,
2285                    ))
2286                }
2287                "ClientException" => {
2288                    return RusotoError::Service(CancelImageCreationError::Client(err.msg))
2289                }
2290                "ForbiddenException" => {
2291                    return RusotoError::Service(CancelImageCreationError::Forbidden(err.msg))
2292                }
2293                "IdempotentParameterMismatchException" => {
2294                    return RusotoError::Service(
2295                        CancelImageCreationError::IdempotentParameterMismatch(err.msg),
2296                    )
2297                }
2298                "InvalidRequestException" => {
2299                    return RusotoError::Service(CancelImageCreationError::InvalidRequest(err.msg))
2300                }
2301                "ResourceInUseException" => {
2302                    return RusotoError::Service(CancelImageCreationError::ResourceInUse(err.msg))
2303                }
2304                "ServiceException" => {
2305                    return RusotoError::Service(CancelImageCreationError::Service(err.msg))
2306                }
2307                "ServiceUnavailableException" => {
2308                    return RusotoError::Service(CancelImageCreationError::ServiceUnavailable(
2309                        err.msg,
2310                    ))
2311                }
2312                "ValidationException" => return RusotoError::Validation(err.msg),
2313                _ => {}
2314            }
2315        }
2316        RusotoError::Unknown(res)
2317    }
2318}
2319impl fmt::Display for CancelImageCreationError {
2320    #[allow(unused_variables)]
2321    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2322        match *self {
2323            CancelImageCreationError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
2324            CancelImageCreationError::Client(ref cause) => write!(f, "{}", cause),
2325            CancelImageCreationError::Forbidden(ref cause) => write!(f, "{}", cause),
2326            CancelImageCreationError::IdempotentParameterMismatch(ref cause) => {
2327                write!(f, "{}", cause)
2328            }
2329            CancelImageCreationError::InvalidRequest(ref cause) => write!(f, "{}", cause),
2330            CancelImageCreationError::ResourceInUse(ref cause) => write!(f, "{}", cause),
2331            CancelImageCreationError::Service(ref cause) => write!(f, "{}", cause),
2332            CancelImageCreationError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
2333        }
2334    }
2335}
2336impl Error for CancelImageCreationError {}
2337/// Errors returned by CreateComponent
2338#[derive(Debug, PartialEq)]
2339pub enum CreateComponentError {
2340    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
2341    CallRateLimitExceeded(String),
2342    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
2343    Client(String),
2344    /// <p>You are not authorized to perform the requested operation.</p>
2345    Forbidden(String),
2346    /// <p>You have specified a client token for an operation using parameter values that differ from a previous request that used the same client token.</p>
2347    IdempotentParameterMismatch(String),
2348    /// <p>You have specified two or more mutually exclusive parameters. Review the error message for details.</p>
2349    InvalidParameterCombination(String),
2350    /// <p>You have made a request for an action that is not supported by the service.</p>
2351    InvalidRequest(String),
2352    /// <p>Your version number is out of bounds or does not follow the required syntax.</p>
2353    InvalidVersionNumber(String),
2354    /// <p>The resource that you are trying to operate on is currently in use. Review the message details and retry later.</p>
2355    ResourceInUse(String),
2356    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
2357    Service(String),
2358    /// <p>You have exceeded the number of permitted resources or operations for this service. For service quotas, see <a href="https://docs.aws.amazon.com/general/latest/gr/imagebuilder.html#limits_imagebuilder">EC2 Image Builder endpoints and quotas</a>.</p>
2359    ServiceQuotaExceeded(String),
2360    /// <p>The service is unable to process your request at this time.</p>
2361    ServiceUnavailable(String),
2362}
2363
2364impl CreateComponentError {
2365    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreateComponentError> {
2366        if let Some(err) = proto::json::Error::parse_rest(&res) {
2367            match err.typ.as_str() {
2368                "CallRateLimitExceededException" => {
2369                    return RusotoError::Service(CreateComponentError::CallRateLimitExceeded(
2370                        err.msg,
2371                    ))
2372                }
2373                "ClientException" => {
2374                    return RusotoError::Service(CreateComponentError::Client(err.msg))
2375                }
2376                "ForbiddenException" => {
2377                    return RusotoError::Service(CreateComponentError::Forbidden(err.msg))
2378                }
2379                "IdempotentParameterMismatchException" => {
2380                    return RusotoError::Service(CreateComponentError::IdempotentParameterMismatch(
2381                        err.msg,
2382                    ))
2383                }
2384                "InvalidParameterCombinationException" => {
2385                    return RusotoError::Service(CreateComponentError::InvalidParameterCombination(
2386                        err.msg,
2387                    ))
2388                }
2389                "InvalidRequestException" => {
2390                    return RusotoError::Service(CreateComponentError::InvalidRequest(err.msg))
2391                }
2392                "InvalidVersionNumberException" => {
2393                    return RusotoError::Service(CreateComponentError::InvalidVersionNumber(
2394                        err.msg,
2395                    ))
2396                }
2397                "ResourceInUseException" => {
2398                    return RusotoError::Service(CreateComponentError::ResourceInUse(err.msg))
2399                }
2400                "ServiceException" => {
2401                    return RusotoError::Service(CreateComponentError::Service(err.msg))
2402                }
2403                "ServiceQuotaExceededException" => {
2404                    return RusotoError::Service(CreateComponentError::ServiceQuotaExceeded(
2405                        err.msg,
2406                    ))
2407                }
2408                "ServiceUnavailableException" => {
2409                    return RusotoError::Service(CreateComponentError::ServiceUnavailable(err.msg))
2410                }
2411                "ValidationException" => return RusotoError::Validation(err.msg),
2412                _ => {}
2413            }
2414        }
2415        RusotoError::Unknown(res)
2416    }
2417}
2418impl fmt::Display for CreateComponentError {
2419    #[allow(unused_variables)]
2420    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2421        match *self {
2422            CreateComponentError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
2423            CreateComponentError::Client(ref cause) => write!(f, "{}", cause),
2424            CreateComponentError::Forbidden(ref cause) => write!(f, "{}", cause),
2425            CreateComponentError::IdempotentParameterMismatch(ref cause) => write!(f, "{}", cause),
2426            CreateComponentError::InvalidParameterCombination(ref cause) => write!(f, "{}", cause),
2427            CreateComponentError::InvalidRequest(ref cause) => write!(f, "{}", cause),
2428            CreateComponentError::InvalidVersionNumber(ref cause) => write!(f, "{}", cause),
2429            CreateComponentError::ResourceInUse(ref cause) => write!(f, "{}", cause),
2430            CreateComponentError::Service(ref cause) => write!(f, "{}", cause),
2431            CreateComponentError::ServiceQuotaExceeded(ref cause) => write!(f, "{}", cause),
2432            CreateComponentError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
2433        }
2434    }
2435}
2436impl Error for CreateComponentError {}
2437/// Errors returned by CreateDistributionConfiguration
2438#[derive(Debug, PartialEq)]
2439pub enum CreateDistributionConfigurationError {
2440    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
2441    CallRateLimitExceeded(String),
2442    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
2443    Client(String),
2444    /// <p>You are not authorized to perform the requested operation.</p>
2445    Forbidden(String),
2446    /// <p>You have specified a client token for an operation using parameter values that differ from a previous request that used the same client token.</p>
2447    IdempotentParameterMismatch(String),
2448    /// <p>You have specified two or more mutually exclusive parameters. Review the error message for details.</p>
2449    InvalidParameterCombination(String),
2450    /// <p>You have made a request for an action that is not supported by the service.</p>
2451    InvalidRequest(String),
2452    /// <p>The resource that you are trying to create already exists.</p>
2453    ResourceAlreadyExists(String),
2454    /// <p>The resource that you are trying to operate on is currently in use. Review the message details and retry later.</p>
2455    ResourceInUse(String),
2456    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
2457    Service(String),
2458    /// <p>You have exceeded the number of permitted resources or operations for this service. For service quotas, see <a href="https://docs.aws.amazon.com/general/latest/gr/imagebuilder.html#limits_imagebuilder">EC2 Image Builder endpoints and quotas</a>.</p>
2459    ServiceQuotaExceeded(String),
2460    /// <p>The service is unable to process your request at this time.</p>
2461    ServiceUnavailable(String),
2462}
2463
2464impl CreateDistributionConfigurationError {
2465    pub fn from_response(
2466        res: BufferedHttpResponse,
2467    ) -> RusotoError<CreateDistributionConfigurationError> {
2468        if let Some(err) = proto::json::Error::parse_rest(&res) {
2469            match err.typ.as_str() {
2470                "CallRateLimitExceededException" => {
2471                    return RusotoError::Service(
2472                        CreateDistributionConfigurationError::CallRateLimitExceeded(err.msg),
2473                    )
2474                }
2475                "ClientException" => {
2476                    return RusotoError::Service(CreateDistributionConfigurationError::Client(
2477                        err.msg,
2478                    ))
2479                }
2480                "ForbiddenException" => {
2481                    return RusotoError::Service(CreateDistributionConfigurationError::Forbidden(
2482                        err.msg,
2483                    ))
2484                }
2485                "IdempotentParameterMismatchException" => {
2486                    return RusotoError::Service(
2487                        CreateDistributionConfigurationError::IdempotentParameterMismatch(err.msg),
2488                    )
2489                }
2490                "InvalidParameterCombinationException" => {
2491                    return RusotoError::Service(
2492                        CreateDistributionConfigurationError::InvalidParameterCombination(err.msg),
2493                    )
2494                }
2495                "InvalidRequestException" => {
2496                    return RusotoError::Service(
2497                        CreateDistributionConfigurationError::InvalidRequest(err.msg),
2498                    )
2499                }
2500                "ResourceAlreadyExistsException" => {
2501                    return RusotoError::Service(
2502                        CreateDistributionConfigurationError::ResourceAlreadyExists(err.msg),
2503                    )
2504                }
2505                "ResourceInUseException" => {
2506                    return RusotoError::Service(
2507                        CreateDistributionConfigurationError::ResourceInUse(err.msg),
2508                    )
2509                }
2510                "ServiceException" => {
2511                    return RusotoError::Service(CreateDistributionConfigurationError::Service(
2512                        err.msg,
2513                    ))
2514                }
2515                "ServiceQuotaExceededException" => {
2516                    return RusotoError::Service(
2517                        CreateDistributionConfigurationError::ServiceQuotaExceeded(err.msg),
2518                    )
2519                }
2520                "ServiceUnavailableException" => {
2521                    return RusotoError::Service(
2522                        CreateDistributionConfigurationError::ServiceUnavailable(err.msg),
2523                    )
2524                }
2525                "ValidationException" => return RusotoError::Validation(err.msg),
2526                _ => {}
2527            }
2528        }
2529        RusotoError::Unknown(res)
2530    }
2531}
2532impl fmt::Display for CreateDistributionConfigurationError {
2533    #[allow(unused_variables)]
2534    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2535        match *self {
2536            CreateDistributionConfigurationError::CallRateLimitExceeded(ref cause) => {
2537                write!(f, "{}", cause)
2538            }
2539            CreateDistributionConfigurationError::Client(ref cause) => write!(f, "{}", cause),
2540            CreateDistributionConfigurationError::Forbidden(ref cause) => write!(f, "{}", cause),
2541            CreateDistributionConfigurationError::IdempotentParameterMismatch(ref cause) => {
2542                write!(f, "{}", cause)
2543            }
2544            CreateDistributionConfigurationError::InvalidParameterCombination(ref cause) => {
2545                write!(f, "{}", cause)
2546            }
2547            CreateDistributionConfigurationError::InvalidRequest(ref cause) => {
2548                write!(f, "{}", cause)
2549            }
2550            CreateDistributionConfigurationError::ResourceAlreadyExists(ref cause) => {
2551                write!(f, "{}", cause)
2552            }
2553            CreateDistributionConfigurationError::ResourceInUse(ref cause) => {
2554                write!(f, "{}", cause)
2555            }
2556            CreateDistributionConfigurationError::Service(ref cause) => write!(f, "{}", cause),
2557            CreateDistributionConfigurationError::ServiceQuotaExceeded(ref cause) => {
2558                write!(f, "{}", cause)
2559            }
2560            CreateDistributionConfigurationError::ServiceUnavailable(ref cause) => {
2561                write!(f, "{}", cause)
2562            }
2563        }
2564    }
2565}
2566impl Error for CreateDistributionConfigurationError {}
2567/// Errors returned by CreateImage
2568#[derive(Debug, PartialEq)]
2569pub enum CreateImageError {
2570    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
2571    CallRateLimitExceeded(String),
2572    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
2573    Client(String),
2574    /// <p>You are not authorized to perform the requested operation.</p>
2575    Forbidden(String),
2576    /// <p>You have specified a client token for an operation using parameter values that differ from a previous request that used the same client token.</p>
2577    IdempotentParameterMismatch(String),
2578    /// <p>You have made a request for an action that is not supported by the service.</p>
2579    InvalidRequest(String),
2580    /// <p>The resource that you are trying to operate on is currently in use. Review the message details and retry later.</p>
2581    ResourceInUse(String),
2582    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
2583    Service(String),
2584    /// <p>You have exceeded the number of permitted resources or operations for this service. For service quotas, see <a href="https://docs.aws.amazon.com/general/latest/gr/imagebuilder.html#limits_imagebuilder">EC2 Image Builder endpoints and quotas</a>.</p>
2585    ServiceQuotaExceeded(String),
2586    /// <p>The service is unable to process your request at this time.</p>
2587    ServiceUnavailable(String),
2588}
2589
2590impl CreateImageError {
2591    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreateImageError> {
2592        if let Some(err) = proto::json::Error::parse_rest(&res) {
2593            match err.typ.as_str() {
2594                "CallRateLimitExceededException" => {
2595                    return RusotoError::Service(CreateImageError::CallRateLimitExceeded(err.msg))
2596                }
2597                "ClientException" => {
2598                    return RusotoError::Service(CreateImageError::Client(err.msg))
2599                }
2600                "ForbiddenException" => {
2601                    return RusotoError::Service(CreateImageError::Forbidden(err.msg))
2602                }
2603                "IdempotentParameterMismatchException" => {
2604                    return RusotoError::Service(CreateImageError::IdempotentParameterMismatch(
2605                        err.msg,
2606                    ))
2607                }
2608                "InvalidRequestException" => {
2609                    return RusotoError::Service(CreateImageError::InvalidRequest(err.msg))
2610                }
2611                "ResourceInUseException" => {
2612                    return RusotoError::Service(CreateImageError::ResourceInUse(err.msg))
2613                }
2614                "ServiceException" => {
2615                    return RusotoError::Service(CreateImageError::Service(err.msg))
2616                }
2617                "ServiceQuotaExceededException" => {
2618                    return RusotoError::Service(CreateImageError::ServiceQuotaExceeded(err.msg))
2619                }
2620                "ServiceUnavailableException" => {
2621                    return RusotoError::Service(CreateImageError::ServiceUnavailable(err.msg))
2622                }
2623                "ValidationException" => return RusotoError::Validation(err.msg),
2624                _ => {}
2625            }
2626        }
2627        RusotoError::Unknown(res)
2628    }
2629}
2630impl fmt::Display for CreateImageError {
2631    #[allow(unused_variables)]
2632    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2633        match *self {
2634            CreateImageError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
2635            CreateImageError::Client(ref cause) => write!(f, "{}", cause),
2636            CreateImageError::Forbidden(ref cause) => write!(f, "{}", cause),
2637            CreateImageError::IdempotentParameterMismatch(ref cause) => write!(f, "{}", cause),
2638            CreateImageError::InvalidRequest(ref cause) => write!(f, "{}", cause),
2639            CreateImageError::ResourceInUse(ref cause) => write!(f, "{}", cause),
2640            CreateImageError::Service(ref cause) => write!(f, "{}", cause),
2641            CreateImageError::ServiceQuotaExceeded(ref cause) => write!(f, "{}", cause),
2642            CreateImageError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
2643        }
2644    }
2645}
2646impl Error for CreateImageError {}
2647/// Errors returned by CreateImagePipeline
2648#[derive(Debug, PartialEq)]
2649pub enum CreateImagePipelineError {
2650    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
2651    CallRateLimitExceeded(String),
2652    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
2653    Client(String),
2654    /// <p>You are not authorized to perform the requested operation.</p>
2655    Forbidden(String),
2656    /// <p>You have specified a client token for an operation using parameter values that differ from a previous request that used the same client token.</p>
2657    IdempotentParameterMismatch(String),
2658    /// <p>You have made a request for an action that is not supported by the service.</p>
2659    InvalidRequest(String),
2660    /// <p>The resource that you are trying to create already exists.</p>
2661    ResourceAlreadyExists(String),
2662    /// <p>The resource that you are trying to operate on is currently in use. Review the message details and retry later.</p>
2663    ResourceInUse(String),
2664    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
2665    Service(String),
2666    /// <p>You have exceeded the number of permitted resources or operations for this service. For service quotas, see <a href="https://docs.aws.amazon.com/general/latest/gr/imagebuilder.html#limits_imagebuilder">EC2 Image Builder endpoints and quotas</a>.</p>
2667    ServiceQuotaExceeded(String),
2668    /// <p>The service is unable to process your request at this time.</p>
2669    ServiceUnavailable(String),
2670}
2671
2672impl CreateImagePipelineError {
2673    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreateImagePipelineError> {
2674        if let Some(err) = proto::json::Error::parse_rest(&res) {
2675            match err.typ.as_str() {
2676                "CallRateLimitExceededException" => {
2677                    return RusotoError::Service(CreateImagePipelineError::CallRateLimitExceeded(
2678                        err.msg,
2679                    ))
2680                }
2681                "ClientException" => {
2682                    return RusotoError::Service(CreateImagePipelineError::Client(err.msg))
2683                }
2684                "ForbiddenException" => {
2685                    return RusotoError::Service(CreateImagePipelineError::Forbidden(err.msg))
2686                }
2687                "IdempotentParameterMismatchException" => {
2688                    return RusotoError::Service(
2689                        CreateImagePipelineError::IdempotentParameterMismatch(err.msg),
2690                    )
2691                }
2692                "InvalidRequestException" => {
2693                    return RusotoError::Service(CreateImagePipelineError::InvalidRequest(err.msg))
2694                }
2695                "ResourceAlreadyExistsException" => {
2696                    return RusotoError::Service(CreateImagePipelineError::ResourceAlreadyExists(
2697                        err.msg,
2698                    ))
2699                }
2700                "ResourceInUseException" => {
2701                    return RusotoError::Service(CreateImagePipelineError::ResourceInUse(err.msg))
2702                }
2703                "ServiceException" => {
2704                    return RusotoError::Service(CreateImagePipelineError::Service(err.msg))
2705                }
2706                "ServiceQuotaExceededException" => {
2707                    return RusotoError::Service(CreateImagePipelineError::ServiceQuotaExceeded(
2708                        err.msg,
2709                    ))
2710                }
2711                "ServiceUnavailableException" => {
2712                    return RusotoError::Service(CreateImagePipelineError::ServiceUnavailable(
2713                        err.msg,
2714                    ))
2715                }
2716                "ValidationException" => return RusotoError::Validation(err.msg),
2717                _ => {}
2718            }
2719        }
2720        RusotoError::Unknown(res)
2721    }
2722}
2723impl fmt::Display for CreateImagePipelineError {
2724    #[allow(unused_variables)]
2725    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2726        match *self {
2727            CreateImagePipelineError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
2728            CreateImagePipelineError::Client(ref cause) => write!(f, "{}", cause),
2729            CreateImagePipelineError::Forbidden(ref cause) => write!(f, "{}", cause),
2730            CreateImagePipelineError::IdempotentParameterMismatch(ref cause) => {
2731                write!(f, "{}", cause)
2732            }
2733            CreateImagePipelineError::InvalidRequest(ref cause) => write!(f, "{}", cause),
2734            CreateImagePipelineError::ResourceAlreadyExists(ref cause) => write!(f, "{}", cause),
2735            CreateImagePipelineError::ResourceInUse(ref cause) => write!(f, "{}", cause),
2736            CreateImagePipelineError::Service(ref cause) => write!(f, "{}", cause),
2737            CreateImagePipelineError::ServiceQuotaExceeded(ref cause) => write!(f, "{}", cause),
2738            CreateImagePipelineError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
2739        }
2740    }
2741}
2742impl Error for CreateImagePipelineError {}
2743/// Errors returned by CreateImageRecipe
2744#[derive(Debug, PartialEq)]
2745pub enum CreateImageRecipeError {
2746    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
2747    CallRateLimitExceeded(String),
2748    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
2749    Client(String),
2750    /// <p>You are not authorized to perform the requested operation.</p>
2751    Forbidden(String),
2752    /// <p>You have specified a client token for an operation using parameter values that differ from a previous request that used the same client token.</p>
2753    IdempotentParameterMismatch(String),
2754    /// <p>You have made a request for an action that is not supported by the service.</p>
2755    InvalidRequest(String),
2756    /// <p>Your version number is out of bounds or does not follow the required syntax.</p>
2757    InvalidVersionNumber(String),
2758    /// <p>The resource that you are trying to create already exists.</p>
2759    ResourceAlreadyExists(String),
2760    /// <p>The resource that you are trying to operate on is currently in use. Review the message details and retry later.</p>
2761    ResourceInUse(String),
2762    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
2763    Service(String),
2764    /// <p>You have exceeded the number of permitted resources or operations for this service. For service quotas, see <a href="https://docs.aws.amazon.com/general/latest/gr/imagebuilder.html#limits_imagebuilder">EC2 Image Builder endpoints and quotas</a>.</p>
2765    ServiceQuotaExceeded(String),
2766    /// <p>The service is unable to process your request at this time.</p>
2767    ServiceUnavailable(String),
2768}
2769
2770impl CreateImageRecipeError {
2771    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreateImageRecipeError> {
2772        if let Some(err) = proto::json::Error::parse_rest(&res) {
2773            match err.typ.as_str() {
2774                "CallRateLimitExceededException" => {
2775                    return RusotoError::Service(CreateImageRecipeError::CallRateLimitExceeded(
2776                        err.msg,
2777                    ))
2778                }
2779                "ClientException" => {
2780                    return RusotoError::Service(CreateImageRecipeError::Client(err.msg))
2781                }
2782                "ForbiddenException" => {
2783                    return RusotoError::Service(CreateImageRecipeError::Forbidden(err.msg))
2784                }
2785                "IdempotentParameterMismatchException" => {
2786                    return RusotoError::Service(
2787                        CreateImageRecipeError::IdempotentParameterMismatch(err.msg),
2788                    )
2789                }
2790                "InvalidRequestException" => {
2791                    return RusotoError::Service(CreateImageRecipeError::InvalidRequest(err.msg))
2792                }
2793                "InvalidVersionNumberException" => {
2794                    return RusotoError::Service(CreateImageRecipeError::InvalidVersionNumber(
2795                        err.msg,
2796                    ))
2797                }
2798                "ResourceAlreadyExistsException" => {
2799                    return RusotoError::Service(CreateImageRecipeError::ResourceAlreadyExists(
2800                        err.msg,
2801                    ))
2802                }
2803                "ResourceInUseException" => {
2804                    return RusotoError::Service(CreateImageRecipeError::ResourceInUse(err.msg))
2805                }
2806                "ServiceException" => {
2807                    return RusotoError::Service(CreateImageRecipeError::Service(err.msg))
2808                }
2809                "ServiceQuotaExceededException" => {
2810                    return RusotoError::Service(CreateImageRecipeError::ServiceQuotaExceeded(
2811                        err.msg,
2812                    ))
2813                }
2814                "ServiceUnavailableException" => {
2815                    return RusotoError::Service(CreateImageRecipeError::ServiceUnavailable(
2816                        err.msg,
2817                    ))
2818                }
2819                "ValidationException" => return RusotoError::Validation(err.msg),
2820                _ => {}
2821            }
2822        }
2823        RusotoError::Unknown(res)
2824    }
2825}
2826impl fmt::Display for CreateImageRecipeError {
2827    #[allow(unused_variables)]
2828    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2829        match *self {
2830            CreateImageRecipeError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
2831            CreateImageRecipeError::Client(ref cause) => write!(f, "{}", cause),
2832            CreateImageRecipeError::Forbidden(ref cause) => write!(f, "{}", cause),
2833            CreateImageRecipeError::IdempotentParameterMismatch(ref cause) => {
2834                write!(f, "{}", cause)
2835            }
2836            CreateImageRecipeError::InvalidRequest(ref cause) => write!(f, "{}", cause),
2837            CreateImageRecipeError::InvalidVersionNumber(ref cause) => write!(f, "{}", cause),
2838            CreateImageRecipeError::ResourceAlreadyExists(ref cause) => write!(f, "{}", cause),
2839            CreateImageRecipeError::ResourceInUse(ref cause) => write!(f, "{}", cause),
2840            CreateImageRecipeError::Service(ref cause) => write!(f, "{}", cause),
2841            CreateImageRecipeError::ServiceQuotaExceeded(ref cause) => write!(f, "{}", cause),
2842            CreateImageRecipeError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
2843        }
2844    }
2845}
2846impl Error for CreateImageRecipeError {}
2847/// Errors returned by CreateInfrastructureConfiguration
2848#[derive(Debug, PartialEq)]
2849pub enum CreateInfrastructureConfigurationError {
2850    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
2851    CallRateLimitExceeded(String),
2852    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
2853    Client(String),
2854    /// <p>You are not authorized to perform the requested operation.</p>
2855    Forbidden(String),
2856    /// <p>You have specified a client token for an operation using parameter values that differ from a previous request that used the same client token.</p>
2857    IdempotentParameterMismatch(String),
2858    /// <p>You have made a request for an action that is not supported by the service.</p>
2859    InvalidRequest(String),
2860    /// <p>The resource that you are trying to create already exists.</p>
2861    ResourceAlreadyExists(String),
2862    /// <p>The resource that you are trying to operate on is currently in use. Review the message details and retry later.</p>
2863    ResourceInUse(String),
2864    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
2865    Service(String),
2866    /// <p>You have exceeded the number of permitted resources or operations for this service. For service quotas, see <a href="https://docs.aws.amazon.com/general/latest/gr/imagebuilder.html#limits_imagebuilder">EC2 Image Builder endpoints and quotas</a>.</p>
2867    ServiceQuotaExceeded(String),
2868    /// <p>The service is unable to process your request at this time.</p>
2869    ServiceUnavailable(String),
2870}
2871
2872impl CreateInfrastructureConfigurationError {
2873    pub fn from_response(
2874        res: BufferedHttpResponse,
2875    ) -> RusotoError<CreateInfrastructureConfigurationError> {
2876        if let Some(err) = proto::json::Error::parse_rest(&res) {
2877            match err.typ.as_str() {
2878                "CallRateLimitExceededException" => {
2879                    return RusotoError::Service(
2880                        CreateInfrastructureConfigurationError::CallRateLimitExceeded(err.msg),
2881                    )
2882                }
2883                "ClientException" => {
2884                    return RusotoError::Service(CreateInfrastructureConfigurationError::Client(
2885                        err.msg,
2886                    ))
2887                }
2888                "ForbiddenException" => {
2889                    return RusotoError::Service(CreateInfrastructureConfigurationError::Forbidden(
2890                        err.msg,
2891                    ))
2892                }
2893                "IdempotentParameterMismatchException" => {
2894                    return RusotoError::Service(
2895                        CreateInfrastructureConfigurationError::IdempotentParameterMismatch(
2896                            err.msg,
2897                        ),
2898                    )
2899                }
2900                "InvalidRequestException" => {
2901                    return RusotoError::Service(
2902                        CreateInfrastructureConfigurationError::InvalidRequest(err.msg),
2903                    )
2904                }
2905                "ResourceAlreadyExistsException" => {
2906                    return RusotoError::Service(
2907                        CreateInfrastructureConfigurationError::ResourceAlreadyExists(err.msg),
2908                    )
2909                }
2910                "ResourceInUseException" => {
2911                    return RusotoError::Service(
2912                        CreateInfrastructureConfigurationError::ResourceInUse(err.msg),
2913                    )
2914                }
2915                "ServiceException" => {
2916                    return RusotoError::Service(CreateInfrastructureConfigurationError::Service(
2917                        err.msg,
2918                    ))
2919                }
2920                "ServiceQuotaExceededException" => {
2921                    return RusotoError::Service(
2922                        CreateInfrastructureConfigurationError::ServiceQuotaExceeded(err.msg),
2923                    )
2924                }
2925                "ServiceUnavailableException" => {
2926                    return RusotoError::Service(
2927                        CreateInfrastructureConfigurationError::ServiceUnavailable(err.msg),
2928                    )
2929                }
2930                "ValidationException" => return RusotoError::Validation(err.msg),
2931                _ => {}
2932            }
2933        }
2934        RusotoError::Unknown(res)
2935    }
2936}
2937impl fmt::Display for CreateInfrastructureConfigurationError {
2938    #[allow(unused_variables)]
2939    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2940        match *self {
2941            CreateInfrastructureConfigurationError::CallRateLimitExceeded(ref cause) => {
2942                write!(f, "{}", cause)
2943            }
2944            CreateInfrastructureConfigurationError::Client(ref cause) => write!(f, "{}", cause),
2945            CreateInfrastructureConfigurationError::Forbidden(ref cause) => write!(f, "{}", cause),
2946            CreateInfrastructureConfigurationError::IdempotentParameterMismatch(ref cause) => {
2947                write!(f, "{}", cause)
2948            }
2949            CreateInfrastructureConfigurationError::InvalidRequest(ref cause) => {
2950                write!(f, "{}", cause)
2951            }
2952            CreateInfrastructureConfigurationError::ResourceAlreadyExists(ref cause) => {
2953                write!(f, "{}", cause)
2954            }
2955            CreateInfrastructureConfigurationError::ResourceInUse(ref cause) => {
2956                write!(f, "{}", cause)
2957            }
2958            CreateInfrastructureConfigurationError::Service(ref cause) => write!(f, "{}", cause),
2959            CreateInfrastructureConfigurationError::ServiceQuotaExceeded(ref cause) => {
2960                write!(f, "{}", cause)
2961            }
2962            CreateInfrastructureConfigurationError::ServiceUnavailable(ref cause) => {
2963                write!(f, "{}", cause)
2964            }
2965        }
2966    }
2967}
2968impl Error for CreateInfrastructureConfigurationError {}
2969/// Errors returned by DeleteComponent
2970#[derive(Debug, PartialEq)]
2971pub enum DeleteComponentError {
2972    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
2973    CallRateLimitExceeded(String),
2974    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
2975    Client(String),
2976    /// <p>You are not authorized to perform the requested operation.</p>
2977    Forbidden(String),
2978    /// <p>You have made a request for an action that is not supported by the service.</p>
2979    InvalidRequest(String),
2980    /// <p>You have attempted to mutate or delete a resource with a dependency that prohibits this action. See the error message for more details.</p>
2981    ResourceDependency(String),
2982    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
2983    Service(String),
2984    /// <p>The service is unable to process your request at this time.</p>
2985    ServiceUnavailable(String),
2986}
2987
2988impl DeleteComponentError {
2989    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeleteComponentError> {
2990        if let Some(err) = proto::json::Error::parse_rest(&res) {
2991            match err.typ.as_str() {
2992                "CallRateLimitExceededException" => {
2993                    return RusotoError::Service(DeleteComponentError::CallRateLimitExceeded(
2994                        err.msg,
2995                    ))
2996                }
2997                "ClientException" => {
2998                    return RusotoError::Service(DeleteComponentError::Client(err.msg))
2999                }
3000                "ForbiddenException" => {
3001                    return RusotoError::Service(DeleteComponentError::Forbidden(err.msg))
3002                }
3003                "InvalidRequestException" => {
3004                    return RusotoError::Service(DeleteComponentError::InvalidRequest(err.msg))
3005                }
3006                "ResourceDependencyException" => {
3007                    return RusotoError::Service(DeleteComponentError::ResourceDependency(err.msg))
3008                }
3009                "ServiceException" => {
3010                    return RusotoError::Service(DeleteComponentError::Service(err.msg))
3011                }
3012                "ServiceUnavailableException" => {
3013                    return RusotoError::Service(DeleteComponentError::ServiceUnavailable(err.msg))
3014                }
3015                "ValidationException" => return RusotoError::Validation(err.msg),
3016                _ => {}
3017            }
3018        }
3019        RusotoError::Unknown(res)
3020    }
3021}
3022impl fmt::Display for DeleteComponentError {
3023    #[allow(unused_variables)]
3024    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3025        match *self {
3026            DeleteComponentError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
3027            DeleteComponentError::Client(ref cause) => write!(f, "{}", cause),
3028            DeleteComponentError::Forbidden(ref cause) => write!(f, "{}", cause),
3029            DeleteComponentError::InvalidRequest(ref cause) => write!(f, "{}", cause),
3030            DeleteComponentError::ResourceDependency(ref cause) => write!(f, "{}", cause),
3031            DeleteComponentError::Service(ref cause) => write!(f, "{}", cause),
3032            DeleteComponentError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
3033        }
3034    }
3035}
3036impl Error for DeleteComponentError {}
3037/// Errors returned by DeleteDistributionConfiguration
3038#[derive(Debug, PartialEq)]
3039pub enum DeleteDistributionConfigurationError {
3040    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3041    CallRateLimitExceeded(String),
3042    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
3043    Client(String),
3044    /// <p>You are not authorized to perform the requested operation.</p>
3045    Forbidden(String),
3046    /// <p>You have made a request for an action that is not supported by the service.</p>
3047    InvalidRequest(String),
3048    /// <p>You have attempted to mutate or delete a resource with a dependency that prohibits this action. See the error message for more details.</p>
3049    ResourceDependency(String),
3050    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3051    Service(String),
3052    /// <p>The service is unable to process your request at this time.</p>
3053    ServiceUnavailable(String),
3054}
3055
3056impl DeleteDistributionConfigurationError {
3057    pub fn from_response(
3058        res: BufferedHttpResponse,
3059    ) -> RusotoError<DeleteDistributionConfigurationError> {
3060        if let Some(err) = proto::json::Error::parse_rest(&res) {
3061            match err.typ.as_str() {
3062                "CallRateLimitExceededException" => {
3063                    return RusotoError::Service(
3064                        DeleteDistributionConfigurationError::CallRateLimitExceeded(err.msg),
3065                    )
3066                }
3067                "ClientException" => {
3068                    return RusotoError::Service(DeleteDistributionConfigurationError::Client(
3069                        err.msg,
3070                    ))
3071                }
3072                "ForbiddenException" => {
3073                    return RusotoError::Service(DeleteDistributionConfigurationError::Forbidden(
3074                        err.msg,
3075                    ))
3076                }
3077                "InvalidRequestException" => {
3078                    return RusotoError::Service(
3079                        DeleteDistributionConfigurationError::InvalidRequest(err.msg),
3080                    )
3081                }
3082                "ResourceDependencyException" => {
3083                    return RusotoError::Service(
3084                        DeleteDistributionConfigurationError::ResourceDependency(err.msg),
3085                    )
3086                }
3087                "ServiceException" => {
3088                    return RusotoError::Service(DeleteDistributionConfigurationError::Service(
3089                        err.msg,
3090                    ))
3091                }
3092                "ServiceUnavailableException" => {
3093                    return RusotoError::Service(
3094                        DeleteDistributionConfigurationError::ServiceUnavailable(err.msg),
3095                    )
3096                }
3097                "ValidationException" => return RusotoError::Validation(err.msg),
3098                _ => {}
3099            }
3100        }
3101        RusotoError::Unknown(res)
3102    }
3103}
3104impl fmt::Display for DeleteDistributionConfigurationError {
3105    #[allow(unused_variables)]
3106    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3107        match *self {
3108            DeleteDistributionConfigurationError::CallRateLimitExceeded(ref cause) => {
3109                write!(f, "{}", cause)
3110            }
3111            DeleteDistributionConfigurationError::Client(ref cause) => write!(f, "{}", cause),
3112            DeleteDistributionConfigurationError::Forbidden(ref cause) => write!(f, "{}", cause),
3113            DeleteDistributionConfigurationError::InvalidRequest(ref cause) => {
3114                write!(f, "{}", cause)
3115            }
3116            DeleteDistributionConfigurationError::ResourceDependency(ref cause) => {
3117                write!(f, "{}", cause)
3118            }
3119            DeleteDistributionConfigurationError::Service(ref cause) => write!(f, "{}", cause),
3120            DeleteDistributionConfigurationError::ServiceUnavailable(ref cause) => {
3121                write!(f, "{}", cause)
3122            }
3123        }
3124    }
3125}
3126impl Error for DeleteDistributionConfigurationError {}
3127/// Errors returned by DeleteImage
3128#[derive(Debug, PartialEq)]
3129pub enum DeleteImageError {
3130    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3131    CallRateLimitExceeded(String),
3132    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
3133    Client(String),
3134    /// <p>You are not authorized to perform the requested operation.</p>
3135    Forbidden(String),
3136    /// <p>You have made a request for an action that is not supported by the service.</p>
3137    InvalidRequest(String),
3138    /// <p>You have attempted to mutate or delete a resource with a dependency that prohibits this action. See the error message for more details.</p>
3139    ResourceDependency(String),
3140    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3141    Service(String),
3142    /// <p>The service is unable to process your request at this time.</p>
3143    ServiceUnavailable(String),
3144}
3145
3146impl DeleteImageError {
3147    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeleteImageError> {
3148        if let Some(err) = proto::json::Error::parse_rest(&res) {
3149            match err.typ.as_str() {
3150                "CallRateLimitExceededException" => {
3151                    return RusotoError::Service(DeleteImageError::CallRateLimitExceeded(err.msg))
3152                }
3153                "ClientException" => {
3154                    return RusotoError::Service(DeleteImageError::Client(err.msg))
3155                }
3156                "ForbiddenException" => {
3157                    return RusotoError::Service(DeleteImageError::Forbidden(err.msg))
3158                }
3159                "InvalidRequestException" => {
3160                    return RusotoError::Service(DeleteImageError::InvalidRequest(err.msg))
3161                }
3162                "ResourceDependencyException" => {
3163                    return RusotoError::Service(DeleteImageError::ResourceDependency(err.msg))
3164                }
3165                "ServiceException" => {
3166                    return RusotoError::Service(DeleteImageError::Service(err.msg))
3167                }
3168                "ServiceUnavailableException" => {
3169                    return RusotoError::Service(DeleteImageError::ServiceUnavailable(err.msg))
3170                }
3171                "ValidationException" => return RusotoError::Validation(err.msg),
3172                _ => {}
3173            }
3174        }
3175        RusotoError::Unknown(res)
3176    }
3177}
3178impl fmt::Display for DeleteImageError {
3179    #[allow(unused_variables)]
3180    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3181        match *self {
3182            DeleteImageError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
3183            DeleteImageError::Client(ref cause) => write!(f, "{}", cause),
3184            DeleteImageError::Forbidden(ref cause) => write!(f, "{}", cause),
3185            DeleteImageError::InvalidRequest(ref cause) => write!(f, "{}", cause),
3186            DeleteImageError::ResourceDependency(ref cause) => write!(f, "{}", cause),
3187            DeleteImageError::Service(ref cause) => write!(f, "{}", cause),
3188            DeleteImageError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
3189        }
3190    }
3191}
3192impl Error for DeleteImageError {}
3193/// Errors returned by DeleteImagePipeline
3194#[derive(Debug, PartialEq)]
3195pub enum DeleteImagePipelineError {
3196    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3197    CallRateLimitExceeded(String),
3198    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
3199    Client(String),
3200    /// <p>You are not authorized to perform the requested operation.</p>
3201    Forbidden(String),
3202    /// <p>You have made a request for an action that is not supported by the service.</p>
3203    InvalidRequest(String),
3204    /// <p>You have attempted to mutate or delete a resource with a dependency that prohibits this action. See the error message for more details.</p>
3205    ResourceDependency(String),
3206    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3207    Service(String),
3208    /// <p>The service is unable to process your request at this time.</p>
3209    ServiceUnavailable(String),
3210}
3211
3212impl DeleteImagePipelineError {
3213    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeleteImagePipelineError> {
3214        if let Some(err) = proto::json::Error::parse_rest(&res) {
3215            match err.typ.as_str() {
3216                "CallRateLimitExceededException" => {
3217                    return RusotoError::Service(DeleteImagePipelineError::CallRateLimitExceeded(
3218                        err.msg,
3219                    ))
3220                }
3221                "ClientException" => {
3222                    return RusotoError::Service(DeleteImagePipelineError::Client(err.msg))
3223                }
3224                "ForbiddenException" => {
3225                    return RusotoError::Service(DeleteImagePipelineError::Forbidden(err.msg))
3226                }
3227                "InvalidRequestException" => {
3228                    return RusotoError::Service(DeleteImagePipelineError::InvalidRequest(err.msg))
3229                }
3230                "ResourceDependencyException" => {
3231                    return RusotoError::Service(DeleteImagePipelineError::ResourceDependency(
3232                        err.msg,
3233                    ))
3234                }
3235                "ServiceException" => {
3236                    return RusotoError::Service(DeleteImagePipelineError::Service(err.msg))
3237                }
3238                "ServiceUnavailableException" => {
3239                    return RusotoError::Service(DeleteImagePipelineError::ServiceUnavailable(
3240                        err.msg,
3241                    ))
3242                }
3243                "ValidationException" => return RusotoError::Validation(err.msg),
3244                _ => {}
3245            }
3246        }
3247        RusotoError::Unknown(res)
3248    }
3249}
3250impl fmt::Display for DeleteImagePipelineError {
3251    #[allow(unused_variables)]
3252    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3253        match *self {
3254            DeleteImagePipelineError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
3255            DeleteImagePipelineError::Client(ref cause) => write!(f, "{}", cause),
3256            DeleteImagePipelineError::Forbidden(ref cause) => write!(f, "{}", cause),
3257            DeleteImagePipelineError::InvalidRequest(ref cause) => write!(f, "{}", cause),
3258            DeleteImagePipelineError::ResourceDependency(ref cause) => write!(f, "{}", cause),
3259            DeleteImagePipelineError::Service(ref cause) => write!(f, "{}", cause),
3260            DeleteImagePipelineError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
3261        }
3262    }
3263}
3264impl Error for DeleteImagePipelineError {}
3265/// Errors returned by DeleteImageRecipe
3266#[derive(Debug, PartialEq)]
3267pub enum DeleteImageRecipeError {
3268    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3269    CallRateLimitExceeded(String),
3270    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
3271    Client(String),
3272    /// <p>You are not authorized to perform the requested operation.</p>
3273    Forbidden(String),
3274    /// <p>You have made a request for an action that is not supported by the service.</p>
3275    InvalidRequest(String),
3276    /// <p>You have attempted to mutate or delete a resource with a dependency that prohibits this action. See the error message for more details.</p>
3277    ResourceDependency(String),
3278    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3279    Service(String),
3280    /// <p>The service is unable to process your request at this time.</p>
3281    ServiceUnavailable(String),
3282}
3283
3284impl DeleteImageRecipeError {
3285    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeleteImageRecipeError> {
3286        if let Some(err) = proto::json::Error::parse_rest(&res) {
3287            match err.typ.as_str() {
3288                "CallRateLimitExceededException" => {
3289                    return RusotoError::Service(DeleteImageRecipeError::CallRateLimitExceeded(
3290                        err.msg,
3291                    ))
3292                }
3293                "ClientException" => {
3294                    return RusotoError::Service(DeleteImageRecipeError::Client(err.msg))
3295                }
3296                "ForbiddenException" => {
3297                    return RusotoError::Service(DeleteImageRecipeError::Forbidden(err.msg))
3298                }
3299                "InvalidRequestException" => {
3300                    return RusotoError::Service(DeleteImageRecipeError::InvalidRequest(err.msg))
3301                }
3302                "ResourceDependencyException" => {
3303                    return RusotoError::Service(DeleteImageRecipeError::ResourceDependency(
3304                        err.msg,
3305                    ))
3306                }
3307                "ServiceException" => {
3308                    return RusotoError::Service(DeleteImageRecipeError::Service(err.msg))
3309                }
3310                "ServiceUnavailableException" => {
3311                    return RusotoError::Service(DeleteImageRecipeError::ServiceUnavailable(
3312                        err.msg,
3313                    ))
3314                }
3315                "ValidationException" => return RusotoError::Validation(err.msg),
3316                _ => {}
3317            }
3318        }
3319        RusotoError::Unknown(res)
3320    }
3321}
3322impl fmt::Display for DeleteImageRecipeError {
3323    #[allow(unused_variables)]
3324    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3325        match *self {
3326            DeleteImageRecipeError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
3327            DeleteImageRecipeError::Client(ref cause) => write!(f, "{}", cause),
3328            DeleteImageRecipeError::Forbidden(ref cause) => write!(f, "{}", cause),
3329            DeleteImageRecipeError::InvalidRequest(ref cause) => write!(f, "{}", cause),
3330            DeleteImageRecipeError::ResourceDependency(ref cause) => write!(f, "{}", cause),
3331            DeleteImageRecipeError::Service(ref cause) => write!(f, "{}", cause),
3332            DeleteImageRecipeError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
3333        }
3334    }
3335}
3336impl Error for DeleteImageRecipeError {}
3337/// Errors returned by DeleteInfrastructureConfiguration
3338#[derive(Debug, PartialEq)]
3339pub enum DeleteInfrastructureConfigurationError {
3340    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3341    CallRateLimitExceeded(String),
3342    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
3343    Client(String),
3344    /// <p>You are not authorized to perform the requested operation.</p>
3345    Forbidden(String),
3346    /// <p>You have made a request for an action that is not supported by the service.</p>
3347    InvalidRequest(String),
3348    /// <p>You have attempted to mutate or delete a resource with a dependency that prohibits this action. See the error message for more details.</p>
3349    ResourceDependency(String),
3350    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3351    Service(String),
3352    /// <p>The service is unable to process your request at this time.</p>
3353    ServiceUnavailable(String),
3354}
3355
3356impl DeleteInfrastructureConfigurationError {
3357    pub fn from_response(
3358        res: BufferedHttpResponse,
3359    ) -> RusotoError<DeleteInfrastructureConfigurationError> {
3360        if let Some(err) = proto::json::Error::parse_rest(&res) {
3361            match err.typ.as_str() {
3362                "CallRateLimitExceededException" => {
3363                    return RusotoError::Service(
3364                        DeleteInfrastructureConfigurationError::CallRateLimitExceeded(err.msg),
3365                    )
3366                }
3367                "ClientException" => {
3368                    return RusotoError::Service(DeleteInfrastructureConfigurationError::Client(
3369                        err.msg,
3370                    ))
3371                }
3372                "ForbiddenException" => {
3373                    return RusotoError::Service(DeleteInfrastructureConfigurationError::Forbidden(
3374                        err.msg,
3375                    ))
3376                }
3377                "InvalidRequestException" => {
3378                    return RusotoError::Service(
3379                        DeleteInfrastructureConfigurationError::InvalidRequest(err.msg),
3380                    )
3381                }
3382                "ResourceDependencyException" => {
3383                    return RusotoError::Service(
3384                        DeleteInfrastructureConfigurationError::ResourceDependency(err.msg),
3385                    )
3386                }
3387                "ServiceException" => {
3388                    return RusotoError::Service(DeleteInfrastructureConfigurationError::Service(
3389                        err.msg,
3390                    ))
3391                }
3392                "ServiceUnavailableException" => {
3393                    return RusotoError::Service(
3394                        DeleteInfrastructureConfigurationError::ServiceUnavailable(err.msg),
3395                    )
3396                }
3397                "ValidationException" => return RusotoError::Validation(err.msg),
3398                _ => {}
3399            }
3400        }
3401        RusotoError::Unknown(res)
3402    }
3403}
3404impl fmt::Display for DeleteInfrastructureConfigurationError {
3405    #[allow(unused_variables)]
3406    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3407        match *self {
3408            DeleteInfrastructureConfigurationError::CallRateLimitExceeded(ref cause) => {
3409                write!(f, "{}", cause)
3410            }
3411            DeleteInfrastructureConfigurationError::Client(ref cause) => write!(f, "{}", cause),
3412            DeleteInfrastructureConfigurationError::Forbidden(ref cause) => write!(f, "{}", cause),
3413            DeleteInfrastructureConfigurationError::InvalidRequest(ref cause) => {
3414                write!(f, "{}", cause)
3415            }
3416            DeleteInfrastructureConfigurationError::ResourceDependency(ref cause) => {
3417                write!(f, "{}", cause)
3418            }
3419            DeleteInfrastructureConfigurationError::Service(ref cause) => write!(f, "{}", cause),
3420            DeleteInfrastructureConfigurationError::ServiceUnavailable(ref cause) => {
3421                write!(f, "{}", cause)
3422            }
3423        }
3424    }
3425}
3426impl Error for DeleteInfrastructureConfigurationError {}
3427/// Errors returned by GetComponent
3428#[derive(Debug, PartialEq)]
3429pub enum GetComponentError {
3430    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3431    CallRateLimitExceeded(String),
3432    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
3433    Client(String),
3434    /// <p>You are not authorized to perform the requested operation.</p>
3435    Forbidden(String),
3436    /// <p>You have made a request for an action that is not supported by the service.</p>
3437    InvalidRequest(String),
3438    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3439    Service(String),
3440    /// <p>The service is unable to process your request at this time.</p>
3441    ServiceUnavailable(String),
3442}
3443
3444impl GetComponentError {
3445    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetComponentError> {
3446        if let Some(err) = proto::json::Error::parse_rest(&res) {
3447            match err.typ.as_str() {
3448                "CallRateLimitExceededException" => {
3449                    return RusotoError::Service(GetComponentError::CallRateLimitExceeded(err.msg))
3450                }
3451                "ClientException" => {
3452                    return RusotoError::Service(GetComponentError::Client(err.msg))
3453                }
3454                "ForbiddenException" => {
3455                    return RusotoError::Service(GetComponentError::Forbidden(err.msg))
3456                }
3457                "InvalidRequestException" => {
3458                    return RusotoError::Service(GetComponentError::InvalidRequest(err.msg))
3459                }
3460                "ServiceException" => {
3461                    return RusotoError::Service(GetComponentError::Service(err.msg))
3462                }
3463                "ServiceUnavailableException" => {
3464                    return RusotoError::Service(GetComponentError::ServiceUnavailable(err.msg))
3465                }
3466                "ValidationException" => return RusotoError::Validation(err.msg),
3467                _ => {}
3468            }
3469        }
3470        RusotoError::Unknown(res)
3471    }
3472}
3473impl fmt::Display for GetComponentError {
3474    #[allow(unused_variables)]
3475    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3476        match *self {
3477            GetComponentError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
3478            GetComponentError::Client(ref cause) => write!(f, "{}", cause),
3479            GetComponentError::Forbidden(ref cause) => write!(f, "{}", cause),
3480            GetComponentError::InvalidRequest(ref cause) => write!(f, "{}", cause),
3481            GetComponentError::Service(ref cause) => write!(f, "{}", cause),
3482            GetComponentError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
3483        }
3484    }
3485}
3486impl Error for GetComponentError {}
3487/// Errors returned by GetComponentPolicy
3488#[derive(Debug, PartialEq)]
3489pub enum GetComponentPolicyError {
3490    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3491    CallRateLimitExceeded(String),
3492    /// <p>You are not authorized to perform the requested operation.</p>
3493    Forbidden(String),
3494    /// <p>You have made a request for an action that is not supported by the service.</p>
3495    InvalidRequest(String),
3496    /// <p>At least one of the resources referenced by your request does not exist.</p>
3497    ResourceNotFound(String),
3498    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3499    Service(String),
3500    /// <p>The service is unable to process your request at this time.</p>
3501    ServiceUnavailable(String),
3502}
3503
3504impl GetComponentPolicyError {
3505    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetComponentPolicyError> {
3506        if let Some(err) = proto::json::Error::parse_rest(&res) {
3507            match err.typ.as_str() {
3508                "CallRateLimitExceededException" => {
3509                    return RusotoError::Service(GetComponentPolicyError::CallRateLimitExceeded(
3510                        err.msg,
3511                    ))
3512                }
3513                "ForbiddenException" => {
3514                    return RusotoError::Service(GetComponentPolicyError::Forbidden(err.msg))
3515                }
3516                "InvalidRequestException" => {
3517                    return RusotoError::Service(GetComponentPolicyError::InvalidRequest(err.msg))
3518                }
3519                "ResourceNotFoundException" => {
3520                    return RusotoError::Service(GetComponentPolicyError::ResourceNotFound(err.msg))
3521                }
3522                "ServiceException" => {
3523                    return RusotoError::Service(GetComponentPolicyError::Service(err.msg))
3524                }
3525                "ServiceUnavailableException" => {
3526                    return RusotoError::Service(GetComponentPolicyError::ServiceUnavailable(
3527                        err.msg,
3528                    ))
3529                }
3530                "ValidationException" => return RusotoError::Validation(err.msg),
3531                _ => {}
3532            }
3533        }
3534        RusotoError::Unknown(res)
3535    }
3536}
3537impl fmt::Display for GetComponentPolicyError {
3538    #[allow(unused_variables)]
3539    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3540        match *self {
3541            GetComponentPolicyError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
3542            GetComponentPolicyError::Forbidden(ref cause) => write!(f, "{}", cause),
3543            GetComponentPolicyError::InvalidRequest(ref cause) => write!(f, "{}", cause),
3544            GetComponentPolicyError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
3545            GetComponentPolicyError::Service(ref cause) => write!(f, "{}", cause),
3546            GetComponentPolicyError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
3547        }
3548    }
3549}
3550impl Error for GetComponentPolicyError {}
3551/// Errors returned by GetDistributionConfiguration
3552#[derive(Debug, PartialEq)]
3553pub enum GetDistributionConfigurationError {
3554    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3555    CallRateLimitExceeded(String),
3556    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
3557    Client(String),
3558    /// <p>You are not authorized to perform the requested operation.</p>
3559    Forbidden(String),
3560    /// <p>You have made a request for an action that is not supported by the service.</p>
3561    InvalidRequest(String),
3562    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3563    Service(String),
3564    /// <p>The service is unable to process your request at this time.</p>
3565    ServiceUnavailable(String),
3566}
3567
3568impl GetDistributionConfigurationError {
3569    pub fn from_response(
3570        res: BufferedHttpResponse,
3571    ) -> RusotoError<GetDistributionConfigurationError> {
3572        if let Some(err) = proto::json::Error::parse_rest(&res) {
3573            match err.typ.as_str() {
3574                "CallRateLimitExceededException" => {
3575                    return RusotoError::Service(
3576                        GetDistributionConfigurationError::CallRateLimitExceeded(err.msg),
3577                    )
3578                }
3579                "ClientException" => {
3580                    return RusotoError::Service(GetDistributionConfigurationError::Client(err.msg))
3581                }
3582                "ForbiddenException" => {
3583                    return RusotoError::Service(GetDistributionConfigurationError::Forbidden(
3584                        err.msg,
3585                    ))
3586                }
3587                "InvalidRequestException" => {
3588                    return RusotoError::Service(GetDistributionConfigurationError::InvalidRequest(
3589                        err.msg,
3590                    ))
3591                }
3592                "ServiceException" => {
3593                    return RusotoError::Service(GetDistributionConfigurationError::Service(
3594                        err.msg,
3595                    ))
3596                }
3597                "ServiceUnavailableException" => {
3598                    return RusotoError::Service(
3599                        GetDistributionConfigurationError::ServiceUnavailable(err.msg),
3600                    )
3601                }
3602                "ValidationException" => return RusotoError::Validation(err.msg),
3603                _ => {}
3604            }
3605        }
3606        RusotoError::Unknown(res)
3607    }
3608}
3609impl fmt::Display for GetDistributionConfigurationError {
3610    #[allow(unused_variables)]
3611    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3612        match *self {
3613            GetDistributionConfigurationError::CallRateLimitExceeded(ref cause) => {
3614                write!(f, "{}", cause)
3615            }
3616            GetDistributionConfigurationError::Client(ref cause) => write!(f, "{}", cause),
3617            GetDistributionConfigurationError::Forbidden(ref cause) => write!(f, "{}", cause),
3618            GetDistributionConfigurationError::InvalidRequest(ref cause) => write!(f, "{}", cause),
3619            GetDistributionConfigurationError::Service(ref cause) => write!(f, "{}", cause),
3620            GetDistributionConfigurationError::ServiceUnavailable(ref cause) => {
3621                write!(f, "{}", cause)
3622            }
3623        }
3624    }
3625}
3626impl Error for GetDistributionConfigurationError {}
3627/// Errors returned by GetImage
3628#[derive(Debug, PartialEq)]
3629pub enum GetImageError {
3630    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3631    CallRateLimitExceeded(String),
3632    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
3633    Client(String),
3634    /// <p>You are not authorized to perform the requested operation.</p>
3635    Forbidden(String),
3636    /// <p>You have made a request for an action that is not supported by the service.</p>
3637    InvalidRequest(String),
3638    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3639    Service(String),
3640    /// <p>The service is unable to process your request at this time.</p>
3641    ServiceUnavailable(String),
3642}
3643
3644impl GetImageError {
3645    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetImageError> {
3646        if let Some(err) = proto::json::Error::parse_rest(&res) {
3647            match err.typ.as_str() {
3648                "CallRateLimitExceededException" => {
3649                    return RusotoError::Service(GetImageError::CallRateLimitExceeded(err.msg))
3650                }
3651                "ClientException" => return RusotoError::Service(GetImageError::Client(err.msg)),
3652                "ForbiddenException" => {
3653                    return RusotoError::Service(GetImageError::Forbidden(err.msg))
3654                }
3655                "InvalidRequestException" => {
3656                    return RusotoError::Service(GetImageError::InvalidRequest(err.msg))
3657                }
3658                "ServiceException" => return RusotoError::Service(GetImageError::Service(err.msg)),
3659                "ServiceUnavailableException" => {
3660                    return RusotoError::Service(GetImageError::ServiceUnavailable(err.msg))
3661                }
3662                "ValidationException" => return RusotoError::Validation(err.msg),
3663                _ => {}
3664            }
3665        }
3666        RusotoError::Unknown(res)
3667    }
3668}
3669impl fmt::Display for GetImageError {
3670    #[allow(unused_variables)]
3671    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3672        match *self {
3673            GetImageError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
3674            GetImageError::Client(ref cause) => write!(f, "{}", cause),
3675            GetImageError::Forbidden(ref cause) => write!(f, "{}", cause),
3676            GetImageError::InvalidRequest(ref cause) => write!(f, "{}", cause),
3677            GetImageError::Service(ref cause) => write!(f, "{}", cause),
3678            GetImageError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
3679        }
3680    }
3681}
3682impl Error for GetImageError {}
3683/// Errors returned by GetImagePipeline
3684#[derive(Debug, PartialEq)]
3685pub enum GetImagePipelineError {
3686    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3687    CallRateLimitExceeded(String),
3688    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
3689    Client(String),
3690    /// <p>You are not authorized to perform the requested operation.</p>
3691    Forbidden(String),
3692    /// <p>You have made a request for an action that is not supported by the service.</p>
3693    InvalidRequest(String),
3694    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3695    Service(String),
3696    /// <p>The service is unable to process your request at this time.</p>
3697    ServiceUnavailable(String),
3698}
3699
3700impl GetImagePipelineError {
3701    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetImagePipelineError> {
3702        if let Some(err) = proto::json::Error::parse_rest(&res) {
3703            match err.typ.as_str() {
3704                "CallRateLimitExceededException" => {
3705                    return RusotoError::Service(GetImagePipelineError::CallRateLimitExceeded(
3706                        err.msg,
3707                    ))
3708                }
3709                "ClientException" => {
3710                    return RusotoError::Service(GetImagePipelineError::Client(err.msg))
3711                }
3712                "ForbiddenException" => {
3713                    return RusotoError::Service(GetImagePipelineError::Forbidden(err.msg))
3714                }
3715                "InvalidRequestException" => {
3716                    return RusotoError::Service(GetImagePipelineError::InvalidRequest(err.msg))
3717                }
3718                "ServiceException" => {
3719                    return RusotoError::Service(GetImagePipelineError::Service(err.msg))
3720                }
3721                "ServiceUnavailableException" => {
3722                    return RusotoError::Service(GetImagePipelineError::ServiceUnavailable(err.msg))
3723                }
3724                "ValidationException" => return RusotoError::Validation(err.msg),
3725                _ => {}
3726            }
3727        }
3728        RusotoError::Unknown(res)
3729    }
3730}
3731impl fmt::Display for GetImagePipelineError {
3732    #[allow(unused_variables)]
3733    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3734        match *self {
3735            GetImagePipelineError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
3736            GetImagePipelineError::Client(ref cause) => write!(f, "{}", cause),
3737            GetImagePipelineError::Forbidden(ref cause) => write!(f, "{}", cause),
3738            GetImagePipelineError::InvalidRequest(ref cause) => write!(f, "{}", cause),
3739            GetImagePipelineError::Service(ref cause) => write!(f, "{}", cause),
3740            GetImagePipelineError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
3741        }
3742    }
3743}
3744impl Error for GetImagePipelineError {}
3745/// Errors returned by GetImagePolicy
3746#[derive(Debug, PartialEq)]
3747pub enum GetImagePolicyError {
3748    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3749    CallRateLimitExceeded(String),
3750    /// <p>You are not authorized to perform the requested operation.</p>
3751    Forbidden(String),
3752    /// <p>You have made a request for an action that is not supported by the service.</p>
3753    InvalidRequest(String),
3754    /// <p>At least one of the resources referenced by your request does not exist.</p>
3755    ResourceNotFound(String),
3756    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3757    Service(String),
3758    /// <p>The service is unable to process your request at this time.</p>
3759    ServiceUnavailable(String),
3760}
3761
3762impl GetImagePolicyError {
3763    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetImagePolicyError> {
3764        if let Some(err) = proto::json::Error::parse_rest(&res) {
3765            match err.typ.as_str() {
3766                "CallRateLimitExceededException" => {
3767                    return RusotoError::Service(GetImagePolicyError::CallRateLimitExceeded(
3768                        err.msg,
3769                    ))
3770                }
3771                "ForbiddenException" => {
3772                    return RusotoError::Service(GetImagePolicyError::Forbidden(err.msg))
3773                }
3774                "InvalidRequestException" => {
3775                    return RusotoError::Service(GetImagePolicyError::InvalidRequest(err.msg))
3776                }
3777                "ResourceNotFoundException" => {
3778                    return RusotoError::Service(GetImagePolicyError::ResourceNotFound(err.msg))
3779                }
3780                "ServiceException" => {
3781                    return RusotoError::Service(GetImagePolicyError::Service(err.msg))
3782                }
3783                "ServiceUnavailableException" => {
3784                    return RusotoError::Service(GetImagePolicyError::ServiceUnavailable(err.msg))
3785                }
3786                "ValidationException" => return RusotoError::Validation(err.msg),
3787                _ => {}
3788            }
3789        }
3790        RusotoError::Unknown(res)
3791    }
3792}
3793impl fmt::Display for GetImagePolicyError {
3794    #[allow(unused_variables)]
3795    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3796        match *self {
3797            GetImagePolicyError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
3798            GetImagePolicyError::Forbidden(ref cause) => write!(f, "{}", cause),
3799            GetImagePolicyError::InvalidRequest(ref cause) => write!(f, "{}", cause),
3800            GetImagePolicyError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
3801            GetImagePolicyError::Service(ref cause) => write!(f, "{}", cause),
3802            GetImagePolicyError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
3803        }
3804    }
3805}
3806impl Error for GetImagePolicyError {}
3807/// Errors returned by GetImageRecipe
3808#[derive(Debug, PartialEq)]
3809pub enum GetImageRecipeError {
3810    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3811    CallRateLimitExceeded(String),
3812    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
3813    Client(String),
3814    /// <p>You are not authorized to perform the requested operation.</p>
3815    Forbidden(String),
3816    /// <p>You have made a request for an action that is not supported by the service.</p>
3817    InvalidRequest(String),
3818    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3819    Service(String),
3820    /// <p>The service is unable to process your request at this time.</p>
3821    ServiceUnavailable(String),
3822}
3823
3824impl GetImageRecipeError {
3825    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetImageRecipeError> {
3826        if let Some(err) = proto::json::Error::parse_rest(&res) {
3827            match err.typ.as_str() {
3828                "CallRateLimitExceededException" => {
3829                    return RusotoError::Service(GetImageRecipeError::CallRateLimitExceeded(
3830                        err.msg,
3831                    ))
3832                }
3833                "ClientException" => {
3834                    return RusotoError::Service(GetImageRecipeError::Client(err.msg))
3835                }
3836                "ForbiddenException" => {
3837                    return RusotoError::Service(GetImageRecipeError::Forbidden(err.msg))
3838                }
3839                "InvalidRequestException" => {
3840                    return RusotoError::Service(GetImageRecipeError::InvalidRequest(err.msg))
3841                }
3842                "ServiceException" => {
3843                    return RusotoError::Service(GetImageRecipeError::Service(err.msg))
3844                }
3845                "ServiceUnavailableException" => {
3846                    return RusotoError::Service(GetImageRecipeError::ServiceUnavailable(err.msg))
3847                }
3848                "ValidationException" => return RusotoError::Validation(err.msg),
3849                _ => {}
3850            }
3851        }
3852        RusotoError::Unknown(res)
3853    }
3854}
3855impl fmt::Display for GetImageRecipeError {
3856    #[allow(unused_variables)]
3857    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3858        match *self {
3859            GetImageRecipeError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
3860            GetImageRecipeError::Client(ref cause) => write!(f, "{}", cause),
3861            GetImageRecipeError::Forbidden(ref cause) => write!(f, "{}", cause),
3862            GetImageRecipeError::InvalidRequest(ref cause) => write!(f, "{}", cause),
3863            GetImageRecipeError::Service(ref cause) => write!(f, "{}", cause),
3864            GetImageRecipeError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
3865        }
3866    }
3867}
3868impl Error for GetImageRecipeError {}
3869/// Errors returned by GetImageRecipePolicy
3870#[derive(Debug, PartialEq)]
3871pub enum GetImageRecipePolicyError {
3872    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3873    CallRateLimitExceeded(String),
3874    /// <p>You are not authorized to perform the requested operation.</p>
3875    Forbidden(String),
3876    /// <p>You have made a request for an action that is not supported by the service.</p>
3877    InvalidRequest(String),
3878    /// <p>At least one of the resources referenced by your request does not exist.</p>
3879    ResourceNotFound(String),
3880    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3881    Service(String),
3882    /// <p>The service is unable to process your request at this time.</p>
3883    ServiceUnavailable(String),
3884}
3885
3886impl GetImageRecipePolicyError {
3887    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetImageRecipePolicyError> {
3888        if let Some(err) = proto::json::Error::parse_rest(&res) {
3889            match err.typ.as_str() {
3890                "CallRateLimitExceededException" => {
3891                    return RusotoError::Service(GetImageRecipePolicyError::CallRateLimitExceeded(
3892                        err.msg,
3893                    ))
3894                }
3895                "ForbiddenException" => {
3896                    return RusotoError::Service(GetImageRecipePolicyError::Forbidden(err.msg))
3897                }
3898                "InvalidRequestException" => {
3899                    return RusotoError::Service(GetImageRecipePolicyError::InvalidRequest(err.msg))
3900                }
3901                "ResourceNotFoundException" => {
3902                    return RusotoError::Service(GetImageRecipePolicyError::ResourceNotFound(
3903                        err.msg,
3904                    ))
3905                }
3906                "ServiceException" => {
3907                    return RusotoError::Service(GetImageRecipePolicyError::Service(err.msg))
3908                }
3909                "ServiceUnavailableException" => {
3910                    return RusotoError::Service(GetImageRecipePolicyError::ServiceUnavailable(
3911                        err.msg,
3912                    ))
3913                }
3914                "ValidationException" => return RusotoError::Validation(err.msg),
3915                _ => {}
3916            }
3917        }
3918        RusotoError::Unknown(res)
3919    }
3920}
3921impl fmt::Display for GetImageRecipePolicyError {
3922    #[allow(unused_variables)]
3923    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3924        match *self {
3925            GetImageRecipePolicyError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
3926            GetImageRecipePolicyError::Forbidden(ref cause) => write!(f, "{}", cause),
3927            GetImageRecipePolicyError::InvalidRequest(ref cause) => write!(f, "{}", cause),
3928            GetImageRecipePolicyError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
3929            GetImageRecipePolicyError::Service(ref cause) => write!(f, "{}", cause),
3930            GetImageRecipePolicyError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
3931        }
3932    }
3933}
3934impl Error for GetImageRecipePolicyError {}
3935/// Errors returned by GetInfrastructureConfiguration
3936#[derive(Debug, PartialEq)]
3937pub enum GetInfrastructureConfigurationError {
3938    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
3939    CallRateLimitExceeded(String),
3940    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
3941    Client(String),
3942    /// <p>You are not authorized to perform the requested operation.</p>
3943    Forbidden(String),
3944    /// <p>You have made a request for an action that is not supported by the service.</p>
3945    InvalidRequest(String),
3946    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
3947    Service(String),
3948    /// <p>The service is unable to process your request at this time.</p>
3949    ServiceUnavailable(String),
3950}
3951
3952impl GetInfrastructureConfigurationError {
3953    pub fn from_response(
3954        res: BufferedHttpResponse,
3955    ) -> RusotoError<GetInfrastructureConfigurationError> {
3956        if let Some(err) = proto::json::Error::parse_rest(&res) {
3957            match err.typ.as_str() {
3958                "CallRateLimitExceededException" => {
3959                    return RusotoError::Service(
3960                        GetInfrastructureConfigurationError::CallRateLimitExceeded(err.msg),
3961                    )
3962                }
3963                "ClientException" => {
3964                    return RusotoError::Service(GetInfrastructureConfigurationError::Client(
3965                        err.msg,
3966                    ))
3967                }
3968                "ForbiddenException" => {
3969                    return RusotoError::Service(GetInfrastructureConfigurationError::Forbidden(
3970                        err.msg,
3971                    ))
3972                }
3973                "InvalidRequestException" => {
3974                    return RusotoError::Service(
3975                        GetInfrastructureConfigurationError::InvalidRequest(err.msg),
3976                    )
3977                }
3978                "ServiceException" => {
3979                    return RusotoError::Service(GetInfrastructureConfigurationError::Service(
3980                        err.msg,
3981                    ))
3982                }
3983                "ServiceUnavailableException" => {
3984                    return RusotoError::Service(
3985                        GetInfrastructureConfigurationError::ServiceUnavailable(err.msg),
3986                    )
3987                }
3988                "ValidationException" => return RusotoError::Validation(err.msg),
3989                _ => {}
3990            }
3991        }
3992        RusotoError::Unknown(res)
3993    }
3994}
3995impl fmt::Display for GetInfrastructureConfigurationError {
3996    #[allow(unused_variables)]
3997    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3998        match *self {
3999            GetInfrastructureConfigurationError::CallRateLimitExceeded(ref cause) => {
4000                write!(f, "{}", cause)
4001            }
4002            GetInfrastructureConfigurationError::Client(ref cause) => write!(f, "{}", cause),
4003            GetInfrastructureConfigurationError::Forbidden(ref cause) => write!(f, "{}", cause),
4004            GetInfrastructureConfigurationError::InvalidRequest(ref cause) => {
4005                write!(f, "{}", cause)
4006            }
4007            GetInfrastructureConfigurationError::Service(ref cause) => write!(f, "{}", cause),
4008            GetInfrastructureConfigurationError::ServiceUnavailable(ref cause) => {
4009                write!(f, "{}", cause)
4010            }
4011        }
4012    }
4013}
4014impl Error for GetInfrastructureConfigurationError {}
4015/// Errors returned by ImportComponent
4016#[derive(Debug, PartialEq)]
4017pub enum ImportComponentError {
4018    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
4019    CallRateLimitExceeded(String),
4020    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
4021    Client(String),
4022    /// <p>You are not authorized to perform the requested operation.</p>
4023    Forbidden(String),
4024    /// <p>You have specified a client token for an operation using parameter values that differ from a previous request that used the same client token.</p>
4025    IdempotentParameterMismatch(String),
4026    /// <p>You have specified two or more mutually exclusive parameters. Review the error message for details.</p>
4027    InvalidParameterCombination(String),
4028    /// <p>You have made a request for an action that is not supported by the service.</p>
4029    InvalidRequest(String),
4030    /// <p>Your version number is out of bounds or does not follow the required syntax.</p>
4031    InvalidVersionNumber(String),
4032    /// <p>The resource that you are trying to operate on is currently in use. Review the message details and retry later.</p>
4033    ResourceInUse(String),
4034    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4035    Service(String),
4036    /// <p>The service is unable to process your request at this time.</p>
4037    ServiceUnavailable(String),
4038}
4039
4040impl ImportComponentError {
4041    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ImportComponentError> {
4042        if let Some(err) = proto::json::Error::parse_rest(&res) {
4043            match err.typ.as_str() {
4044                "CallRateLimitExceededException" => {
4045                    return RusotoError::Service(ImportComponentError::CallRateLimitExceeded(
4046                        err.msg,
4047                    ))
4048                }
4049                "ClientException" => {
4050                    return RusotoError::Service(ImportComponentError::Client(err.msg))
4051                }
4052                "ForbiddenException" => {
4053                    return RusotoError::Service(ImportComponentError::Forbidden(err.msg))
4054                }
4055                "IdempotentParameterMismatchException" => {
4056                    return RusotoError::Service(ImportComponentError::IdempotentParameterMismatch(
4057                        err.msg,
4058                    ))
4059                }
4060                "InvalidParameterCombinationException" => {
4061                    return RusotoError::Service(ImportComponentError::InvalidParameterCombination(
4062                        err.msg,
4063                    ))
4064                }
4065                "InvalidRequestException" => {
4066                    return RusotoError::Service(ImportComponentError::InvalidRequest(err.msg))
4067                }
4068                "InvalidVersionNumberException" => {
4069                    return RusotoError::Service(ImportComponentError::InvalidVersionNumber(
4070                        err.msg,
4071                    ))
4072                }
4073                "ResourceInUseException" => {
4074                    return RusotoError::Service(ImportComponentError::ResourceInUse(err.msg))
4075                }
4076                "ServiceException" => {
4077                    return RusotoError::Service(ImportComponentError::Service(err.msg))
4078                }
4079                "ServiceUnavailableException" => {
4080                    return RusotoError::Service(ImportComponentError::ServiceUnavailable(err.msg))
4081                }
4082                "ValidationException" => return RusotoError::Validation(err.msg),
4083                _ => {}
4084            }
4085        }
4086        RusotoError::Unknown(res)
4087    }
4088}
4089impl fmt::Display for ImportComponentError {
4090    #[allow(unused_variables)]
4091    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4092        match *self {
4093            ImportComponentError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
4094            ImportComponentError::Client(ref cause) => write!(f, "{}", cause),
4095            ImportComponentError::Forbidden(ref cause) => write!(f, "{}", cause),
4096            ImportComponentError::IdempotentParameterMismatch(ref cause) => write!(f, "{}", cause),
4097            ImportComponentError::InvalidParameterCombination(ref cause) => write!(f, "{}", cause),
4098            ImportComponentError::InvalidRequest(ref cause) => write!(f, "{}", cause),
4099            ImportComponentError::InvalidVersionNumber(ref cause) => write!(f, "{}", cause),
4100            ImportComponentError::ResourceInUse(ref cause) => write!(f, "{}", cause),
4101            ImportComponentError::Service(ref cause) => write!(f, "{}", cause),
4102            ImportComponentError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
4103        }
4104    }
4105}
4106impl Error for ImportComponentError {}
4107/// Errors returned by ListComponentBuildVersions
4108#[derive(Debug, PartialEq)]
4109pub enum ListComponentBuildVersionsError {
4110    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
4111    CallRateLimitExceeded(String),
4112    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
4113    Client(String),
4114    /// <p>You are not authorized to perform the requested operation.</p>
4115    Forbidden(String),
4116    /// <p>You have provided an invalid pagination token in your request.</p>
4117    InvalidPaginationToken(String),
4118    /// <p>You have made a request for an action that is not supported by the service.</p>
4119    InvalidRequest(String),
4120    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4121    Service(String),
4122    /// <p>The service is unable to process your request at this time.</p>
4123    ServiceUnavailable(String),
4124}
4125
4126impl ListComponentBuildVersionsError {
4127    pub fn from_response(
4128        res: BufferedHttpResponse,
4129    ) -> RusotoError<ListComponentBuildVersionsError> {
4130        if let Some(err) = proto::json::Error::parse_rest(&res) {
4131            match err.typ.as_str() {
4132                "CallRateLimitExceededException" => {
4133                    return RusotoError::Service(
4134                        ListComponentBuildVersionsError::CallRateLimitExceeded(err.msg),
4135                    )
4136                }
4137                "ClientException" => {
4138                    return RusotoError::Service(ListComponentBuildVersionsError::Client(err.msg))
4139                }
4140                "ForbiddenException" => {
4141                    return RusotoError::Service(ListComponentBuildVersionsError::Forbidden(
4142                        err.msg,
4143                    ))
4144                }
4145                "InvalidPaginationTokenException" => {
4146                    return RusotoError::Service(
4147                        ListComponentBuildVersionsError::InvalidPaginationToken(err.msg),
4148                    )
4149                }
4150                "InvalidRequestException" => {
4151                    return RusotoError::Service(ListComponentBuildVersionsError::InvalidRequest(
4152                        err.msg,
4153                    ))
4154                }
4155                "ServiceException" => {
4156                    return RusotoError::Service(ListComponentBuildVersionsError::Service(err.msg))
4157                }
4158                "ServiceUnavailableException" => {
4159                    return RusotoError::Service(
4160                        ListComponentBuildVersionsError::ServiceUnavailable(err.msg),
4161                    )
4162                }
4163                "ValidationException" => return RusotoError::Validation(err.msg),
4164                _ => {}
4165            }
4166        }
4167        RusotoError::Unknown(res)
4168    }
4169}
4170impl fmt::Display for ListComponentBuildVersionsError {
4171    #[allow(unused_variables)]
4172    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4173        match *self {
4174            ListComponentBuildVersionsError::CallRateLimitExceeded(ref cause) => {
4175                write!(f, "{}", cause)
4176            }
4177            ListComponentBuildVersionsError::Client(ref cause) => write!(f, "{}", cause),
4178            ListComponentBuildVersionsError::Forbidden(ref cause) => write!(f, "{}", cause),
4179            ListComponentBuildVersionsError::InvalidPaginationToken(ref cause) => {
4180                write!(f, "{}", cause)
4181            }
4182            ListComponentBuildVersionsError::InvalidRequest(ref cause) => write!(f, "{}", cause),
4183            ListComponentBuildVersionsError::Service(ref cause) => write!(f, "{}", cause),
4184            ListComponentBuildVersionsError::ServiceUnavailable(ref cause) => {
4185                write!(f, "{}", cause)
4186            }
4187        }
4188    }
4189}
4190impl Error for ListComponentBuildVersionsError {}
4191/// Errors returned by ListComponents
4192#[derive(Debug, PartialEq)]
4193pub enum ListComponentsError {
4194    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
4195    CallRateLimitExceeded(String),
4196    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
4197    Client(String),
4198    /// <p>You are not authorized to perform the requested operation.</p>
4199    Forbidden(String),
4200    /// <p>You have provided an invalid pagination token in your request.</p>
4201    InvalidPaginationToken(String),
4202    /// <p>You have made a request for an action that is not supported by the service.</p>
4203    InvalidRequest(String),
4204    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4205    Service(String),
4206    /// <p>The service is unable to process your request at this time.</p>
4207    ServiceUnavailable(String),
4208}
4209
4210impl ListComponentsError {
4211    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListComponentsError> {
4212        if let Some(err) = proto::json::Error::parse_rest(&res) {
4213            match err.typ.as_str() {
4214                "CallRateLimitExceededException" => {
4215                    return RusotoError::Service(ListComponentsError::CallRateLimitExceeded(
4216                        err.msg,
4217                    ))
4218                }
4219                "ClientException" => {
4220                    return RusotoError::Service(ListComponentsError::Client(err.msg))
4221                }
4222                "ForbiddenException" => {
4223                    return RusotoError::Service(ListComponentsError::Forbidden(err.msg))
4224                }
4225                "InvalidPaginationTokenException" => {
4226                    return RusotoError::Service(ListComponentsError::InvalidPaginationToken(
4227                        err.msg,
4228                    ))
4229                }
4230                "InvalidRequestException" => {
4231                    return RusotoError::Service(ListComponentsError::InvalidRequest(err.msg))
4232                }
4233                "ServiceException" => {
4234                    return RusotoError::Service(ListComponentsError::Service(err.msg))
4235                }
4236                "ServiceUnavailableException" => {
4237                    return RusotoError::Service(ListComponentsError::ServiceUnavailable(err.msg))
4238                }
4239                "ValidationException" => return RusotoError::Validation(err.msg),
4240                _ => {}
4241            }
4242        }
4243        RusotoError::Unknown(res)
4244    }
4245}
4246impl fmt::Display for ListComponentsError {
4247    #[allow(unused_variables)]
4248    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4249        match *self {
4250            ListComponentsError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
4251            ListComponentsError::Client(ref cause) => write!(f, "{}", cause),
4252            ListComponentsError::Forbidden(ref cause) => write!(f, "{}", cause),
4253            ListComponentsError::InvalidPaginationToken(ref cause) => write!(f, "{}", cause),
4254            ListComponentsError::InvalidRequest(ref cause) => write!(f, "{}", cause),
4255            ListComponentsError::Service(ref cause) => write!(f, "{}", cause),
4256            ListComponentsError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
4257        }
4258    }
4259}
4260impl Error for ListComponentsError {}
4261/// Errors returned by ListDistributionConfigurations
4262#[derive(Debug, PartialEq)]
4263pub enum ListDistributionConfigurationsError {
4264    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
4265    CallRateLimitExceeded(String),
4266    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
4267    Client(String),
4268    /// <p>You are not authorized to perform the requested operation.</p>
4269    Forbidden(String),
4270    /// <p>You have provided an invalid pagination token in your request.</p>
4271    InvalidPaginationToken(String),
4272    /// <p>You have made a request for an action that is not supported by the service.</p>
4273    InvalidRequest(String),
4274    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4275    Service(String),
4276    /// <p>The service is unable to process your request at this time.</p>
4277    ServiceUnavailable(String),
4278}
4279
4280impl ListDistributionConfigurationsError {
4281    pub fn from_response(
4282        res: BufferedHttpResponse,
4283    ) -> RusotoError<ListDistributionConfigurationsError> {
4284        if let Some(err) = proto::json::Error::parse_rest(&res) {
4285            match err.typ.as_str() {
4286                "CallRateLimitExceededException" => {
4287                    return RusotoError::Service(
4288                        ListDistributionConfigurationsError::CallRateLimitExceeded(err.msg),
4289                    )
4290                }
4291                "ClientException" => {
4292                    return RusotoError::Service(ListDistributionConfigurationsError::Client(
4293                        err.msg,
4294                    ))
4295                }
4296                "ForbiddenException" => {
4297                    return RusotoError::Service(ListDistributionConfigurationsError::Forbidden(
4298                        err.msg,
4299                    ))
4300                }
4301                "InvalidPaginationTokenException" => {
4302                    return RusotoError::Service(
4303                        ListDistributionConfigurationsError::InvalidPaginationToken(err.msg),
4304                    )
4305                }
4306                "InvalidRequestException" => {
4307                    return RusotoError::Service(
4308                        ListDistributionConfigurationsError::InvalidRequest(err.msg),
4309                    )
4310                }
4311                "ServiceException" => {
4312                    return RusotoError::Service(ListDistributionConfigurationsError::Service(
4313                        err.msg,
4314                    ))
4315                }
4316                "ServiceUnavailableException" => {
4317                    return RusotoError::Service(
4318                        ListDistributionConfigurationsError::ServiceUnavailable(err.msg),
4319                    )
4320                }
4321                "ValidationException" => return RusotoError::Validation(err.msg),
4322                _ => {}
4323            }
4324        }
4325        RusotoError::Unknown(res)
4326    }
4327}
4328impl fmt::Display for ListDistributionConfigurationsError {
4329    #[allow(unused_variables)]
4330    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4331        match *self {
4332            ListDistributionConfigurationsError::CallRateLimitExceeded(ref cause) => {
4333                write!(f, "{}", cause)
4334            }
4335            ListDistributionConfigurationsError::Client(ref cause) => write!(f, "{}", cause),
4336            ListDistributionConfigurationsError::Forbidden(ref cause) => write!(f, "{}", cause),
4337            ListDistributionConfigurationsError::InvalidPaginationToken(ref cause) => {
4338                write!(f, "{}", cause)
4339            }
4340            ListDistributionConfigurationsError::InvalidRequest(ref cause) => {
4341                write!(f, "{}", cause)
4342            }
4343            ListDistributionConfigurationsError::Service(ref cause) => write!(f, "{}", cause),
4344            ListDistributionConfigurationsError::ServiceUnavailable(ref cause) => {
4345                write!(f, "{}", cause)
4346            }
4347        }
4348    }
4349}
4350impl Error for ListDistributionConfigurationsError {}
4351/// Errors returned by ListImageBuildVersions
4352#[derive(Debug, PartialEq)]
4353pub enum ListImageBuildVersionsError {
4354    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
4355    CallRateLimitExceeded(String),
4356    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
4357    Client(String),
4358    /// <p>You are not authorized to perform the requested operation.</p>
4359    Forbidden(String),
4360    /// <p>You have provided an invalid pagination token in your request.</p>
4361    InvalidPaginationToken(String),
4362    /// <p>You have made a request for an action that is not supported by the service.</p>
4363    InvalidRequest(String),
4364    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4365    Service(String),
4366    /// <p>The service is unable to process your request at this time.</p>
4367    ServiceUnavailable(String),
4368}
4369
4370impl ListImageBuildVersionsError {
4371    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListImageBuildVersionsError> {
4372        if let Some(err) = proto::json::Error::parse_rest(&res) {
4373            match err.typ.as_str() {
4374                "CallRateLimitExceededException" => {
4375                    return RusotoError::Service(
4376                        ListImageBuildVersionsError::CallRateLimitExceeded(err.msg),
4377                    )
4378                }
4379                "ClientException" => {
4380                    return RusotoError::Service(ListImageBuildVersionsError::Client(err.msg))
4381                }
4382                "ForbiddenException" => {
4383                    return RusotoError::Service(ListImageBuildVersionsError::Forbidden(err.msg))
4384                }
4385                "InvalidPaginationTokenException" => {
4386                    return RusotoError::Service(
4387                        ListImageBuildVersionsError::InvalidPaginationToken(err.msg),
4388                    )
4389                }
4390                "InvalidRequestException" => {
4391                    return RusotoError::Service(ListImageBuildVersionsError::InvalidRequest(
4392                        err.msg,
4393                    ))
4394                }
4395                "ServiceException" => {
4396                    return RusotoError::Service(ListImageBuildVersionsError::Service(err.msg))
4397                }
4398                "ServiceUnavailableException" => {
4399                    return RusotoError::Service(ListImageBuildVersionsError::ServiceUnavailable(
4400                        err.msg,
4401                    ))
4402                }
4403                "ValidationException" => return RusotoError::Validation(err.msg),
4404                _ => {}
4405            }
4406        }
4407        RusotoError::Unknown(res)
4408    }
4409}
4410impl fmt::Display for ListImageBuildVersionsError {
4411    #[allow(unused_variables)]
4412    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4413        match *self {
4414            ListImageBuildVersionsError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
4415            ListImageBuildVersionsError::Client(ref cause) => write!(f, "{}", cause),
4416            ListImageBuildVersionsError::Forbidden(ref cause) => write!(f, "{}", cause),
4417            ListImageBuildVersionsError::InvalidPaginationToken(ref cause) => {
4418                write!(f, "{}", cause)
4419            }
4420            ListImageBuildVersionsError::InvalidRequest(ref cause) => write!(f, "{}", cause),
4421            ListImageBuildVersionsError::Service(ref cause) => write!(f, "{}", cause),
4422            ListImageBuildVersionsError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
4423        }
4424    }
4425}
4426impl Error for ListImageBuildVersionsError {}
4427/// Errors returned by ListImagePipelineImages
4428#[derive(Debug, PartialEq)]
4429pub enum ListImagePipelineImagesError {
4430    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
4431    CallRateLimitExceeded(String),
4432    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
4433    Client(String),
4434    /// <p>You are not authorized to perform the requested operation.</p>
4435    Forbidden(String),
4436    /// <p>You have provided an invalid pagination token in your request.</p>
4437    InvalidPaginationToken(String),
4438    /// <p>You have made a request for an action that is not supported by the service.</p>
4439    InvalidRequest(String),
4440    /// <p>At least one of the resources referenced by your request does not exist.</p>
4441    ResourceNotFound(String),
4442    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4443    Service(String),
4444    /// <p>The service is unable to process your request at this time.</p>
4445    ServiceUnavailable(String),
4446}
4447
4448impl ListImagePipelineImagesError {
4449    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListImagePipelineImagesError> {
4450        if let Some(err) = proto::json::Error::parse_rest(&res) {
4451            match err.typ.as_str() {
4452                "CallRateLimitExceededException" => {
4453                    return RusotoError::Service(
4454                        ListImagePipelineImagesError::CallRateLimitExceeded(err.msg),
4455                    )
4456                }
4457                "ClientException" => {
4458                    return RusotoError::Service(ListImagePipelineImagesError::Client(err.msg))
4459                }
4460                "ForbiddenException" => {
4461                    return RusotoError::Service(ListImagePipelineImagesError::Forbidden(err.msg))
4462                }
4463                "InvalidPaginationTokenException" => {
4464                    return RusotoError::Service(
4465                        ListImagePipelineImagesError::InvalidPaginationToken(err.msg),
4466                    )
4467                }
4468                "InvalidRequestException" => {
4469                    return RusotoError::Service(ListImagePipelineImagesError::InvalidRequest(
4470                        err.msg,
4471                    ))
4472                }
4473                "ResourceNotFoundException" => {
4474                    return RusotoError::Service(ListImagePipelineImagesError::ResourceNotFound(
4475                        err.msg,
4476                    ))
4477                }
4478                "ServiceException" => {
4479                    return RusotoError::Service(ListImagePipelineImagesError::Service(err.msg))
4480                }
4481                "ServiceUnavailableException" => {
4482                    return RusotoError::Service(ListImagePipelineImagesError::ServiceUnavailable(
4483                        err.msg,
4484                    ))
4485                }
4486                "ValidationException" => return RusotoError::Validation(err.msg),
4487                _ => {}
4488            }
4489        }
4490        RusotoError::Unknown(res)
4491    }
4492}
4493impl fmt::Display for ListImagePipelineImagesError {
4494    #[allow(unused_variables)]
4495    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4496        match *self {
4497            ListImagePipelineImagesError::CallRateLimitExceeded(ref cause) => {
4498                write!(f, "{}", cause)
4499            }
4500            ListImagePipelineImagesError::Client(ref cause) => write!(f, "{}", cause),
4501            ListImagePipelineImagesError::Forbidden(ref cause) => write!(f, "{}", cause),
4502            ListImagePipelineImagesError::InvalidPaginationToken(ref cause) => {
4503                write!(f, "{}", cause)
4504            }
4505            ListImagePipelineImagesError::InvalidRequest(ref cause) => write!(f, "{}", cause),
4506            ListImagePipelineImagesError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4507            ListImagePipelineImagesError::Service(ref cause) => write!(f, "{}", cause),
4508            ListImagePipelineImagesError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
4509        }
4510    }
4511}
4512impl Error for ListImagePipelineImagesError {}
4513/// Errors returned by ListImagePipelines
4514#[derive(Debug, PartialEq)]
4515pub enum ListImagePipelinesError {
4516    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
4517    CallRateLimitExceeded(String),
4518    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
4519    Client(String),
4520    /// <p>You are not authorized to perform the requested operation.</p>
4521    Forbidden(String),
4522    /// <p>You have provided an invalid pagination token in your request.</p>
4523    InvalidPaginationToken(String),
4524    /// <p>You have made a request for an action that is not supported by the service.</p>
4525    InvalidRequest(String),
4526    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4527    Service(String),
4528    /// <p>The service is unable to process your request at this time.</p>
4529    ServiceUnavailable(String),
4530}
4531
4532impl ListImagePipelinesError {
4533    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListImagePipelinesError> {
4534        if let Some(err) = proto::json::Error::parse_rest(&res) {
4535            match err.typ.as_str() {
4536                "CallRateLimitExceededException" => {
4537                    return RusotoError::Service(ListImagePipelinesError::CallRateLimitExceeded(
4538                        err.msg,
4539                    ))
4540                }
4541                "ClientException" => {
4542                    return RusotoError::Service(ListImagePipelinesError::Client(err.msg))
4543                }
4544                "ForbiddenException" => {
4545                    return RusotoError::Service(ListImagePipelinesError::Forbidden(err.msg))
4546                }
4547                "InvalidPaginationTokenException" => {
4548                    return RusotoError::Service(ListImagePipelinesError::InvalidPaginationToken(
4549                        err.msg,
4550                    ))
4551                }
4552                "InvalidRequestException" => {
4553                    return RusotoError::Service(ListImagePipelinesError::InvalidRequest(err.msg))
4554                }
4555                "ServiceException" => {
4556                    return RusotoError::Service(ListImagePipelinesError::Service(err.msg))
4557                }
4558                "ServiceUnavailableException" => {
4559                    return RusotoError::Service(ListImagePipelinesError::ServiceUnavailable(
4560                        err.msg,
4561                    ))
4562                }
4563                "ValidationException" => return RusotoError::Validation(err.msg),
4564                _ => {}
4565            }
4566        }
4567        RusotoError::Unknown(res)
4568    }
4569}
4570impl fmt::Display for ListImagePipelinesError {
4571    #[allow(unused_variables)]
4572    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4573        match *self {
4574            ListImagePipelinesError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
4575            ListImagePipelinesError::Client(ref cause) => write!(f, "{}", cause),
4576            ListImagePipelinesError::Forbidden(ref cause) => write!(f, "{}", cause),
4577            ListImagePipelinesError::InvalidPaginationToken(ref cause) => write!(f, "{}", cause),
4578            ListImagePipelinesError::InvalidRequest(ref cause) => write!(f, "{}", cause),
4579            ListImagePipelinesError::Service(ref cause) => write!(f, "{}", cause),
4580            ListImagePipelinesError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
4581        }
4582    }
4583}
4584impl Error for ListImagePipelinesError {}
4585/// Errors returned by ListImageRecipes
4586#[derive(Debug, PartialEq)]
4587pub enum ListImageRecipesError {
4588    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
4589    CallRateLimitExceeded(String),
4590    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
4591    Client(String),
4592    /// <p>You are not authorized to perform the requested operation.</p>
4593    Forbidden(String),
4594    /// <p>You have provided an invalid pagination token in your request.</p>
4595    InvalidPaginationToken(String),
4596    /// <p>You have made a request for an action that is not supported by the service.</p>
4597    InvalidRequest(String),
4598    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4599    Service(String),
4600    /// <p>The service is unable to process your request at this time.</p>
4601    ServiceUnavailable(String),
4602}
4603
4604impl ListImageRecipesError {
4605    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListImageRecipesError> {
4606        if let Some(err) = proto::json::Error::parse_rest(&res) {
4607            match err.typ.as_str() {
4608                "CallRateLimitExceededException" => {
4609                    return RusotoError::Service(ListImageRecipesError::CallRateLimitExceeded(
4610                        err.msg,
4611                    ))
4612                }
4613                "ClientException" => {
4614                    return RusotoError::Service(ListImageRecipesError::Client(err.msg))
4615                }
4616                "ForbiddenException" => {
4617                    return RusotoError::Service(ListImageRecipesError::Forbidden(err.msg))
4618                }
4619                "InvalidPaginationTokenException" => {
4620                    return RusotoError::Service(ListImageRecipesError::InvalidPaginationToken(
4621                        err.msg,
4622                    ))
4623                }
4624                "InvalidRequestException" => {
4625                    return RusotoError::Service(ListImageRecipesError::InvalidRequest(err.msg))
4626                }
4627                "ServiceException" => {
4628                    return RusotoError::Service(ListImageRecipesError::Service(err.msg))
4629                }
4630                "ServiceUnavailableException" => {
4631                    return RusotoError::Service(ListImageRecipesError::ServiceUnavailable(err.msg))
4632                }
4633                "ValidationException" => return RusotoError::Validation(err.msg),
4634                _ => {}
4635            }
4636        }
4637        RusotoError::Unknown(res)
4638    }
4639}
4640impl fmt::Display for ListImageRecipesError {
4641    #[allow(unused_variables)]
4642    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4643        match *self {
4644            ListImageRecipesError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
4645            ListImageRecipesError::Client(ref cause) => write!(f, "{}", cause),
4646            ListImageRecipesError::Forbidden(ref cause) => write!(f, "{}", cause),
4647            ListImageRecipesError::InvalidPaginationToken(ref cause) => write!(f, "{}", cause),
4648            ListImageRecipesError::InvalidRequest(ref cause) => write!(f, "{}", cause),
4649            ListImageRecipesError::Service(ref cause) => write!(f, "{}", cause),
4650            ListImageRecipesError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
4651        }
4652    }
4653}
4654impl Error for ListImageRecipesError {}
4655/// Errors returned by ListImages
4656#[derive(Debug, PartialEq)]
4657pub enum ListImagesError {
4658    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
4659    CallRateLimitExceeded(String),
4660    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
4661    Client(String),
4662    /// <p>You are not authorized to perform the requested operation.</p>
4663    Forbidden(String),
4664    /// <p>You have provided an invalid pagination token in your request.</p>
4665    InvalidPaginationToken(String),
4666    /// <p>You have made a request for an action that is not supported by the service.</p>
4667    InvalidRequest(String),
4668    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4669    Service(String),
4670    /// <p>The service is unable to process your request at this time.</p>
4671    ServiceUnavailable(String),
4672}
4673
4674impl ListImagesError {
4675    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListImagesError> {
4676        if let Some(err) = proto::json::Error::parse_rest(&res) {
4677            match err.typ.as_str() {
4678                "CallRateLimitExceededException" => {
4679                    return RusotoError::Service(ListImagesError::CallRateLimitExceeded(err.msg))
4680                }
4681                "ClientException" => return RusotoError::Service(ListImagesError::Client(err.msg)),
4682                "ForbiddenException" => {
4683                    return RusotoError::Service(ListImagesError::Forbidden(err.msg))
4684                }
4685                "InvalidPaginationTokenException" => {
4686                    return RusotoError::Service(ListImagesError::InvalidPaginationToken(err.msg))
4687                }
4688                "InvalidRequestException" => {
4689                    return RusotoError::Service(ListImagesError::InvalidRequest(err.msg))
4690                }
4691                "ServiceException" => {
4692                    return RusotoError::Service(ListImagesError::Service(err.msg))
4693                }
4694                "ServiceUnavailableException" => {
4695                    return RusotoError::Service(ListImagesError::ServiceUnavailable(err.msg))
4696                }
4697                "ValidationException" => return RusotoError::Validation(err.msg),
4698                _ => {}
4699            }
4700        }
4701        RusotoError::Unknown(res)
4702    }
4703}
4704impl fmt::Display for ListImagesError {
4705    #[allow(unused_variables)]
4706    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4707        match *self {
4708            ListImagesError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
4709            ListImagesError::Client(ref cause) => write!(f, "{}", cause),
4710            ListImagesError::Forbidden(ref cause) => write!(f, "{}", cause),
4711            ListImagesError::InvalidPaginationToken(ref cause) => write!(f, "{}", cause),
4712            ListImagesError::InvalidRequest(ref cause) => write!(f, "{}", cause),
4713            ListImagesError::Service(ref cause) => write!(f, "{}", cause),
4714            ListImagesError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
4715        }
4716    }
4717}
4718impl Error for ListImagesError {}
4719/// Errors returned by ListInfrastructureConfigurations
4720#[derive(Debug, PartialEq)]
4721pub enum ListInfrastructureConfigurationsError {
4722    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
4723    CallRateLimitExceeded(String),
4724    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
4725    Client(String),
4726    /// <p>You are not authorized to perform the requested operation.</p>
4727    Forbidden(String),
4728    /// <p>You have provided an invalid pagination token in your request.</p>
4729    InvalidPaginationToken(String),
4730    /// <p>You have made a request for an action that is not supported by the service.</p>
4731    InvalidRequest(String),
4732    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4733    Service(String),
4734    /// <p>The service is unable to process your request at this time.</p>
4735    ServiceUnavailable(String),
4736}
4737
4738impl ListInfrastructureConfigurationsError {
4739    pub fn from_response(
4740        res: BufferedHttpResponse,
4741    ) -> RusotoError<ListInfrastructureConfigurationsError> {
4742        if let Some(err) = proto::json::Error::parse_rest(&res) {
4743            match err.typ.as_str() {
4744                "CallRateLimitExceededException" => {
4745                    return RusotoError::Service(
4746                        ListInfrastructureConfigurationsError::CallRateLimitExceeded(err.msg),
4747                    )
4748                }
4749                "ClientException" => {
4750                    return RusotoError::Service(ListInfrastructureConfigurationsError::Client(
4751                        err.msg,
4752                    ))
4753                }
4754                "ForbiddenException" => {
4755                    return RusotoError::Service(ListInfrastructureConfigurationsError::Forbidden(
4756                        err.msg,
4757                    ))
4758                }
4759                "InvalidPaginationTokenException" => {
4760                    return RusotoError::Service(
4761                        ListInfrastructureConfigurationsError::InvalidPaginationToken(err.msg),
4762                    )
4763                }
4764                "InvalidRequestException" => {
4765                    return RusotoError::Service(
4766                        ListInfrastructureConfigurationsError::InvalidRequest(err.msg),
4767                    )
4768                }
4769                "ServiceException" => {
4770                    return RusotoError::Service(ListInfrastructureConfigurationsError::Service(
4771                        err.msg,
4772                    ))
4773                }
4774                "ServiceUnavailableException" => {
4775                    return RusotoError::Service(
4776                        ListInfrastructureConfigurationsError::ServiceUnavailable(err.msg),
4777                    )
4778                }
4779                "ValidationException" => return RusotoError::Validation(err.msg),
4780                _ => {}
4781            }
4782        }
4783        RusotoError::Unknown(res)
4784    }
4785}
4786impl fmt::Display for ListInfrastructureConfigurationsError {
4787    #[allow(unused_variables)]
4788    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4789        match *self {
4790            ListInfrastructureConfigurationsError::CallRateLimitExceeded(ref cause) => {
4791                write!(f, "{}", cause)
4792            }
4793            ListInfrastructureConfigurationsError::Client(ref cause) => write!(f, "{}", cause),
4794            ListInfrastructureConfigurationsError::Forbidden(ref cause) => write!(f, "{}", cause),
4795            ListInfrastructureConfigurationsError::InvalidPaginationToken(ref cause) => {
4796                write!(f, "{}", cause)
4797            }
4798            ListInfrastructureConfigurationsError::InvalidRequest(ref cause) => {
4799                write!(f, "{}", cause)
4800            }
4801            ListInfrastructureConfigurationsError::Service(ref cause) => write!(f, "{}", cause),
4802            ListInfrastructureConfigurationsError::ServiceUnavailable(ref cause) => {
4803                write!(f, "{}", cause)
4804            }
4805        }
4806    }
4807}
4808impl Error for ListInfrastructureConfigurationsError {}
4809/// Errors returned by ListTagsForResource
4810#[derive(Debug, PartialEq)]
4811pub enum ListTagsForResourceError {
4812    /// <p>The specified parameter is invalid. Review the available parameters for the API request.</p>
4813    InvalidParameter(String),
4814    /// <p>At least one of the resources referenced by your request does not exist.</p>
4815    ResourceNotFound(String),
4816    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4817    Service(String),
4818}
4819
4820impl ListTagsForResourceError {
4821    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListTagsForResourceError> {
4822        if let Some(err) = proto::json::Error::parse_rest(&res) {
4823            match err.typ.as_str() {
4824                "InvalidParameterException" => {
4825                    return RusotoError::Service(ListTagsForResourceError::InvalidParameter(
4826                        err.msg,
4827                    ))
4828                }
4829                "ResourceNotFoundException" => {
4830                    return RusotoError::Service(ListTagsForResourceError::ResourceNotFound(
4831                        err.msg,
4832                    ))
4833                }
4834                "ServiceException" => {
4835                    return RusotoError::Service(ListTagsForResourceError::Service(err.msg))
4836                }
4837                "ValidationException" => return RusotoError::Validation(err.msg),
4838                _ => {}
4839            }
4840        }
4841        RusotoError::Unknown(res)
4842    }
4843}
4844impl fmt::Display for ListTagsForResourceError {
4845    #[allow(unused_variables)]
4846    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4847        match *self {
4848            ListTagsForResourceError::InvalidParameter(ref cause) => write!(f, "{}", cause),
4849            ListTagsForResourceError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4850            ListTagsForResourceError::Service(ref cause) => write!(f, "{}", cause),
4851        }
4852    }
4853}
4854impl Error for ListTagsForResourceError {}
4855/// Errors returned by PutComponentPolicy
4856#[derive(Debug, PartialEq)]
4857pub enum PutComponentPolicyError {
4858    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
4859    CallRateLimitExceeded(String),
4860    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
4861    Client(String),
4862    /// <p>You are not authorized to perform the requested operation.</p>
4863    Forbidden(String),
4864    /// <p>The value that you provided for the specified parameter is invalid.</p>
4865    InvalidParameterValue(String),
4866    /// <p>You have made a request for an action that is not supported by the service.</p>
4867    InvalidRequest(String),
4868    /// <p>At least one of the resources referenced by your request does not exist.</p>
4869    ResourceNotFound(String),
4870    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4871    Service(String),
4872    /// <p>The service is unable to process your request at this time.</p>
4873    ServiceUnavailable(String),
4874}
4875
4876impl PutComponentPolicyError {
4877    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<PutComponentPolicyError> {
4878        if let Some(err) = proto::json::Error::parse_rest(&res) {
4879            match err.typ.as_str() {
4880                "CallRateLimitExceededException" => {
4881                    return RusotoError::Service(PutComponentPolicyError::CallRateLimitExceeded(
4882                        err.msg,
4883                    ))
4884                }
4885                "ClientException" => {
4886                    return RusotoError::Service(PutComponentPolicyError::Client(err.msg))
4887                }
4888                "ForbiddenException" => {
4889                    return RusotoError::Service(PutComponentPolicyError::Forbidden(err.msg))
4890                }
4891                "InvalidParameterValueException" => {
4892                    return RusotoError::Service(PutComponentPolicyError::InvalidParameterValue(
4893                        err.msg,
4894                    ))
4895                }
4896                "InvalidRequestException" => {
4897                    return RusotoError::Service(PutComponentPolicyError::InvalidRequest(err.msg))
4898                }
4899                "ResourceNotFoundException" => {
4900                    return RusotoError::Service(PutComponentPolicyError::ResourceNotFound(err.msg))
4901                }
4902                "ServiceException" => {
4903                    return RusotoError::Service(PutComponentPolicyError::Service(err.msg))
4904                }
4905                "ServiceUnavailableException" => {
4906                    return RusotoError::Service(PutComponentPolicyError::ServiceUnavailable(
4907                        err.msg,
4908                    ))
4909                }
4910                "ValidationException" => return RusotoError::Validation(err.msg),
4911                _ => {}
4912            }
4913        }
4914        RusotoError::Unknown(res)
4915    }
4916}
4917impl fmt::Display for PutComponentPolicyError {
4918    #[allow(unused_variables)]
4919    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4920        match *self {
4921            PutComponentPolicyError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
4922            PutComponentPolicyError::Client(ref cause) => write!(f, "{}", cause),
4923            PutComponentPolicyError::Forbidden(ref cause) => write!(f, "{}", cause),
4924            PutComponentPolicyError::InvalidParameterValue(ref cause) => write!(f, "{}", cause),
4925            PutComponentPolicyError::InvalidRequest(ref cause) => write!(f, "{}", cause),
4926            PutComponentPolicyError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4927            PutComponentPolicyError::Service(ref cause) => write!(f, "{}", cause),
4928            PutComponentPolicyError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
4929        }
4930    }
4931}
4932impl Error for PutComponentPolicyError {}
4933/// Errors returned by PutImagePolicy
4934#[derive(Debug, PartialEq)]
4935pub enum PutImagePolicyError {
4936    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
4937    CallRateLimitExceeded(String),
4938    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
4939    Client(String),
4940    /// <p>You are not authorized to perform the requested operation.</p>
4941    Forbidden(String),
4942    /// <p>The value that you provided for the specified parameter is invalid.</p>
4943    InvalidParameterValue(String),
4944    /// <p>You have made a request for an action that is not supported by the service.</p>
4945    InvalidRequest(String),
4946    /// <p>At least one of the resources referenced by your request does not exist.</p>
4947    ResourceNotFound(String),
4948    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
4949    Service(String),
4950    /// <p>The service is unable to process your request at this time.</p>
4951    ServiceUnavailable(String),
4952}
4953
4954impl PutImagePolicyError {
4955    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<PutImagePolicyError> {
4956        if let Some(err) = proto::json::Error::parse_rest(&res) {
4957            match err.typ.as_str() {
4958                "CallRateLimitExceededException" => {
4959                    return RusotoError::Service(PutImagePolicyError::CallRateLimitExceeded(
4960                        err.msg,
4961                    ))
4962                }
4963                "ClientException" => {
4964                    return RusotoError::Service(PutImagePolicyError::Client(err.msg))
4965                }
4966                "ForbiddenException" => {
4967                    return RusotoError::Service(PutImagePolicyError::Forbidden(err.msg))
4968                }
4969                "InvalidParameterValueException" => {
4970                    return RusotoError::Service(PutImagePolicyError::InvalidParameterValue(
4971                        err.msg,
4972                    ))
4973                }
4974                "InvalidRequestException" => {
4975                    return RusotoError::Service(PutImagePolicyError::InvalidRequest(err.msg))
4976                }
4977                "ResourceNotFoundException" => {
4978                    return RusotoError::Service(PutImagePolicyError::ResourceNotFound(err.msg))
4979                }
4980                "ServiceException" => {
4981                    return RusotoError::Service(PutImagePolicyError::Service(err.msg))
4982                }
4983                "ServiceUnavailableException" => {
4984                    return RusotoError::Service(PutImagePolicyError::ServiceUnavailable(err.msg))
4985                }
4986                "ValidationException" => return RusotoError::Validation(err.msg),
4987                _ => {}
4988            }
4989        }
4990        RusotoError::Unknown(res)
4991    }
4992}
4993impl fmt::Display for PutImagePolicyError {
4994    #[allow(unused_variables)]
4995    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4996        match *self {
4997            PutImagePolicyError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
4998            PutImagePolicyError::Client(ref cause) => write!(f, "{}", cause),
4999            PutImagePolicyError::Forbidden(ref cause) => write!(f, "{}", cause),
5000            PutImagePolicyError::InvalidParameterValue(ref cause) => write!(f, "{}", cause),
5001            PutImagePolicyError::InvalidRequest(ref cause) => write!(f, "{}", cause),
5002            PutImagePolicyError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5003            PutImagePolicyError::Service(ref cause) => write!(f, "{}", cause),
5004            PutImagePolicyError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
5005        }
5006    }
5007}
5008impl Error for PutImagePolicyError {}
5009/// Errors returned by PutImageRecipePolicy
5010#[derive(Debug, PartialEq)]
5011pub enum PutImageRecipePolicyError {
5012    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
5013    CallRateLimitExceeded(String),
5014    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
5015    Client(String),
5016    /// <p>You are not authorized to perform the requested operation.</p>
5017    Forbidden(String),
5018    /// <p>The value that you provided for the specified parameter is invalid.</p>
5019    InvalidParameterValue(String),
5020    /// <p>You have made a request for an action that is not supported by the service.</p>
5021    InvalidRequest(String),
5022    /// <p>At least one of the resources referenced by your request does not exist.</p>
5023    ResourceNotFound(String),
5024    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
5025    Service(String),
5026    /// <p>The service is unable to process your request at this time.</p>
5027    ServiceUnavailable(String),
5028}
5029
5030impl PutImageRecipePolicyError {
5031    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<PutImageRecipePolicyError> {
5032        if let Some(err) = proto::json::Error::parse_rest(&res) {
5033            match err.typ.as_str() {
5034                "CallRateLimitExceededException" => {
5035                    return RusotoError::Service(PutImageRecipePolicyError::CallRateLimitExceeded(
5036                        err.msg,
5037                    ))
5038                }
5039                "ClientException" => {
5040                    return RusotoError::Service(PutImageRecipePolicyError::Client(err.msg))
5041                }
5042                "ForbiddenException" => {
5043                    return RusotoError::Service(PutImageRecipePolicyError::Forbidden(err.msg))
5044                }
5045                "InvalidParameterValueException" => {
5046                    return RusotoError::Service(PutImageRecipePolicyError::InvalidParameterValue(
5047                        err.msg,
5048                    ))
5049                }
5050                "InvalidRequestException" => {
5051                    return RusotoError::Service(PutImageRecipePolicyError::InvalidRequest(err.msg))
5052                }
5053                "ResourceNotFoundException" => {
5054                    return RusotoError::Service(PutImageRecipePolicyError::ResourceNotFound(
5055                        err.msg,
5056                    ))
5057                }
5058                "ServiceException" => {
5059                    return RusotoError::Service(PutImageRecipePolicyError::Service(err.msg))
5060                }
5061                "ServiceUnavailableException" => {
5062                    return RusotoError::Service(PutImageRecipePolicyError::ServiceUnavailable(
5063                        err.msg,
5064                    ))
5065                }
5066                "ValidationException" => return RusotoError::Validation(err.msg),
5067                _ => {}
5068            }
5069        }
5070        RusotoError::Unknown(res)
5071    }
5072}
5073impl fmt::Display for PutImageRecipePolicyError {
5074    #[allow(unused_variables)]
5075    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5076        match *self {
5077            PutImageRecipePolicyError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
5078            PutImageRecipePolicyError::Client(ref cause) => write!(f, "{}", cause),
5079            PutImageRecipePolicyError::Forbidden(ref cause) => write!(f, "{}", cause),
5080            PutImageRecipePolicyError::InvalidParameterValue(ref cause) => write!(f, "{}", cause),
5081            PutImageRecipePolicyError::InvalidRequest(ref cause) => write!(f, "{}", cause),
5082            PutImageRecipePolicyError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5083            PutImageRecipePolicyError::Service(ref cause) => write!(f, "{}", cause),
5084            PutImageRecipePolicyError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
5085        }
5086    }
5087}
5088impl Error for PutImageRecipePolicyError {}
5089/// Errors returned by StartImagePipelineExecution
5090#[derive(Debug, PartialEq)]
5091pub enum StartImagePipelineExecutionError {
5092    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
5093    CallRateLimitExceeded(String),
5094    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
5095    Client(String),
5096    /// <p>You are not authorized to perform the requested operation.</p>
5097    Forbidden(String),
5098    /// <p>You have specified a client token for an operation using parameter values that differ from a previous request that used the same client token.</p>
5099    IdempotentParameterMismatch(String),
5100    /// <p>You have made a request for an action that is not supported by the service.</p>
5101    InvalidRequest(String),
5102    /// <p>The resource that you are trying to operate on is currently in use. Review the message details and retry later.</p>
5103    ResourceInUse(String),
5104    /// <p>At least one of the resources referenced by your request does not exist.</p>
5105    ResourceNotFound(String),
5106    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
5107    Service(String),
5108    /// <p>The service is unable to process your request at this time.</p>
5109    ServiceUnavailable(String),
5110}
5111
5112impl StartImagePipelineExecutionError {
5113    pub fn from_response(
5114        res: BufferedHttpResponse,
5115    ) -> RusotoError<StartImagePipelineExecutionError> {
5116        if let Some(err) = proto::json::Error::parse_rest(&res) {
5117            match err.typ.as_str() {
5118                "CallRateLimitExceededException" => {
5119                    return RusotoError::Service(
5120                        StartImagePipelineExecutionError::CallRateLimitExceeded(err.msg),
5121                    )
5122                }
5123                "ClientException" => {
5124                    return RusotoError::Service(StartImagePipelineExecutionError::Client(err.msg))
5125                }
5126                "ForbiddenException" => {
5127                    return RusotoError::Service(StartImagePipelineExecutionError::Forbidden(
5128                        err.msg,
5129                    ))
5130                }
5131                "IdempotentParameterMismatchException" => {
5132                    return RusotoError::Service(
5133                        StartImagePipelineExecutionError::IdempotentParameterMismatch(err.msg),
5134                    )
5135                }
5136                "InvalidRequestException" => {
5137                    return RusotoError::Service(StartImagePipelineExecutionError::InvalidRequest(
5138                        err.msg,
5139                    ))
5140                }
5141                "ResourceInUseException" => {
5142                    return RusotoError::Service(StartImagePipelineExecutionError::ResourceInUse(
5143                        err.msg,
5144                    ))
5145                }
5146                "ResourceNotFoundException" => {
5147                    return RusotoError::Service(
5148                        StartImagePipelineExecutionError::ResourceNotFound(err.msg),
5149                    )
5150                }
5151                "ServiceException" => {
5152                    return RusotoError::Service(StartImagePipelineExecutionError::Service(err.msg))
5153                }
5154                "ServiceUnavailableException" => {
5155                    return RusotoError::Service(
5156                        StartImagePipelineExecutionError::ServiceUnavailable(err.msg),
5157                    )
5158                }
5159                "ValidationException" => return RusotoError::Validation(err.msg),
5160                _ => {}
5161            }
5162        }
5163        RusotoError::Unknown(res)
5164    }
5165}
5166impl fmt::Display for StartImagePipelineExecutionError {
5167    #[allow(unused_variables)]
5168    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5169        match *self {
5170            StartImagePipelineExecutionError::CallRateLimitExceeded(ref cause) => {
5171                write!(f, "{}", cause)
5172            }
5173            StartImagePipelineExecutionError::Client(ref cause) => write!(f, "{}", cause),
5174            StartImagePipelineExecutionError::Forbidden(ref cause) => write!(f, "{}", cause),
5175            StartImagePipelineExecutionError::IdempotentParameterMismatch(ref cause) => {
5176                write!(f, "{}", cause)
5177            }
5178            StartImagePipelineExecutionError::InvalidRequest(ref cause) => write!(f, "{}", cause),
5179            StartImagePipelineExecutionError::ResourceInUse(ref cause) => write!(f, "{}", cause),
5180            StartImagePipelineExecutionError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5181            StartImagePipelineExecutionError::Service(ref cause) => write!(f, "{}", cause),
5182            StartImagePipelineExecutionError::ServiceUnavailable(ref cause) => {
5183                write!(f, "{}", cause)
5184            }
5185        }
5186    }
5187}
5188impl Error for StartImagePipelineExecutionError {}
5189/// Errors returned by TagResource
5190#[derive(Debug, PartialEq)]
5191pub enum TagResourceError {
5192    /// <p>The specified parameter is invalid. Review the available parameters for the API request.</p>
5193    InvalidParameter(String),
5194    /// <p>At least one of the resources referenced by your request does not exist.</p>
5195    ResourceNotFound(String),
5196    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
5197    Service(String),
5198}
5199
5200impl TagResourceError {
5201    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<TagResourceError> {
5202        if let Some(err) = proto::json::Error::parse_rest(&res) {
5203            match err.typ.as_str() {
5204                "InvalidParameterException" => {
5205                    return RusotoError::Service(TagResourceError::InvalidParameter(err.msg))
5206                }
5207                "ResourceNotFoundException" => {
5208                    return RusotoError::Service(TagResourceError::ResourceNotFound(err.msg))
5209                }
5210                "ServiceException" => {
5211                    return RusotoError::Service(TagResourceError::Service(err.msg))
5212                }
5213                "ValidationException" => return RusotoError::Validation(err.msg),
5214                _ => {}
5215            }
5216        }
5217        RusotoError::Unknown(res)
5218    }
5219}
5220impl fmt::Display for TagResourceError {
5221    #[allow(unused_variables)]
5222    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5223        match *self {
5224            TagResourceError::InvalidParameter(ref cause) => write!(f, "{}", cause),
5225            TagResourceError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5226            TagResourceError::Service(ref cause) => write!(f, "{}", cause),
5227        }
5228    }
5229}
5230impl Error for TagResourceError {}
5231/// Errors returned by UntagResource
5232#[derive(Debug, PartialEq)]
5233pub enum UntagResourceError {
5234    /// <p>The specified parameter is invalid. Review the available parameters for the API request.</p>
5235    InvalidParameter(String),
5236    /// <p>At least one of the resources referenced by your request does not exist.</p>
5237    ResourceNotFound(String),
5238    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
5239    Service(String),
5240}
5241
5242impl UntagResourceError {
5243    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<UntagResourceError> {
5244        if let Some(err) = proto::json::Error::parse_rest(&res) {
5245            match err.typ.as_str() {
5246                "InvalidParameterException" => {
5247                    return RusotoError::Service(UntagResourceError::InvalidParameter(err.msg))
5248                }
5249                "ResourceNotFoundException" => {
5250                    return RusotoError::Service(UntagResourceError::ResourceNotFound(err.msg))
5251                }
5252                "ServiceException" => {
5253                    return RusotoError::Service(UntagResourceError::Service(err.msg))
5254                }
5255                "ValidationException" => return RusotoError::Validation(err.msg),
5256                _ => {}
5257            }
5258        }
5259        RusotoError::Unknown(res)
5260    }
5261}
5262impl fmt::Display for UntagResourceError {
5263    #[allow(unused_variables)]
5264    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5265        match *self {
5266            UntagResourceError::InvalidParameter(ref cause) => write!(f, "{}", cause),
5267            UntagResourceError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5268            UntagResourceError::Service(ref cause) => write!(f, "{}", cause),
5269        }
5270    }
5271}
5272impl Error for UntagResourceError {}
5273/// Errors returned by UpdateDistributionConfiguration
5274#[derive(Debug, PartialEq)]
5275pub enum UpdateDistributionConfigurationError {
5276    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
5277    CallRateLimitExceeded(String),
5278    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
5279    Client(String),
5280    /// <p>You are not authorized to perform the requested operation.</p>
5281    Forbidden(String),
5282    /// <p>You have specified a client token for an operation using parameter values that differ from a previous request that used the same client token.</p>
5283    IdempotentParameterMismatch(String),
5284    /// <p>You have specified two or more mutually exclusive parameters. Review the error message for details.</p>
5285    InvalidParameterCombination(String),
5286    /// <p>You have made a request for an action that is not supported by the service.</p>
5287    InvalidRequest(String),
5288    /// <p>The resource that you are trying to operate on is currently in use. Review the message details and retry later.</p>
5289    ResourceInUse(String),
5290    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
5291    Service(String),
5292    /// <p>The service is unable to process your request at this time.</p>
5293    ServiceUnavailable(String),
5294}
5295
5296impl UpdateDistributionConfigurationError {
5297    pub fn from_response(
5298        res: BufferedHttpResponse,
5299    ) -> RusotoError<UpdateDistributionConfigurationError> {
5300        if let Some(err) = proto::json::Error::parse_rest(&res) {
5301            match err.typ.as_str() {
5302                "CallRateLimitExceededException" => {
5303                    return RusotoError::Service(
5304                        UpdateDistributionConfigurationError::CallRateLimitExceeded(err.msg),
5305                    )
5306                }
5307                "ClientException" => {
5308                    return RusotoError::Service(UpdateDistributionConfigurationError::Client(
5309                        err.msg,
5310                    ))
5311                }
5312                "ForbiddenException" => {
5313                    return RusotoError::Service(UpdateDistributionConfigurationError::Forbidden(
5314                        err.msg,
5315                    ))
5316                }
5317                "IdempotentParameterMismatchException" => {
5318                    return RusotoError::Service(
5319                        UpdateDistributionConfigurationError::IdempotentParameterMismatch(err.msg),
5320                    )
5321                }
5322                "InvalidParameterCombinationException" => {
5323                    return RusotoError::Service(
5324                        UpdateDistributionConfigurationError::InvalidParameterCombination(err.msg),
5325                    )
5326                }
5327                "InvalidRequestException" => {
5328                    return RusotoError::Service(
5329                        UpdateDistributionConfigurationError::InvalidRequest(err.msg),
5330                    )
5331                }
5332                "ResourceInUseException" => {
5333                    return RusotoError::Service(
5334                        UpdateDistributionConfigurationError::ResourceInUse(err.msg),
5335                    )
5336                }
5337                "ServiceException" => {
5338                    return RusotoError::Service(UpdateDistributionConfigurationError::Service(
5339                        err.msg,
5340                    ))
5341                }
5342                "ServiceUnavailableException" => {
5343                    return RusotoError::Service(
5344                        UpdateDistributionConfigurationError::ServiceUnavailable(err.msg),
5345                    )
5346                }
5347                "ValidationException" => return RusotoError::Validation(err.msg),
5348                _ => {}
5349            }
5350        }
5351        RusotoError::Unknown(res)
5352    }
5353}
5354impl fmt::Display for UpdateDistributionConfigurationError {
5355    #[allow(unused_variables)]
5356    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5357        match *self {
5358            UpdateDistributionConfigurationError::CallRateLimitExceeded(ref cause) => {
5359                write!(f, "{}", cause)
5360            }
5361            UpdateDistributionConfigurationError::Client(ref cause) => write!(f, "{}", cause),
5362            UpdateDistributionConfigurationError::Forbidden(ref cause) => write!(f, "{}", cause),
5363            UpdateDistributionConfigurationError::IdempotentParameterMismatch(ref cause) => {
5364                write!(f, "{}", cause)
5365            }
5366            UpdateDistributionConfigurationError::InvalidParameterCombination(ref cause) => {
5367                write!(f, "{}", cause)
5368            }
5369            UpdateDistributionConfigurationError::InvalidRequest(ref cause) => {
5370                write!(f, "{}", cause)
5371            }
5372            UpdateDistributionConfigurationError::ResourceInUse(ref cause) => {
5373                write!(f, "{}", cause)
5374            }
5375            UpdateDistributionConfigurationError::Service(ref cause) => write!(f, "{}", cause),
5376            UpdateDistributionConfigurationError::ServiceUnavailable(ref cause) => {
5377                write!(f, "{}", cause)
5378            }
5379        }
5380    }
5381}
5382impl Error for UpdateDistributionConfigurationError {}
5383/// Errors returned by UpdateImagePipeline
5384#[derive(Debug, PartialEq)]
5385pub enum UpdateImagePipelineError {
5386    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
5387    CallRateLimitExceeded(String),
5388    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
5389    Client(String),
5390    /// <p>You are not authorized to perform the requested operation.</p>
5391    Forbidden(String),
5392    /// <p>You have specified a client token for an operation using parameter values that differ from a previous request that used the same client token.</p>
5393    IdempotentParameterMismatch(String),
5394    /// <p>You have made a request for an action that is not supported by the service.</p>
5395    InvalidRequest(String),
5396    /// <p>The resource that you are trying to operate on is currently in use. Review the message details and retry later.</p>
5397    ResourceInUse(String),
5398    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
5399    Service(String),
5400    /// <p>The service is unable to process your request at this time.</p>
5401    ServiceUnavailable(String),
5402}
5403
5404impl UpdateImagePipelineError {
5405    pub fn from_response(res: BufferedHttpResponse) -> RusotoError<UpdateImagePipelineError> {
5406        if let Some(err) = proto::json::Error::parse_rest(&res) {
5407            match err.typ.as_str() {
5408                "CallRateLimitExceededException" => {
5409                    return RusotoError::Service(UpdateImagePipelineError::CallRateLimitExceeded(
5410                        err.msg,
5411                    ))
5412                }
5413                "ClientException" => {
5414                    return RusotoError::Service(UpdateImagePipelineError::Client(err.msg))
5415                }
5416                "ForbiddenException" => {
5417                    return RusotoError::Service(UpdateImagePipelineError::Forbidden(err.msg))
5418                }
5419                "IdempotentParameterMismatchException" => {
5420                    return RusotoError::Service(
5421                        UpdateImagePipelineError::IdempotentParameterMismatch(err.msg),
5422                    )
5423                }
5424                "InvalidRequestException" => {
5425                    return RusotoError::Service(UpdateImagePipelineError::InvalidRequest(err.msg))
5426                }
5427                "ResourceInUseException" => {
5428                    return RusotoError::Service(UpdateImagePipelineError::ResourceInUse(err.msg))
5429                }
5430                "ServiceException" => {
5431                    return RusotoError::Service(UpdateImagePipelineError::Service(err.msg))
5432                }
5433                "ServiceUnavailableException" => {
5434                    return RusotoError::Service(UpdateImagePipelineError::ServiceUnavailable(
5435                        err.msg,
5436                    ))
5437                }
5438                "ValidationException" => return RusotoError::Validation(err.msg),
5439                _ => {}
5440            }
5441        }
5442        RusotoError::Unknown(res)
5443    }
5444}
5445impl fmt::Display for UpdateImagePipelineError {
5446    #[allow(unused_variables)]
5447    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5448        match *self {
5449            UpdateImagePipelineError::CallRateLimitExceeded(ref cause) => write!(f, "{}", cause),
5450            UpdateImagePipelineError::Client(ref cause) => write!(f, "{}", cause),
5451            UpdateImagePipelineError::Forbidden(ref cause) => write!(f, "{}", cause),
5452            UpdateImagePipelineError::IdempotentParameterMismatch(ref cause) => {
5453                write!(f, "{}", cause)
5454            }
5455            UpdateImagePipelineError::InvalidRequest(ref cause) => write!(f, "{}", cause),
5456            UpdateImagePipelineError::ResourceInUse(ref cause) => write!(f, "{}", cause),
5457            UpdateImagePipelineError::Service(ref cause) => write!(f, "{}", cause),
5458            UpdateImagePipelineError::ServiceUnavailable(ref cause) => write!(f, "{}", cause),
5459        }
5460    }
5461}
5462impl Error for UpdateImagePipelineError {}
5463/// Errors returned by UpdateInfrastructureConfiguration
5464#[derive(Debug, PartialEq)]
5465pub enum UpdateInfrastructureConfigurationError {
5466    /// <p>You have exceeded the permitted request rate for the specific operation.</p>
5467    CallRateLimitExceeded(String),
5468    /// <p>These errors are usually caused by a client action, such as using an action or resource on behalf of a user that doesn't have permissions to use the action or resource, or specifying an invalid resource identifier.</p>
5469    Client(String),
5470    /// <p>You are not authorized to perform the requested operation.</p>
5471    Forbidden(String),
5472    /// <p>You have specified a client token for an operation using parameter values that differ from a previous request that used the same client token.</p>
5473    IdempotentParameterMismatch(String),
5474    /// <p>You have made a request for an action that is not supported by the service.</p>
5475    InvalidRequest(String),
5476    /// <p>The resource that you are trying to operate on is currently in use. Review the message details and retry later.</p>
5477    ResourceInUse(String),
5478    /// <p>This exception is thrown when the service encounters an unrecoverable exception.</p>
5479    Service(String),
5480    /// <p>The service is unable to process your request at this time.</p>
5481    ServiceUnavailable(String),
5482}
5483
5484impl UpdateInfrastructureConfigurationError {
5485    pub fn from_response(
5486        res: BufferedHttpResponse,
5487    ) -> RusotoError<UpdateInfrastructureConfigurationError> {
5488        if let Some(err) = proto::json::Error::parse_rest(&res) {
5489            match err.typ.as_str() {
5490                "CallRateLimitExceededException" => {
5491                    return RusotoError::Service(
5492                        UpdateInfrastructureConfigurationError::CallRateLimitExceeded(err.msg),
5493                    )
5494                }
5495                "ClientException" => {
5496                    return RusotoError::Service(UpdateInfrastructureConfigurationError::Client(
5497                        err.msg,
5498                    ))
5499                }
5500                "ForbiddenException" => {
5501                    return RusotoError::Service(UpdateInfrastructureConfigurationError::Forbidden(
5502                        err.msg,
5503                    ))
5504                }
5505                "IdempotentParameterMismatchException" => {
5506                    return RusotoError::Service(
5507                        UpdateInfrastructureConfigurationError::IdempotentParameterMismatch(
5508                            err.msg,
5509                        ),
5510                    )
5511                }
5512                "InvalidRequestException" => {
5513                    return RusotoError::Service(
5514                        UpdateInfrastructureConfigurationError::InvalidRequest(err.msg),
5515                    )
5516                }
5517                "ResourceInUseException" => {
5518                    return RusotoError::Service(
5519                        UpdateInfrastructureConfigurationError::ResourceInUse(err.msg),
5520                    )
5521                }
5522                "ServiceException" => {
5523                    return RusotoError::Service(UpdateInfrastructureConfigurationError::Service(
5524                        err.msg,
5525                    ))
5526                }
5527                "ServiceUnavailableException" => {
5528                    return RusotoError::Service(
5529                        UpdateInfrastructureConfigurationError::ServiceUnavailable(err.msg),
5530                    )
5531                }
5532                "ValidationException" => return RusotoError::Validation(err.msg),
5533                _ => {}
5534            }
5535        }
5536        RusotoError::Unknown(res)
5537    }
5538}
5539impl fmt::Display for UpdateInfrastructureConfigurationError {
5540    #[allow(unused_variables)]
5541    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5542        match *self {
5543            UpdateInfrastructureConfigurationError::CallRateLimitExceeded(ref cause) => {
5544                write!(f, "{}", cause)
5545            }
5546            UpdateInfrastructureConfigurationError::Client(ref cause) => write!(f, "{}", cause),
5547            UpdateInfrastructureConfigurationError::Forbidden(ref cause) => write!(f, "{}", cause),
5548            UpdateInfrastructureConfigurationError::IdempotentParameterMismatch(ref cause) => {
5549                write!(f, "{}", cause)
5550            }
5551            UpdateInfrastructureConfigurationError::InvalidRequest(ref cause) => {
5552                write!(f, "{}", cause)
5553            }
5554            UpdateInfrastructureConfigurationError::ResourceInUse(ref cause) => {
5555                write!(f, "{}", cause)
5556            }
5557            UpdateInfrastructureConfigurationError::Service(ref cause) => write!(f, "{}", cause),
5558            UpdateInfrastructureConfigurationError::ServiceUnavailable(ref cause) => {
5559                write!(f, "{}", cause)
5560            }
5561        }
5562    }
5563}
5564impl Error for UpdateInfrastructureConfigurationError {}
5565/// Trait representing the capabilities of the imagebuilder API. imagebuilder clients implement this trait.
5566#[async_trait]
5567pub trait ImageBuilder {
5568    /// <p>CancelImageCreation cancels the creation of Image. This operation can only be used on images in a non-terminal state.</p>
5569    async fn cancel_image_creation(
5570        &self,
5571        input: CancelImageCreationRequest,
5572    ) -> Result<CancelImageCreationResponse, RusotoError<CancelImageCreationError>>;
5573
5574    /// <p>Creates a new component that can be used to build, validate, test, and assess your image.</p>
5575    async fn create_component(
5576        &self,
5577        input: CreateComponentRequest,
5578    ) -> Result<CreateComponentResponse, RusotoError<CreateComponentError>>;
5579
5580    /// <p>Creates a new distribution configuration. Distribution configurations define and configure the outputs of your pipeline. </p>
5581    async fn create_distribution_configuration(
5582        &self,
5583        input: CreateDistributionConfigurationRequest,
5584    ) -> Result<
5585        CreateDistributionConfigurationResponse,
5586        RusotoError<CreateDistributionConfigurationError>,
5587    >;
5588
5589    /// <p> Creates a new image. This request will create a new image along with all of the configured output resources defined in the distribution configuration. </p>
5590    async fn create_image(
5591        &self,
5592        input: CreateImageRequest,
5593    ) -> Result<CreateImageResponse, RusotoError<CreateImageError>>;
5594
5595    /// <p> Creates a new image pipeline. Image pipelines enable you to automate the creation and distribution of images. </p>
5596    async fn create_image_pipeline(
5597        &self,
5598        input: CreateImagePipelineRequest,
5599    ) -> Result<CreateImagePipelineResponse, RusotoError<CreateImagePipelineError>>;
5600
5601    /// <p> Creates a new image recipe. Image recipes define how images are configured, tested, and assessed. </p>
5602    async fn create_image_recipe(
5603        &self,
5604        input: CreateImageRecipeRequest,
5605    ) -> Result<CreateImageRecipeResponse, RusotoError<CreateImageRecipeError>>;
5606
5607    /// <p> Creates a new infrastructure configuration. An infrastructure configuration defines the environment in which your image will be built and tested. </p>
5608    async fn create_infrastructure_configuration(
5609        &self,
5610        input: CreateInfrastructureConfigurationRequest,
5611    ) -> Result<
5612        CreateInfrastructureConfigurationResponse,
5613        RusotoError<CreateInfrastructureConfigurationError>,
5614    >;
5615
5616    /// <p> Deletes a component build version. </p>
5617    async fn delete_component(
5618        &self,
5619        input: DeleteComponentRequest,
5620    ) -> Result<DeleteComponentResponse, RusotoError<DeleteComponentError>>;
5621
5622    /// <p> Deletes a distribution configuration. </p>
5623    async fn delete_distribution_configuration(
5624        &self,
5625        input: DeleteDistributionConfigurationRequest,
5626    ) -> Result<
5627        DeleteDistributionConfigurationResponse,
5628        RusotoError<DeleteDistributionConfigurationError>,
5629    >;
5630
5631    /// <p> Deletes an image. </p>
5632    async fn delete_image(
5633        &self,
5634        input: DeleteImageRequest,
5635    ) -> Result<DeleteImageResponse, RusotoError<DeleteImageError>>;
5636
5637    /// <p> Deletes an image pipeline. </p>
5638    async fn delete_image_pipeline(
5639        &self,
5640        input: DeleteImagePipelineRequest,
5641    ) -> Result<DeleteImagePipelineResponse, RusotoError<DeleteImagePipelineError>>;
5642
5643    /// <p> Deletes an image recipe. </p>
5644    async fn delete_image_recipe(
5645        &self,
5646        input: DeleteImageRecipeRequest,
5647    ) -> Result<DeleteImageRecipeResponse, RusotoError<DeleteImageRecipeError>>;
5648
5649    /// <p> Deletes an infrastructure configuration. </p>
5650    async fn delete_infrastructure_configuration(
5651        &self,
5652        input: DeleteInfrastructureConfigurationRequest,
5653    ) -> Result<
5654        DeleteInfrastructureConfigurationResponse,
5655        RusotoError<DeleteInfrastructureConfigurationError>,
5656    >;
5657
5658    /// <p> Gets a component object. </p>
5659    async fn get_component(
5660        &self,
5661        input: GetComponentRequest,
5662    ) -> Result<GetComponentResponse, RusotoError<GetComponentError>>;
5663
5664    /// <p> Gets a component policy. </p>
5665    async fn get_component_policy(
5666        &self,
5667        input: GetComponentPolicyRequest,
5668    ) -> Result<GetComponentPolicyResponse, RusotoError<GetComponentPolicyError>>;
5669
5670    /// <p> Gets a distribution configuration. </p>
5671    async fn get_distribution_configuration(
5672        &self,
5673        input: GetDistributionConfigurationRequest,
5674    ) -> Result<GetDistributionConfigurationResponse, RusotoError<GetDistributionConfigurationError>>;
5675
5676    /// <p> Gets an image. </p>
5677    async fn get_image(
5678        &self,
5679        input: GetImageRequest,
5680    ) -> Result<GetImageResponse, RusotoError<GetImageError>>;
5681
5682    /// <p> Gets an image pipeline. </p>
5683    async fn get_image_pipeline(
5684        &self,
5685        input: GetImagePipelineRequest,
5686    ) -> Result<GetImagePipelineResponse, RusotoError<GetImagePipelineError>>;
5687
5688    /// <p> Gets an image policy. </p>
5689    async fn get_image_policy(
5690        &self,
5691        input: GetImagePolicyRequest,
5692    ) -> Result<GetImagePolicyResponse, RusotoError<GetImagePolicyError>>;
5693
5694    /// <p> Gets an image recipe. </p>
5695    async fn get_image_recipe(
5696        &self,
5697        input: GetImageRecipeRequest,
5698    ) -> Result<GetImageRecipeResponse, RusotoError<GetImageRecipeError>>;
5699
5700    /// <p> Gets an image recipe policy. </p>
5701    async fn get_image_recipe_policy(
5702        &self,
5703        input: GetImageRecipePolicyRequest,
5704    ) -> Result<GetImageRecipePolicyResponse, RusotoError<GetImageRecipePolicyError>>;
5705
5706    /// <p> Gets an infrastructure configuration. </p>
5707    async fn get_infrastructure_configuration(
5708        &self,
5709        input: GetInfrastructureConfigurationRequest,
5710    ) -> Result<
5711        GetInfrastructureConfigurationResponse,
5712        RusotoError<GetInfrastructureConfigurationError>,
5713    >;
5714
5715    /// <p>Imports a component and transforms its data into a component document. </p>
5716    async fn import_component(
5717        &self,
5718        input: ImportComponentRequest,
5719    ) -> Result<ImportComponentResponse, RusotoError<ImportComponentError>>;
5720
5721    /// <p> Returns the list of component build versions for the specified semantic version. </p>
5722    async fn list_component_build_versions(
5723        &self,
5724        input: ListComponentBuildVersionsRequest,
5725    ) -> Result<ListComponentBuildVersionsResponse, RusotoError<ListComponentBuildVersionsError>>;
5726
5727    /// <p>Returns the list of component build versions for the specified semantic version. </p>
5728    async fn list_components(
5729        &self,
5730        input: ListComponentsRequest,
5731    ) -> Result<ListComponentsResponse, RusotoError<ListComponentsError>>;
5732
5733    /// <p> Returns a list of distribution configurations. </p>
5734    async fn list_distribution_configurations(
5735        &self,
5736        input: ListDistributionConfigurationsRequest,
5737    ) -> Result<
5738        ListDistributionConfigurationsResponse,
5739        RusotoError<ListDistributionConfigurationsError>,
5740    >;
5741
5742    /// <p> Returns a list of image build versions. </p>
5743    async fn list_image_build_versions(
5744        &self,
5745        input: ListImageBuildVersionsRequest,
5746    ) -> Result<ListImageBuildVersionsResponse, RusotoError<ListImageBuildVersionsError>>;
5747
5748    /// <p> Returns a list of images created by the specified pipeline. </p>
5749    async fn list_image_pipeline_images(
5750        &self,
5751        input: ListImagePipelineImagesRequest,
5752    ) -> Result<ListImagePipelineImagesResponse, RusotoError<ListImagePipelineImagesError>>;
5753
5754    /// <p>Returns a list of image pipelines. </p>
5755    async fn list_image_pipelines(
5756        &self,
5757        input: ListImagePipelinesRequest,
5758    ) -> Result<ListImagePipelinesResponse, RusotoError<ListImagePipelinesError>>;
5759
5760    /// <p> Returns a list of image recipes. </p>
5761    async fn list_image_recipes(
5762        &self,
5763        input: ListImageRecipesRequest,
5764    ) -> Result<ListImageRecipesResponse, RusotoError<ListImageRecipesError>>;
5765
5766    /// <p> Returns the list of images that you have access to. </p>
5767    async fn list_images(
5768        &self,
5769        input: ListImagesRequest,
5770    ) -> Result<ListImagesResponse, RusotoError<ListImagesError>>;
5771
5772    /// <p> Returns a list of infrastructure configurations. </p>
5773    async fn list_infrastructure_configurations(
5774        &self,
5775        input: ListInfrastructureConfigurationsRequest,
5776    ) -> Result<
5777        ListInfrastructureConfigurationsResponse,
5778        RusotoError<ListInfrastructureConfigurationsError>,
5779    >;
5780
5781    /// <p> Returns the list of tags for the specified resource. </p>
5782    async fn list_tags_for_resource(
5783        &self,
5784        input: ListTagsForResourceRequest,
5785    ) -> Result<ListTagsForResourceResponse, RusotoError<ListTagsForResourceError>>;
5786
5787    /// <p> Applies a policy to a component. We recommend that you call the RAM API <a href="https://docs.aws.amazon.com/ram/latest/APIReference/API_CreateResourceShare.html">CreateResourceShare</a> to share resources. If you call the Image Builder API <code>PutComponentPolicy</code>, you must also call the RAM API <a href="https://docs.aws.amazon.com/ram/latest/APIReference/API_PromoteResourceShareCreatedFromPolicy.html">PromoteResourceShareCreatedFromPolicy</a> in order for the resource to be visible to all principals with whom the resource is shared. </p>
5788    async fn put_component_policy(
5789        &self,
5790        input: PutComponentPolicyRequest,
5791    ) -> Result<PutComponentPolicyResponse, RusotoError<PutComponentPolicyError>>;
5792
5793    /// <p>Applies a policy to an image. We recommend that you call the RAM API <a href="https://docs.aws.amazon.com/ram/latest/APIReference/API_CreateResourceShare.html">CreateResourceShare</a> to share resources. If you call the Image Builder API <code>PutImagePolicy</code>, you must also call the RAM API <a href="https://docs.aws.amazon.com/ram/latest/APIReference/API_PromoteResourceShareCreatedFromPolicy.html">PromoteResourceShareCreatedFromPolicy</a> in order for the resource to be visible to all principals with whom the resource is shared. </p>
5794    async fn put_image_policy(
5795        &self,
5796        input: PutImagePolicyRequest,
5797    ) -> Result<PutImagePolicyResponse, RusotoError<PutImagePolicyError>>;
5798
5799    /// <p> Applies a policy to an image recipe. We recommend that you call the RAM API <a href="https://docs.aws.amazon.com/ram/latest/APIReference/API_CreateResourceShare.html">CreateResourceShare</a> to share resources. If you call the Image Builder API <code>PutImageRecipePolicy</code>, you must also call the RAM API <a href="https://docs.aws.amazon.com/ram/latest/APIReference/API_PromoteResourceShareCreatedFromPolicy.html">PromoteResourceShareCreatedFromPolicy</a> in order for the resource to be visible to all principals with whom the resource is shared. </p>
5800    async fn put_image_recipe_policy(
5801        &self,
5802        input: PutImageRecipePolicyRequest,
5803    ) -> Result<PutImageRecipePolicyResponse, RusotoError<PutImageRecipePolicyError>>;
5804
5805    /// <p> Manually triggers a pipeline to create an image. </p>
5806    async fn start_image_pipeline_execution(
5807        &self,
5808        input: StartImagePipelineExecutionRequest,
5809    ) -> Result<StartImagePipelineExecutionResponse, RusotoError<StartImagePipelineExecutionError>>;
5810
5811    /// <p> Adds a tag to a resource. </p>
5812    async fn tag_resource(
5813        &self,
5814        input: TagResourceRequest,
5815    ) -> Result<TagResourceResponse, RusotoError<TagResourceError>>;
5816
5817    /// <p> Removes a tag from a resource. </p>
5818    async fn untag_resource(
5819        &self,
5820        input: UntagResourceRequest,
5821    ) -> Result<UntagResourceResponse, RusotoError<UntagResourceError>>;
5822
5823    /// <p> Updates a new distribution configuration. Distribution configurations define and configure the outputs of your pipeline. </p>
5824    async fn update_distribution_configuration(
5825        &self,
5826        input: UpdateDistributionConfigurationRequest,
5827    ) -> Result<
5828        UpdateDistributionConfigurationResponse,
5829        RusotoError<UpdateDistributionConfigurationError>,
5830    >;
5831
5832    /// <p> Updates a new image pipeline. Image pipelines enable you to automate the creation and distribution of images. </p>
5833    async fn update_image_pipeline(
5834        &self,
5835        input: UpdateImagePipelineRequest,
5836    ) -> Result<UpdateImagePipelineResponse, RusotoError<UpdateImagePipelineError>>;
5837
5838    /// <p> Updates a new infrastructure configuration. An infrastructure configuration defines the environment in which your image will be built and tested. </p>
5839    async fn update_infrastructure_configuration(
5840        &self,
5841        input: UpdateInfrastructureConfigurationRequest,
5842    ) -> Result<
5843        UpdateInfrastructureConfigurationResponse,
5844        RusotoError<UpdateInfrastructureConfigurationError>,
5845    >;
5846}
5847/// A client for the imagebuilder API.
5848#[derive(Clone)]
5849pub struct ImageBuilderClient {
5850    client: Client,
5851    region: region::Region,
5852}
5853
5854impl ImageBuilderClient {
5855    /// Creates a client backed by the default tokio event loop.
5856    ///
5857    /// The client will use the default credentials provider and tls client.
5858    pub fn new(region: region::Region) -> ImageBuilderClient {
5859        ImageBuilderClient {
5860            client: Client::shared(),
5861            region,
5862        }
5863    }
5864
5865    pub fn new_with<P, D>(
5866        request_dispatcher: D,
5867        credentials_provider: P,
5868        region: region::Region,
5869    ) -> ImageBuilderClient
5870    where
5871        P: ProvideAwsCredentials + Send + Sync + 'static,
5872        D: DispatchSignedRequest + Send + Sync + 'static,
5873    {
5874        ImageBuilderClient {
5875            client: Client::new_with(credentials_provider, request_dispatcher),
5876            region,
5877        }
5878    }
5879
5880    pub fn new_with_client(client: Client, region: region::Region) -> ImageBuilderClient {
5881        ImageBuilderClient { client, region }
5882    }
5883}
5884
5885#[async_trait]
5886impl ImageBuilder for ImageBuilderClient {
5887    /// <p>CancelImageCreation cancels the creation of Image. This operation can only be used on images in a non-terminal state.</p>
5888    #[allow(unused_mut)]
5889    async fn cancel_image_creation(
5890        &self,
5891        input: CancelImageCreationRequest,
5892    ) -> Result<CancelImageCreationResponse, RusotoError<CancelImageCreationError>> {
5893        let request_uri = "/CancelImageCreation";
5894
5895        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
5896        request.set_content_type("application/x-amz-json-1.1".to_owned());
5897
5898        let encoded = Some(serde_json::to_vec(&input).unwrap());
5899        request.set_payload(encoded);
5900
5901        let mut response = self
5902            .client
5903            .sign_and_dispatch(request)
5904            .await
5905            .map_err(RusotoError::from)?;
5906        if response.status.is_success() {
5907            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
5908            let result = proto::json::ResponsePayload::new(&response)
5909                .deserialize::<CancelImageCreationResponse, _>()?;
5910
5911            Ok(result)
5912        } else {
5913            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
5914            Err(CancelImageCreationError::from_response(response))
5915        }
5916    }
5917
5918    /// <p>Creates a new component that can be used to build, validate, test, and assess your image.</p>
5919    #[allow(unused_mut)]
5920    async fn create_component(
5921        &self,
5922        input: CreateComponentRequest,
5923    ) -> Result<CreateComponentResponse, RusotoError<CreateComponentError>> {
5924        let request_uri = "/CreateComponent";
5925
5926        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
5927        request.set_content_type("application/x-amz-json-1.1".to_owned());
5928
5929        let encoded = Some(serde_json::to_vec(&input).unwrap());
5930        request.set_payload(encoded);
5931
5932        let mut response = self
5933            .client
5934            .sign_and_dispatch(request)
5935            .await
5936            .map_err(RusotoError::from)?;
5937        if response.status.is_success() {
5938            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
5939            let result = proto::json::ResponsePayload::new(&response)
5940                .deserialize::<CreateComponentResponse, _>()?;
5941
5942            Ok(result)
5943        } else {
5944            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
5945            Err(CreateComponentError::from_response(response))
5946        }
5947    }
5948
5949    /// <p>Creates a new distribution configuration. Distribution configurations define and configure the outputs of your pipeline. </p>
5950    #[allow(unused_mut)]
5951    async fn create_distribution_configuration(
5952        &self,
5953        input: CreateDistributionConfigurationRequest,
5954    ) -> Result<
5955        CreateDistributionConfigurationResponse,
5956        RusotoError<CreateDistributionConfigurationError>,
5957    > {
5958        let request_uri = "/CreateDistributionConfiguration";
5959
5960        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
5961        request.set_content_type("application/x-amz-json-1.1".to_owned());
5962
5963        let encoded = Some(serde_json::to_vec(&input).unwrap());
5964        request.set_payload(encoded);
5965
5966        let mut response = self
5967            .client
5968            .sign_and_dispatch(request)
5969            .await
5970            .map_err(RusotoError::from)?;
5971        if response.status.is_success() {
5972            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
5973            let result = proto::json::ResponsePayload::new(&response)
5974                .deserialize::<CreateDistributionConfigurationResponse, _>()?;
5975
5976            Ok(result)
5977        } else {
5978            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
5979            Err(CreateDistributionConfigurationError::from_response(
5980                response,
5981            ))
5982        }
5983    }
5984
5985    /// <p> Creates a new image. This request will create a new image along with all of the configured output resources defined in the distribution configuration. </p>
5986    #[allow(unused_mut)]
5987    async fn create_image(
5988        &self,
5989        input: CreateImageRequest,
5990    ) -> Result<CreateImageResponse, RusotoError<CreateImageError>> {
5991        let request_uri = "/CreateImage";
5992
5993        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
5994        request.set_content_type("application/x-amz-json-1.1".to_owned());
5995
5996        let encoded = Some(serde_json::to_vec(&input).unwrap());
5997        request.set_payload(encoded);
5998
5999        let mut response = self
6000            .client
6001            .sign_and_dispatch(request)
6002            .await
6003            .map_err(RusotoError::from)?;
6004        if response.status.is_success() {
6005            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6006            let result = proto::json::ResponsePayload::new(&response)
6007                .deserialize::<CreateImageResponse, _>()?;
6008
6009            Ok(result)
6010        } else {
6011            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6012            Err(CreateImageError::from_response(response))
6013        }
6014    }
6015
6016    /// <p> Creates a new image pipeline. Image pipelines enable you to automate the creation and distribution of images. </p>
6017    #[allow(unused_mut)]
6018    async fn create_image_pipeline(
6019        &self,
6020        input: CreateImagePipelineRequest,
6021    ) -> Result<CreateImagePipelineResponse, RusotoError<CreateImagePipelineError>> {
6022        let request_uri = "/CreateImagePipeline";
6023
6024        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
6025        request.set_content_type("application/x-amz-json-1.1".to_owned());
6026
6027        let encoded = Some(serde_json::to_vec(&input).unwrap());
6028        request.set_payload(encoded);
6029
6030        let mut response = self
6031            .client
6032            .sign_and_dispatch(request)
6033            .await
6034            .map_err(RusotoError::from)?;
6035        if response.status.is_success() {
6036            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6037            let result = proto::json::ResponsePayload::new(&response)
6038                .deserialize::<CreateImagePipelineResponse, _>()?;
6039
6040            Ok(result)
6041        } else {
6042            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6043            Err(CreateImagePipelineError::from_response(response))
6044        }
6045    }
6046
6047    /// <p> Creates a new image recipe. Image recipes define how images are configured, tested, and assessed. </p>
6048    #[allow(unused_mut)]
6049    async fn create_image_recipe(
6050        &self,
6051        input: CreateImageRecipeRequest,
6052    ) -> Result<CreateImageRecipeResponse, RusotoError<CreateImageRecipeError>> {
6053        let request_uri = "/CreateImageRecipe";
6054
6055        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
6056        request.set_content_type("application/x-amz-json-1.1".to_owned());
6057
6058        let encoded = Some(serde_json::to_vec(&input).unwrap());
6059        request.set_payload(encoded);
6060
6061        let mut response = self
6062            .client
6063            .sign_and_dispatch(request)
6064            .await
6065            .map_err(RusotoError::from)?;
6066        if response.status.is_success() {
6067            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6068            let result = proto::json::ResponsePayload::new(&response)
6069                .deserialize::<CreateImageRecipeResponse, _>()?;
6070
6071            Ok(result)
6072        } else {
6073            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6074            Err(CreateImageRecipeError::from_response(response))
6075        }
6076    }
6077
6078    /// <p> Creates a new infrastructure configuration. An infrastructure configuration defines the environment in which your image will be built and tested. </p>
6079    #[allow(unused_mut)]
6080    async fn create_infrastructure_configuration(
6081        &self,
6082        input: CreateInfrastructureConfigurationRequest,
6083    ) -> Result<
6084        CreateInfrastructureConfigurationResponse,
6085        RusotoError<CreateInfrastructureConfigurationError>,
6086    > {
6087        let request_uri = "/CreateInfrastructureConfiguration";
6088
6089        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
6090        request.set_content_type("application/x-amz-json-1.1".to_owned());
6091
6092        let encoded = Some(serde_json::to_vec(&input).unwrap());
6093        request.set_payload(encoded);
6094
6095        let mut response = self
6096            .client
6097            .sign_and_dispatch(request)
6098            .await
6099            .map_err(RusotoError::from)?;
6100        if response.status.is_success() {
6101            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6102            let result = proto::json::ResponsePayload::new(&response)
6103                .deserialize::<CreateInfrastructureConfigurationResponse, _>()?;
6104
6105            Ok(result)
6106        } else {
6107            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6108            Err(CreateInfrastructureConfigurationError::from_response(
6109                response,
6110            ))
6111        }
6112    }
6113
6114    /// <p> Deletes a component build version. </p>
6115    #[allow(unused_mut)]
6116    async fn delete_component(
6117        &self,
6118        input: DeleteComponentRequest,
6119    ) -> Result<DeleteComponentResponse, RusotoError<DeleteComponentError>> {
6120        let request_uri = "/DeleteComponent";
6121
6122        let mut request = SignedRequest::new("DELETE", "imagebuilder", &self.region, &request_uri);
6123        request.set_content_type("application/x-amz-json-1.1".to_owned());
6124
6125        let mut params = Params::new();
6126        params.put(
6127            "componentBuildVersionArn",
6128            &input.component_build_version_arn,
6129        );
6130        request.set_params(params);
6131
6132        let mut response = self
6133            .client
6134            .sign_and_dispatch(request)
6135            .await
6136            .map_err(RusotoError::from)?;
6137        if response.status.is_success() {
6138            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6139            let result = proto::json::ResponsePayload::new(&response)
6140                .deserialize::<DeleteComponentResponse, _>()?;
6141
6142            Ok(result)
6143        } else {
6144            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6145            Err(DeleteComponentError::from_response(response))
6146        }
6147    }
6148
6149    /// <p> Deletes a distribution configuration. </p>
6150    #[allow(unused_mut)]
6151    async fn delete_distribution_configuration(
6152        &self,
6153        input: DeleteDistributionConfigurationRequest,
6154    ) -> Result<
6155        DeleteDistributionConfigurationResponse,
6156        RusotoError<DeleteDistributionConfigurationError>,
6157    > {
6158        let request_uri = "/DeleteDistributionConfiguration";
6159
6160        let mut request = SignedRequest::new("DELETE", "imagebuilder", &self.region, &request_uri);
6161        request.set_content_type("application/x-amz-json-1.1".to_owned());
6162
6163        let mut params = Params::new();
6164        params.put(
6165            "distributionConfigurationArn",
6166            &input.distribution_configuration_arn,
6167        );
6168        request.set_params(params);
6169
6170        let mut response = self
6171            .client
6172            .sign_and_dispatch(request)
6173            .await
6174            .map_err(RusotoError::from)?;
6175        if response.status.is_success() {
6176            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6177            let result = proto::json::ResponsePayload::new(&response)
6178                .deserialize::<DeleteDistributionConfigurationResponse, _>()?;
6179
6180            Ok(result)
6181        } else {
6182            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6183            Err(DeleteDistributionConfigurationError::from_response(
6184                response,
6185            ))
6186        }
6187    }
6188
6189    /// <p> Deletes an image. </p>
6190    #[allow(unused_mut)]
6191    async fn delete_image(
6192        &self,
6193        input: DeleteImageRequest,
6194    ) -> Result<DeleteImageResponse, RusotoError<DeleteImageError>> {
6195        let request_uri = "/DeleteImage";
6196
6197        let mut request = SignedRequest::new("DELETE", "imagebuilder", &self.region, &request_uri);
6198        request.set_content_type("application/x-amz-json-1.1".to_owned());
6199
6200        let mut params = Params::new();
6201        params.put("imageBuildVersionArn", &input.image_build_version_arn);
6202        request.set_params(params);
6203
6204        let mut response = self
6205            .client
6206            .sign_and_dispatch(request)
6207            .await
6208            .map_err(RusotoError::from)?;
6209        if response.status.is_success() {
6210            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6211            let result = proto::json::ResponsePayload::new(&response)
6212                .deserialize::<DeleteImageResponse, _>()?;
6213
6214            Ok(result)
6215        } else {
6216            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6217            Err(DeleteImageError::from_response(response))
6218        }
6219    }
6220
6221    /// <p> Deletes an image pipeline. </p>
6222    #[allow(unused_mut)]
6223    async fn delete_image_pipeline(
6224        &self,
6225        input: DeleteImagePipelineRequest,
6226    ) -> Result<DeleteImagePipelineResponse, RusotoError<DeleteImagePipelineError>> {
6227        let request_uri = "/DeleteImagePipeline";
6228
6229        let mut request = SignedRequest::new("DELETE", "imagebuilder", &self.region, &request_uri);
6230        request.set_content_type("application/x-amz-json-1.1".to_owned());
6231
6232        let mut params = Params::new();
6233        params.put("imagePipelineArn", &input.image_pipeline_arn);
6234        request.set_params(params);
6235
6236        let mut response = self
6237            .client
6238            .sign_and_dispatch(request)
6239            .await
6240            .map_err(RusotoError::from)?;
6241        if response.status.is_success() {
6242            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6243            let result = proto::json::ResponsePayload::new(&response)
6244                .deserialize::<DeleteImagePipelineResponse, _>()?;
6245
6246            Ok(result)
6247        } else {
6248            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6249            Err(DeleteImagePipelineError::from_response(response))
6250        }
6251    }
6252
6253    /// <p> Deletes an image recipe. </p>
6254    #[allow(unused_mut)]
6255    async fn delete_image_recipe(
6256        &self,
6257        input: DeleteImageRecipeRequest,
6258    ) -> Result<DeleteImageRecipeResponse, RusotoError<DeleteImageRecipeError>> {
6259        let request_uri = "/DeleteImageRecipe";
6260
6261        let mut request = SignedRequest::new("DELETE", "imagebuilder", &self.region, &request_uri);
6262        request.set_content_type("application/x-amz-json-1.1".to_owned());
6263
6264        let mut params = Params::new();
6265        params.put("imageRecipeArn", &input.image_recipe_arn);
6266        request.set_params(params);
6267
6268        let mut response = self
6269            .client
6270            .sign_and_dispatch(request)
6271            .await
6272            .map_err(RusotoError::from)?;
6273        if response.status.is_success() {
6274            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6275            let result = proto::json::ResponsePayload::new(&response)
6276                .deserialize::<DeleteImageRecipeResponse, _>()?;
6277
6278            Ok(result)
6279        } else {
6280            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6281            Err(DeleteImageRecipeError::from_response(response))
6282        }
6283    }
6284
6285    /// <p> Deletes an infrastructure configuration. </p>
6286    #[allow(unused_mut)]
6287    async fn delete_infrastructure_configuration(
6288        &self,
6289        input: DeleteInfrastructureConfigurationRequest,
6290    ) -> Result<
6291        DeleteInfrastructureConfigurationResponse,
6292        RusotoError<DeleteInfrastructureConfigurationError>,
6293    > {
6294        let request_uri = "/DeleteInfrastructureConfiguration";
6295
6296        let mut request = SignedRequest::new("DELETE", "imagebuilder", &self.region, &request_uri);
6297        request.set_content_type("application/x-amz-json-1.1".to_owned());
6298
6299        let mut params = Params::new();
6300        params.put(
6301            "infrastructureConfigurationArn",
6302            &input.infrastructure_configuration_arn,
6303        );
6304        request.set_params(params);
6305
6306        let mut response = self
6307            .client
6308            .sign_and_dispatch(request)
6309            .await
6310            .map_err(RusotoError::from)?;
6311        if response.status.is_success() {
6312            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6313            let result = proto::json::ResponsePayload::new(&response)
6314                .deserialize::<DeleteInfrastructureConfigurationResponse, _>()?;
6315
6316            Ok(result)
6317        } else {
6318            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6319            Err(DeleteInfrastructureConfigurationError::from_response(
6320                response,
6321            ))
6322        }
6323    }
6324
6325    /// <p> Gets a component object. </p>
6326    #[allow(unused_mut)]
6327    async fn get_component(
6328        &self,
6329        input: GetComponentRequest,
6330    ) -> Result<GetComponentResponse, RusotoError<GetComponentError>> {
6331        let request_uri = "/GetComponent";
6332
6333        let mut request = SignedRequest::new("GET", "imagebuilder", &self.region, &request_uri);
6334        request.set_content_type("application/x-amz-json-1.1".to_owned());
6335
6336        let mut params = Params::new();
6337        params.put(
6338            "componentBuildVersionArn",
6339            &input.component_build_version_arn,
6340        );
6341        request.set_params(params);
6342
6343        let mut response = self
6344            .client
6345            .sign_and_dispatch(request)
6346            .await
6347            .map_err(RusotoError::from)?;
6348        if response.status.is_success() {
6349            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6350            let result = proto::json::ResponsePayload::new(&response)
6351                .deserialize::<GetComponentResponse, _>()?;
6352
6353            Ok(result)
6354        } else {
6355            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6356            Err(GetComponentError::from_response(response))
6357        }
6358    }
6359
6360    /// <p> Gets a component policy. </p>
6361    #[allow(unused_mut)]
6362    async fn get_component_policy(
6363        &self,
6364        input: GetComponentPolicyRequest,
6365    ) -> Result<GetComponentPolicyResponse, RusotoError<GetComponentPolicyError>> {
6366        let request_uri = "/GetComponentPolicy";
6367
6368        let mut request = SignedRequest::new("GET", "imagebuilder", &self.region, &request_uri);
6369        request.set_content_type("application/x-amz-json-1.1".to_owned());
6370
6371        let mut params = Params::new();
6372        params.put("componentArn", &input.component_arn);
6373        request.set_params(params);
6374
6375        let mut response = self
6376            .client
6377            .sign_and_dispatch(request)
6378            .await
6379            .map_err(RusotoError::from)?;
6380        if response.status.is_success() {
6381            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6382            let result = proto::json::ResponsePayload::new(&response)
6383                .deserialize::<GetComponentPolicyResponse, _>()?;
6384
6385            Ok(result)
6386        } else {
6387            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6388            Err(GetComponentPolicyError::from_response(response))
6389        }
6390    }
6391
6392    /// <p> Gets a distribution configuration. </p>
6393    #[allow(unused_mut)]
6394    async fn get_distribution_configuration(
6395        &self,
6396        input: GetDistributionConfigurationRequest,
6397    ) -> Result<GetDistributionConfigurationResponse, RusotoError<GetDistributionConfigurationError>>
6398    {
6399        let request_uri = "/GetDistributionConfiguration";
6400
6401        let mut request = SignedRequest::new("GET", "imagebuilder", &self.region, &request_uri);
6402        request.set_content_type("application/x-amz-json-1.1".to_owned());
6403
6404        let mut params = Params::new();
6405        params.put(
6406            "distributionConfigurationArn",
6407            &input.distribution_configuration_arn,
6408        );
6409        request.set_params(params);
6410
6411        let mut response = self
6412            .client
6413            .sign_and_dispatch(request)
6414            .await
6415            .map_err(RusotoError::from)?;
6416        if response.status.is_success() {
6417            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6418            let result = proto::json::ResponsePayload::new(&response)
6419                .deserialize::<GetDistributionConfigurationResponse, _>()?;
6420
6421            Ok(result)
6422        } else {
6423            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6424            Err(GetDistributionConfigurationError::from_response(response))
6425        }
6426    }
6427
6428    /// <p> Gets an image. </p>
6429    #[allow(unused_mut)]
6430    async fn get_image(
6431        &self,
6432        input: GetImageRequest,
6433    ) -> Result<GetImageResponse, RusotoError<GetImageError>> {
6434        let request_uri = "/GetImage";
6435
6436        let mut request = SignedRequest::new("GET", "imagebuilder", &self.region, &request_uri);
6437        request.set_content_type("application/x-amz-json-1.1".to_owned());
6438
6439        let mut params = Params::new();
6440        params.put("imageBuildVersionArn", &input.image_build_version_arn);
6441        request.set_params(params);
6442
6443        let mut response = self
6444            .client
6445            .sign_and_dispatch(request)
6446            .await
6447            .map_err(RusotoError::from)?;
6448        if response.status.is_success() {
6449            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6450            let result = proto::json::ResponsePayload::new(&response)
6451                .deserialize::<GetImageResponse, _>()?;
6452
6453            Ok(result)
6454        } else {
6455            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6456            Err(GetImageError::from_response(response))
6457        }
6458    }
6459
6460    /// <p> Gets an image pipeline. </p>
6461    #[allow(unused_mut)]
6462    async fn get_image_pipeline(
6463        &self,
6464        input: GetImagePipelineRequest,
6465    ) -> Result<GetImagePipelineResponse, RusotoError<GetImagePipelineError>> {
6466        let request_uri = "/GetImagePipeline";
6467
6468        let mut request = SignedRequest::new("GET", "imagebuilder", &self.region, &request_uri);
6469        request.set_content_type("application/x-amz-json-1.1".to_owned());
6470
6471        let mut params = Params::new();
6472        params.put("imagePipelineArn", &input.image_pipeline_arn);
6473        request.set_params(params);
6474
6475        let mut response = self
6476            .client
6477            .sign_and_dispatch(request)
6478            .await
6479            .map_err(RusotoError::from)?;
6480        if response.status.is_success() {
6481            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6482            let result = proto::json::ResponsePayload::new(&response)
6483                .deserialize::<GetImagePipelineResponse, _>()?;
6484
6485            Ok(result)
6486        } else {
6487            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6488            Err(GetImagePipelineError::from_response(response))
6489        }
6490    }
6491
6492    /// <p> Gets an image policy. </p>
6493    #[allow(unused_mut)]
6494    async fn get_image_policy(
6495        &self,
6496        input: GetImagePolicyRequest,
6497    ) -> Result<GetImagePolicyResponse, RusotoError<GetImagePolicyError>> {
6498        let request_uri = "/GetImagePolicy";
6499
6500        let mut request = SignedRequest::new("GET", "imagebuilder", &self.region, &request_uri);
6501        request.set_content_type("application/x-amz-json-1.1".to_owned());
6502
6503        let mut params = Params::new();
6504        params.put("imageArn", &input.image_arn);
6505        request.set_params(params);
6506
6507        let mut response = self
6508            .client
6509            .sign_and_dispatch(request)
6510            .await
6511            .map_err(RusotoError::from)?;
6512        if response.status.is_success() {
6513            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6514            let result = proto::json::ResponsePayload::new(&response)
6515                .deserialize::<GetImagePolicyResponse, _>()?;
6516
6517            Ok(result)
6518        } else {
6519            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6520            Err(GetImagePolicyError::from_response(response))
6521        }
6522    }
6523
6524    /// <p> Gets an image recipe. </p>
6525    #[allow(unused_mut)]
6526    async fn get_image_recipe(
6527        &self,
6528        input: GetImageRecipeRequest,
6529    ) -> Result<GetImageRecipeResponse, RusotoError<GetImageRecipeError>> {
6530        let request_uri = "/GetImageRecipe";
6531
6532        let mut request = SignedRequest::new("GET", "imagebuilder", &self.region, &request_uri);
6533        request.set_content_type("application/x-amz-json-1.1".to_owned());
6534
6535        let mut params = Params::new();
6536        params.put("imageRecipeArn", &input.image_recipe_arn);
6537        request.set_params(params);
6538
6539        let mut response = self
6540            .client
6541            .sign_and_dispatch(request)
6542            .await
6543            .map_err(RusotoError::from)?;
6544        if response.status.is_success() {
6545            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6546            let result = proto::json::ResponsePayload::new(&response)
6547                .deserialize::<GetImageRecipeResponse, _>()?;
6548
6549            Ok(result)
6550        } else {
6551            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6552            Err(GetImageRecipeError::from_response(response))
6553        }
6554    }
6555
6556    /// <p> Gets an image recipe policy. </p>
6557    #[allow(unused_mut)]
6558    async fn get_image_recipe_policy(
6559        &self,
6560        input: GetImageRecipePolicyRequest,
6561    ) -> Result<GetImageRecipePolicyResponse, RusotoError<GetImageRecipePolicyError>> {
6562        let request_uri = "/GetImageRecipePolicy";
6563
6564        let mut request = SignedRequest::new("GET", "imagebuilder", &self.region, &request_uri);
6565        request.set_content_type("application/x-amz-json-1.1".to_owned());
6566
6567        let mut params = Params::new();
6568        params.put("imageRecipeArn", &input.image_recipe_arn);
6569        request.set_params(params);
6570
6571        let mut response = self
6572            .client
6573            .sign_and_dispatch(request)
6574            .await
6575            .map_err(RusotoError::from)?;
6576        if response.status.is_success() {
6577            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6578            let result = proto::json::ResponsePayload::new(&response)
6579                .deserialize::<GetImageRecipePolicyResponse, _>()?;
6580
6581            Ok(result)
6582        } else {
6583            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6584            Err(GetImageRecipePolicyError::from_response(response))
6585        }
6586    }
6587
6588    /// <p> Gets an infrastructure configuration. </p>
6589    #[allow(unused_mut)]
6590    async fn get_infrastructure_configuration(
6591        &self,
6592        input: GetInfrastructureConfigurationRequest,
6593    ) -> Result<
6594        GetInfrastructureConfigurationResponse,
6595        RusotoError<GetInfrastructureConfigurationError>,
6596    > {
6597        let request_uri = "/GetInfrastructureConfiguration";
6598
6599        let mut request = SignedRequest::new("GET", "imagebuilder", &self.region, &request_uri);
6600        request.set_content_type("application/x-amz-json-1.1".to_owned());
6601
6602        let mut params = Params::new();
6603        params.put(
6604            "infrastructureConfigurationArn",
6605            &input.infrastructure_configuration_arn,
6606        );
6607        request.set_params(params);
6608
6609        let mut response = self
6610            .client
6611            .sign_and_dispatch(request)
6612            .await
6613            .map_err(RusotoError::from)?;
6614        if response.status.is_success() {
6615            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6616            let result = proto::json::ResponsePayload::new(&response)
6617                .deserialize::<GetInfrastructureConfigurationResponse, _>()?;
6618
6619            Ok(result)
6620        } else {
6621            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6622            Err(GetInfrastructureConfigurationError::from_response(response))
6623        }
6624    }
6625
6626    /// <p>Imports a component and transforms its data into a component document. </p>
6627    #[allow(unused_mut)]
6628    async fn import_component(
6629        &self,
6630        input: ImportComponentRequest,
6631    ) -> Result<ImportComponentResponse, RusotoError<ImportComponentError>> {
6632        let request_uri = "/ImportComponent";
6633
6634        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
6635        request.set_content_type("application/x-amz-json-1.1".to_owned());
6636
6637        let encoded = Some(serde_json::to_vec(&input).unwrap());
6638        request.set_payload(encoded);
6639
6640        let mut response = self
6641            .client
6642            .sign_and_dispatch(request)
6643            .await
6644            .map_err(RusotoError::from)?;
6645        if response.status.is_success() {
6646            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6647            let result = proto::json::ResponsePayload::new(&response)
6648                .deserialize::<ImportComponentResponse, _>()?;
6649
6650            Ok(result)
6651        } else {
6652            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6653            Err(ImportComponentError::from_response(response))
6654        }
6655    }
6656
6657    /// <p> Returns the list of component build versions for the specified semantic version. </p>
6658    #[allow(unused_mut)]
6659    async fn list_component_build_versions(
6660        &self,
6661        input: ListComponentBuildVersionsRequest,
6662    ) -> Result<ListComponentBuildVersionsResponse, RusotoError<ListComponentBuildVersionsError>>
6663    {
6664        let request_uri = "/ListComponentBuildVersions";
6665
6666        let mut request = SignedRequest::new("POST", "imagebuilder", &self.region, &request_uri);
6667        request.set_content_type("application/x-amz-json-1.1".to_owned());
6668
6669        let encoded = Some(serde_json::to_vec(&input).unwrap());
6670        request.set_payload(encoded);
6671
6672        let mut response = self
6673            .client
6674            .sign_and_dispatch(request)
6675            .await
6676            .map_err(RusotoError::from)?;
6677        if response.status.is_success() {
6678            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6679            let result = proto::json::ResponsePayload::new(&response)
6680                .deserialize::<ListComponentBuildVersionsResponse, _>()?;
6681
6682            Ok(result)
6683        } else {
6684            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6685            Err(ListComponentBuildVersionsError::from_response(response))
6686        }
6687    }
6688
6689    /// <p>Returns the list of component build versions for the specified semantic version. </p>
6690    #[allow(unused_mut)]
6691    async fn list_components(
6692        &self,
6693        input: ListComponentsRequest,
6694    ) -> Result<ListComponentsResponse, RusotoError<ListComponentsError>> {
6695        let request_uri = "/ListComponents";
6696
6697        let mut request = SignedRequest::new("POST", "imagebuilder", &self.region, &request_uri);
6698        request.set_content_type("application/x-amz-json-1.1".to_owned());
6699
6700        let encoded = Some(serde_json::to_vec(&input).unwrap());
6701        request.set_payload(encoded);
6702
6703        let mut response = self
6704            .client
6705            .sign_and_dispatch(request)
6706            .await
6707            .map_err(RusotoError::from)?;
6708        if response.status.is_success() {
6709            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6710            let result = proto::json::ResponsePayload::new(&response)
6711                .deserialize::<ListComponentsResponse, _>()?;
6712
6713            Ok(result)
6714        } else {
6715            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6716            Err(ListComponentsError::from_response(response))
6717        }
6718    }
6719
6720    /// <p> Returns a list of distribution configurations. </p>
6721    #[allow(unused_mut)]
6722    async fn list_distribution_configurations(
6723        &self,
6724        input: ListDistributionConfigurationsRequest,
6725    ) -> Result<
6726        ListDistributionConfigurationsResponse,
6727        RusotoError<ListDistributionConfigurationsError>,
6728    > {
6729        let request_uri = "/ListDistributionConfigurations";
6730
6731        let mut request = SignedRequest::new("POST", "imagebuilder", &self.region, &request_uri);
6732        request.set_content_type("application/x-amz-json-1.1".to_owned());
6733
6734        let encoded = Some(serde_json::to_vec(&input).unwrap());
6735        request.set_payload(encoded);
6736
6737        let mut response = self
6738            .client
6739            .sign_and_dispatch(request)
6740            .await
6741            .map_err(RusotoError::from)?;
6742        if response.status.is_success() {
6743            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6744            let result = proto::json::ResponsePayload::new(&response)
6745                .deserialize::<ListDistributionConfigurationsResponse, _>()?;
6746
6747            Ok(result)
6748        } else {
6749            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6750            Err(ListDistributionConfigurationsError::from_response(response))
6751        }
6752    }
6753
6754    /// <p> Returns a list of image build versions. </p>
6755    #[allow(unused_mut)]
6756    async fn list_image_build_versions(
6757        &self,
6758        input: ListImageBuildVersionsRequest,
6759    ) -> Result<ListImageBuildVersionsResponse, RusotoError<ListImageBuildVersionsError>> {
6760        let request_uri = "/ListImageBuildVersions";
6761
6762        let mut request = SignedRequest::new("POST", "imagebuilder", &self.region, &request_uri);
6763        request.set_content_type("application/x-amz-json-1.1".to_owned());
6764
6765        let encoded = Some(serde_json::to_vec(&input).unwrap());
6766        request.set_payload(encoded);
6767
6768        let mut response = self
6769            .client
6770            .sign_and_dispatch(request)
6771            .await
6772            .map_err(RusotoError::from)?;
6773        if response.status.is_success() {
6774            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6775            let result = proto::json::ResponsePayload::new(&response)
6776                .deserialize::<ListImageBuildVersionsResponse, _>()?;
6777
6778            Ok(result)
6779        } else {
6780            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6781            Err(ListImageBuildVersionsError::from_response(response))
6782        }
6783    }
6784
6785    /// <p> Returns a list of images created by the specified pipeline. </p>
6786    #[allow(unused_mut)]
6787    async fn list_image_pipeline_images(
6788        &self,
6789        input: ListImagePipelineImagesRequest,
6790    ) -> Result<ListImagePipelineImagesResponse, RusotoError<ListImagePipelineImagesError>> {
6791        let request_uri = "/ListImagePipelineImages";
6792
6793        let mut request = SignedRequest::new("POST", "imagebuilder", &self.region, &request_uri);
6794        request.set_content_type("application/x-amz-json-1.1".to_owned());
6795
6796        let encoded = Some(serde_json::to_vec(&input).unwrap());
6797        request.set_payload(encoded);
6798
6799        let mut response = self
6800            .client
6801            .sign_and_dispatch(request)
6802            .await
6803            .map_err(RusotoError::from)?;
6804        if response.status.is_success() {
6805            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6806            let result = proto::json::ResponsePayload::new(&response)
6807                .deserialize::<ListImagePipelineImagesResponse, _>()?;
6808
6809            Ok(result)
6810        } else {
6811            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6812            Err(ListImagePipelineImagesError::from_response(response))
6813        }
6814    }
6815
6816    /// <p>Returns a list of image pipelines. </p>
6817    #[allow(unused_mut)]
6818    async fn list_image_pipelines(
6819        &self,
6820        input: ListImagePipelinesRequest,
6821    ) -> Result<ListImagePipelinesResponse, RusotoError<ListImagePipelinesError>> {
6822        let request_uri = "/ListImagePipelines";
6823
6824        let mut request = SignedRequest::new("POST", "imagebuilder", &self.region, &request_uri);
6825        request.set_content_type("application/x-amz-json-1.1".to_owned());
6826
6827        let encoded = Some(serde_json::to_vec(&input).unwrap());
6828        request.set_payload(encoded);
6829
6830        let mut response = self
6831            .client
6832            .sign_and_dispatch(request)
6833            .await
6834            .map_err(RusotoError::from)?;
6835        if response.status.is_success() {
6836            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6837            let result = proto::json::ResponsePayload::new(&response)
6838                .deserialize::<ListImagePipelinesResponse, _>()?;
6839
6840            Ok(result)
6841        } else {
6842            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6843            Err(ListImagePipelinesError::from_response(response))
6844        }
6845    }
6846
6847    /// <p> Returns a list of image recipes. </p>
6848    #[allow(unused_mut)]
6849    async fn list_image_recipes(
6850        &self,
6851        input: ListImageRecipesRequest,
6852    ) -> Result<ListImageRecipesResponse, RusotoError<ListImageRecipesError>> {
6853        let request_uri = "/ListImageRecipes";
6854
6855        let mut request = SignedRequest::new("POST", "imagebuilder", &self.region, &request_uri);
6856        request.set_content_type("application/x-amz-json-1.1".to_owned());
6857
6858        let encoded = Some(serde_json::to_vec(&input).unwrap());
6859        request.set_payload(encoded);
6860
6861        let mut response = self
6862            .client
6863            .sign_and_dispatch(request)
6864            .await
6865            .map_err(RusotoError::from)?;
6866        if response.status.is_success() {
6867            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6868            let result = proto::json::ResponsePayload::new(&response)
6869                .deserialize::<ListImageRecipesResponse, _>()?;
6870
6871            Ok(result)
6872        } else {
6873            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6874            Err(ListImageRecipesError::from_response(response))
6875        }
6876    }
6877
6878    /// <p> Returns the list of images that you have access to. </p>
6879    #[allow(unused_mut)]
6880    async fn list_images(
6881        &self,
6882        input: ListImagesRequest,
6883    ) -> Result<ListImagesResponse, RusotoError<ListImagesError>> {
6884        let request_uri = "/ListImages";
6885
6886        let mut request = SignedRequest::new("POST", "imagebuilder", &self.region, &request_uri);
6887        request.set_content_type("application/x-amz-json-1.1".to_owned());
6888
6889        let encoded = Some(serde_json::to_vec(&input).unwrap());
6890        request.set_payload(encoded);
6891
6892        let mut response = self
6893            .client
6894            .sign_and_dispatch(request)
6895            .await
6896            .map_err(RusotoError::from)?;
6897        if response.status.is_success() {
6898            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6899            let result = proto::json::ResponsePayload::new(&response)
6900                .deserialize::<ListImagesResponse, _>()?;
6901
6902            Ok(result)
6903        } else {
6904            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6905            Err(ListImagesError::from_response(response))
6906        }
6907    }
6908
6909    /// <p> Returns a list of infrastructure configurations. </p>
6910    #[allow(unused_mut)]
6911    async fn list_infrastructure_configurations(
6912        &self,
6913        input: ListInfrastructureConfigurationsRequest,
6914    ) -> Result<
6915        ListInfrastructureConfigurationsResponse,
6916        RusotoError<ListInfrastructureConfigurationsError>,
6917    > {
6918        let request_uri = "/ListInfrastructureConfigurations";
6919
6920        let mut request = SignedRequest::new("POST", "imagebuilder", &self.region, &request_uri);
6921        request.set_content_type("application/x-amz-json-1.1".to_owned());
6922
6923        let encoded = Some(serde_json::to_vec(&input).unwrap());
6924        request.set_payload(encoded);
6925
6926        let mut response = self
6927            .client
6928            .sign_and_dispatch(request)
6929            .await
6930            .map_err(RusotoError::from)?;
6931        if response.status.is_success() {
6932            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6933            let result = proto::json::ResponsePayload::new(&response)
6934                .deserialize::<ListInfrastructureConfigurationsResponse, _>()?;
6935
6936            Ok(result)
6937        } else {
6938            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6939            Err(ListInfrastructureConfigurationsError::from_response(
6940                response,
6941            ))
6942        }
6943    }
6944
6945    /// <p> Returns the list of tags for the specified resource. </p>
6946    #[allow(unused_mut)]
6947    async fn list_tags_for_resource(
6948        &self,
6949        input: ListTagsForResourceRequest,
6950    ) -> Result<ListTagsForResourceResponse, RusotoError<ListTagsForResourceError>> {
6951        let request_uri = format!("/tags/{resource_arn}", resource_arn = input.resource_arn);
6952
6953        let mut request = SignedRequest::new("GET", "imagebuilder", &self.region, &request_uri);
6954        request.set_content_type("application/x-amz-json-1.1".to_owned());
6955
6956        let mut response = self
6957            .client
6958            .sign_and_dispatch(request)
6959            .await
6960            .map_err(RusotoError::from)?;
6961        if response.status.is_success() {
6962            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6963            let result = proto::json::ResponsePayload::new(&response)
6964                .deserialize::<ListTagsForResourceResponse, _>()?;
6965
6966            Ok(result)
6967        } else {
6968            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6969            Err(ListTagsForResourceError::from_response(response))
6970        }
6971    }
6972
6973    /// <p> Applies a policy to a component. We recommend that you call the RAM API <a href="https://docs.aws.amazon.com/ram/latest/APIReference/API_CreateResourceShare.html">CreateResourceShare</a> to share resources. If you call the Image Builder API <code>PutComponentPolicy</code>, you must also call the RAM API <a href="https://docs.aws.amazon.com/ram/latest/APIReference/API_PromoteResourceShareCreatedFromPolicy.html">PromoteResourceShareCreatedFromPolicy</a> in order for the resource to be visible to all principals with whom the resource is shared. </p>
6974    #[allow(unused_mut)]
6975    async fn put_component_policy(
6976        &self,
6977        input: PutComponentPolicyRequest,
6978    ) -> Result<PutComponentPolicyResponse, RusotoError<PutComponentPolicyError>> {
6979        let request_uri = "/PutComponentPolicy";
6980
6981        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
6982        request.set_content_type("application/x-amz-json-1.1".to_owned());
6983
6984        let encoded = Some(serde_json::to_vec(&input).unwrap());
6985        request.set_payload(encoded);
6986
6987        let mut response = self
6988            .client
6989            .sign_and_dispatch(request)
6990            .await
6991            .map_err(RusotoError::from)?;
6992        if response.status.is_success() {
6993            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6994            let result = proto::json::ResponsePayload::new(&response)
6995                .deserialize::<PutComponentPolicyResponse, _>()?;
6996
6997            Ok(result)
6998        } else {
6999            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7000            Err(PutComponentPolicyError::from_response(response))
7001        }
7002    }
7003
7004    /// <p>Applies a policy to an image. We recommend that you call the RAM API <a href="https://docs.aws.amazon.com/ram/latest/APIReference/API_CreateResourceShare.html">CreateResourceShare</a> to share resources. If you call the Image Builder API <code>PutImagePolicy</code>, you must also call the RAM API <a href="https://docs.aws.amazon.com/ram/latest/APIReference/API_PromoteResourceShareCreatedFromPolicy.html">PromoteResourceShareCreatedFromPolicy</a> in order for the resource to be visible to all principals with whom the resource is shared. </p>
7005    #[allow(unused_mut)]
7006    async fn put_image_policy(
7007        &self,
7008        input: PutImagePolicyRequest,
7009    ) -> Result<PutImagePolicyResponse, RusotoError<PutImagePolicyError>> {
7010        let request_uri = "/PutImagePolicy";
7011
7012        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
7013        request.set_content_type("application/x-amz-json-1.1".to_owned());
7014
7015        let encoded = Some(serde_json::to_vec(&input).unwrap());
7016        request.set_payload(encoded);
7017
7018        let mut response = self
7019            .client
7020            .sign_and_dispatch(request)
7021            .await
7022            .map_err(RusotoError::from)?;
7023        if response.status.is_success() {
7024            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7025            let result = proto::json::ResponsePayload::new(&response)
7026                .deserialize::<PutImagePolicyResponse, _>()?;
7027
7028            Ok(result)
7029        } else {
7030            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7031            Err(PutImagePolicyError::from_response(response))
7032        }
7033    }
7034
7035    /// <p> Applies a policy to an image recipe. We recommend that you call the RAM API <a href="https://docs.aws.amazon.com/ram/latest/APIReference/API_CreateResourceShare.html">CreateResourceShare</a> to share resources. If you call the Image Builder API <code>PutImageRecipePolicy</code>, you must also call the RAM API <a href="https://docs.aws.amazon.com/ram/latest/APIReference/API_PromoteResourceShareCreatedFromPolicy.html">PromoteResourceShareCreatedFromPolicy</a> in order for the resource to be visible to all principals with whom the resource is shared. </p>
7036    #[allow(unused_mut)]
7037    async fn put_image_recipe_policy(
7038        &self,
7039        input: PutImageRecipePolicyRequest,
7040    ) -> Result<PutImageRecipePolicyResponse, RusotoError<PutImageRecipePolicyError>> {
7041        let request_uri = "/PutImageRecipePolicy";
7042
7043        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
7044        request.set_content_type("application/x-amz-json-1.1".to_owned());
7045
7046        let encoded = Some(serde_json::to_vec(&input).unwrap());
7047        request.set_payload(encoded);
7048
7049        let mut response = self
7050            .client
7051            .sign_and_dispatch(request)
7052            .await
7053            .map_err(RusotoError::from)?;
7054        if response.status.is_success() {
7055            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7056            let result = proto::json::ResponsePayload::new(&response)
7057                .deserialize::<PutImageRecipePolicyResponse, _>()?;
7058
7059            Ok(result)
7060        } else {
7061            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7062            Err(PutImageRecipePolicyError::from_response(response))
7063        }
7064    }
7065
7066    /// <p> Manually triggers a pipeline to create an image. </p>
7067    #[allow(unused_mut)]
7068    async fn start_image_pipeline_execution(
7069        &self,
7070        input: StartImagePipelineExecutionRequest,
7071    ) -> Result<StartImagePipelineExecutionResponse, RusotoError<StartImagePipelineExecutionError>>
7072    {
7073        let request_uri = "/StartImagePipelineExecution";
7074
7075        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
7076        request.set_content_type("application/x-amz-json-1.1".to_owned());
7077
7078        let encoded = Some(serde_json::to_vec(&input).unwrap());
7079        request.set_payload(encoded);
7080
7081        let mut response = self
7082            .client
7083            .sign_and_dispatch(request)
7084            .await
7085            .map_err(RusotoError::from)?;
7086        if response.status.is_success() {
7087            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7088            let result = proto::json::ResponsePayload::new(&response)
7089                .deserialize::<StartImagePipelineExecutionResponse, _>()?;
7090
7091            Ok(result)
7092        } else {
7093            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7094            Err(StartImagePipelineExecutionError::from_response(response))
7095        }
7096    }
7097
7098    /// <p> Adds a tag to a resource. </p>
7099    #[allow(unused_mut)]
7100    async fn tag_resource(
7101        &self,
7102        input: TagResourceRequest,
7103    ) -> Result<TagResourceResponse, RusotoError<TagResourceError>> {
7104        let request_uri = format!("/tags/{resource_arn}", resource_arn = input.resource_arn);
7105
7106        let mut request = SignedRequest::new("POST", "imagebuilder", &self.region, &request_uri);
7107        request.set_content_type("application/x-amz-json-1.1".to_owned());
7108
7109        let encoded = Some(serde_json::to_vec(&input).unwrap());
7110        request.set_payload(encoded);
7111
7112        let mut response = self
7113            .client
7114            .sign_and_dispatch(request)
7115            .await
7116            .map_err(RusotoError::from)?;
7117        if response.status.is_success() {
7118            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7119            let result = proto::json::ResponsePayload::new(&response)
7120                .deserialize::<TagResourceResponse, _>()?;
7121
7122            Ok(result)
7123        } else {
7124            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7125            Err(TagResourceError::from_response(response))
7126        }
7127    }
7128
7129    /// <p> Removes a tag from a resource. </p>
7130    #[allow(unused_mut)]
7131    async fn untag_resource(
7132        &self,
7133        input: UntagResourceRequest,
7134    ) -> Result<UntagResourceResponse, RusotoError<UntagResourceError>> {
7135        let request_uri = format!("/tags/{resource_arn}", resource_arn = input.resource_arn);
7136
7137        let mut request = SignedRequest::new("DELETE", "imagebuilder", &self.region, &request_uri);
7138        request.set_content_type("application/x-amz-json-1.1".to_owned());
7139
7140        let mut params = Params::new();
7141        for item in input.tag_keys.iter() {
7142            params.put("tagKeys", item);
7143        }
7144        request.set_params(params);
7145
7146        let mut response = self
7147            .client
7148            .sign_and_dispatch(request)
7149            .await
7150            .map_err(RusotoError::from)?;
7151        if response.status.is_success() {
7152            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7153            let result = proto::json::ResponsePayload::new(&response)
7154                .deserialize::<UntagResourceResponse, _>()?;
7155
7156            Ok(result)
7157        } else {
7158            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7159            Err(UntagResourceError::from_response(response))
7160        }
7161    }
7162
7163    /// <p> Updates a new distribution configuration. Distribution configurations define and configure the outputs of your pipeline. </p>
7164    #[allow(unused_mut)]
7165    async fn update_distribution_configuration(
7166        &self,
7167        input: UpdateDistributionConfigurationRequest,
7168    ) -> Result<
7169        UpdateDistributionConfigurationResponse,
7170        RusotoError<UpdateDistributionConfigurationError>,
7171    > {
7172        let request_uri = "/UpdateDistributionConfiguration";
7173
7174        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
7175        request.set_content_type("application/x-amz-json-1.1".to_owned());
7176
7177        let encoded = Some(serde_json::to_vec(&input).unwrap());
7178        request.set_payload(encoded);
7179
7180        let mut response = self
7181            .client
7182            .sign_and_dispatch(request)
7183            .await
7184            .map_err(RusotoError::from)?;
7185        if response.status.is_success() {
7186            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7187            let result = proto::json::ResponsePayload::new(&response)
7188                .deserialize::<UpdateDistributionConfigurationResponse, _>()?;
7189
7190            Ok(result)
7191        } else {
7192            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7193            Err(UpdateDistributionConfigurationError::from_response(
7194                response,
7195            ))
7196        }
7197    }
7198
7199    /// <p> Updates a new image pipeline. Image pipelines enable you to automate the creation and distribution of images. </p>
7200    #[allow(unused_mut)]
7201    async fn update_image_pipeline(
7202        &self,
7203        input: UpdateImagePipelineRequest,
7204    ) -> Result<UpdateImagePipelineResponse, RusotoError<UpdateImagePipelineError>> {
7205        let request_uri = "/UpdateImagePipeline";
7206
7207        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
7208        request.set_content_type("application/x-amz-json-1.1".to_owned());
7209
7210        let encoded = Some(serde_json::to_vec(&input).unwrap());
7211        request.set_payload(encoded);
7212
7213        let mut response = self
7214            .client
7215            .sign_and_dispatch(request)
7216            .await
7217            .map_err(RusotoError::from)?;
7218        if response.status.is_success() {
7219            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7220            let result = proto::json::ResponsePayload::new(&response)
7221                .deserialize::<UpdateImagePipelineResponse, _>()?;
7222
7223            Ok(result)
7224        } else {
7225            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7226            Err(UpdateImagePipelineError::from_response(response))
7227        }
7228    }
7229
7230    /// <p> Updates a new infrastructure configuration. An infrastructure configuration defines the environment in which your image will be built and tested. </p>
7231    #[allow(unused_mut)]
7232    async fn update_infrastructure_configuration(
7233        &self,
7234        input: UpdateInfrastructureConfigurationRequest,
7235    ) -> Result<
7236        UpdateInfrastructureConfigurationResponse,
7237        RusotoError<UpdateInfrastructureConfigurationError>,
7238    > {
7239        let request_uri = "/UpdateInfrastructureConfiguration";
7240
7241        let mut request = SignedRequest::new("PUT", "imagebuilder", &self.region, &request_uri);
7242        request.set_content_type("application/x-amz-json-1.1".to_owned());
7243
7244        let encoded = Some(serde_json::to_vec(&input).unwrap());
7245        request.set_payload(encoded);
7246
7247        let mut response = self
7248            .client
7249            .sign_and_dispatch(request)
7250            .await
7251            .map_err(RusotoError::from)?;
7252        if response.status.is_success() {
7253            let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7254            let result = proto::json::ResponsePayload::new(&response)
7255                .deserialize::<UpdateInfrastructureConfigurationResponse, _>()?;
7256
7257            Ok(result)
7258        } else {
7259            let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7260            Err(UpdateInfrastructureConfigurationError::from_response(
7261                response,
7262            ))
7263        }
7264    }
7265}