1---2name: ec2-image-builder3description: EC2 Image Builder API skill. Use when working with EC2 Image Builder for CancelImageCreation, CancelLifecycleExecution, CreateComponent. Covers 73 endpoints.4---5
6# EC2 Image Builder
7API version: 2019-12-02
8
9## Auth
10AWS SigV4
11
12## Base URL
13Not specified.
14
15## Setup
161. Configure auth: AWS SigV4
172. GET /GetComponent -- verify access
183. POST /ListComponentBuildVersions -- create first ListComponentBuildVersions
19
20## Endpoints
21
2273 endpoints across 71 groups. See references/api-spec.lap for full details.
23
24### CancelImageCreation
25| Method | Path | Description |
26|--------|------|-------------|
27| PUT | /CancelImageCreation | CancelImageCreation cancels the creation of Image. This operation can only be used on images in a non-terminal state. |
28
29### CancelLifecycleExecution
30| Method | Path | Description |
31|--------|------|-------------|
32| PUT | /CancelLifecycleExecution | Cancel a specific image lifecycle policy runtime instance. |
33
34### CreateComponent
35| Method | Path | Description |
36|--------|------|-------------|
37| PUT | /CreateComponent | Creates a new component that can be used to build, validate, test, and assess your image. The component is based on a YAML document that you specify using exactly one of the following methods: Inline, using the data property in the request body. A URL that points to a YAML document file stored in Amazon S3, using the uri property in the request body. |
38
39### CreateContainerRecipe
40| Method | Path | Description |
41|--------|------|-------------|
42| PUT | /CreateContainerRecipe | Creates a new container recipe. Container recipes define how images are configured, tested, and assessed. |
43
44### CreateDistributionConfiguration
45| Method | Path | Description |
46|--------|------|-------------|
47| PUT | /CreateDistributionConfiguration | Creates a new distribution configuration. Distribution configurations define and configure the outputs of your pipeline. |
48
49### CreateImage
50| Method | Path | Description |
51|--------|------|-------------|
52| PUT | /CreateImage | Creates a new image. This request will create a new image along with all of the configured output resources defined in the distribution configuration. You must specify exactly one recipe for your image, using either a ContainerRecipeArn or an ImageRecipeArn. |
53
54### CreateImagePipeline
55| Method | Path | Description |
56|--------|------|-------------|
57| PUT | /CreateImagePipeline | Creates a new image pipeline. Image pipelines enable you to automate the creation and distribution of images. |
58
59### CreateImageRecipe
60| Method | Path | Description |
61|--------|------|-------------|
62| PUT | /CreateImageRecipe | Creates a new image recipe. Image recipes define how images are configured, tested, and assessed. |
63
64### CreateInfrastructureConfiguration
65| Method | Path | Description |
66|--------|------|-------------|
67| PUT | /CreateInfrastructureConfiguration | Creates a new infrastructure configuration. An infrastructure configuration defines the environment in which your image will be built and tested. |
68
69### CreateLifecyclePolicy
70| Method | Path | Description |
71|--------|------|-------------|
72| PUT | /CreateLifecyclePolicy | Create a lifecycle policy resource. |
73
74### CreateWorkflow
75| Method | Path | Description |
76|--------|------|-------------|
77| PUT | /CreateWorkflow | Create a new workflow or a new version of an existing workflow. |
78
79### DeleteComponent
80| Method | Path | Description |
81|--------|------|-------------|
82| DELETE | /DeleteComponent | Deletes a component build version. |
83
84### DeleteContainerRecipe
85| Method | Path | Description |
86|--------|------|-------------|
87| DELETE | /DeleteContainerRecipe | Deletes a container recipe. |
88
89### DeleteDistributionConfiguration
90| Method | Path | Description |
91|--------|------|-------------|
92| DELETE | /DeleteDistributionConfiguration | Deletes a distribution configuration. |
93
94### DeleteImage
95| Method | Path | Description |
96|--------|------|-------------|
97| DELETE | /DeleteImage | Deletes an Image Builder image resource. This does not delete any EC2 AMIs or ECR container images that are created during the image build process. You must clean those up separately, using the appropriate Amazon EC2 or Amazon ECR console actions, or API or CLI commands. To deregister an EC2 Linux AMI, see Deregister your Linux AMI in the Amazon EC2 User Guide . To deregister an EC2 Windows AMI, see Deregister your Windows AMI in the Amazon EC2 Windows Guide . To delete a container image from Amazon ECR, see Deleting an image in the Amazon ECR User Guide. |
98
99### DeleteImagePipeline
100| Method | Path | Description |
101|--------|------|-------------|
102| DELETE | /DeleteImagePipeline | Deletes an image pipeline. |
103
104### DeleteImageRecipe
105| Method | Path | Description |
106|--------|------|-------------|
107| DELETE | /DeleteImageRecipe | Deletes an image recipe. |
108
109### DeleteInfrastructureConfiguration
110| Method | Path | Description |
111|--------|------|-------------|
112| DELETE | /DeleteInfrastructureConfiguration | Deletes an infrastructure configuration. |
113
114### DeleteLifecyclePolicy
115| Method | Path | Description |
116|--------|------|-------------|
117| DELETE | /DeleteLifecyclePolicy | Delete the specified lifecycle policy resource. |
118
119### DeleteWorkflow
120| Method | Path | Description |
121|--------|------|-------------|
122| DELETE | /DeleteWorkflow | Deletes a specific workflow resource. |
123
124### GetComponent
125| Method | Path | Description |
126|--------|------|-------------|
127| GET | /GetComponent | Gets a component object. |
128
129### GetComponentPolicy
130| Method | Path | Description |
131|--------|------|-------------|
132| GET | /GetComponentPolicy | Gets a component policy. |
133
134### GetContainerRecipe
135| Method | Path | Description |
136|--------|------|-------------|
137| GET | /GetContainerRecipe | Retrieves a container recipe. |
138
139### GetContainerRecipePolicy
140| Method | Path | Description |
141|--------|------|-------------|
142| GET | /GetContainerRecipePolicy | Retrieves the policy for a container recipe. |
143
144### GetDistributionConfiguration
145| Method | Path | Description |
146|--------|------|-------------|
147| GET | /GetDistributionConfiguration | Gets a distribution configuration. |
148
149### GetImage
150| Method | Path | Description |
151|--------|------|-------------|
152| GET | /GetImage | Gets an image. |
153
154### GetImagePipeline
155| Method | Path | Description |
156|--------|------|-------------|
157| GET | /GetImagePipeline | Gets an image pipeline. |
158
159### GetImagePolicy
160| Method | Path | Description |
161|--------|------|-------------|
162| GET | /GetImagePolicy | Gets an image policy. |
163
164### GetImageRecipe
165| Method | Path | Description |
166|--------|------|-------------|
167| GET | /GetImageRecipe | Gets an image recipe. |
168
169### GetImageRecipePolicy
170| Method | Path | Description |
171|--------|------|-------------|
172| GET | /GetImageRecipePolicy | Gets an image recipe policy. |
173
174### GetInfrastructureConfiguration
175| Method | Path | Description |
176|--------|------|-------------|
177| GET | /GetInfrastructureConfiguration | Gets an infrastructure configuration. |
178
179### GetLifecycleExecution
180| Method | Path | Description |
181|--------|------|-------------|
182| GET | /GetLifecycleExecution | Get the runtime information that was logged for a specific runtime instance of the lifecycle policy. |
183
184### GetLifecyclePolicy
185| Method | Path | Description |
186|--------|------|-------------|
187| GET | /GetLifecyclePolicy | Get details for the specified image lifecycle policy. |
188
189### GetWorkflow
190| Method | Path | Description |
191|--------|------|-------------|
192| GET | /GetWorkflow | Get a workflow resource object. |
193
194### GetWorkflowExecution
195| Method | Path | Description |
196|--------|------|-------------|
197| GET | /GetWorkflowExecution | Get the runtime information that was logged for a specific runtime instance of the workflow. |
198
199### GetWorkflowStepExecution
200| Method | Path | Description |
201|--------|------|-------------|
202| GET | /GetWorkflowStepExecution | Get the runtime information that was logged for a specific runtime instance of the workflow step. |
203
204### ImportComponent
205| Method | Path | Description |
206|--------|------|-------------|
207| PUT | /ImportComponent | Imports a component and transforms its data into a component document. |
208
209### ImportVmImage
210| Method | Path | Description |
211|--------|------|-------------|
212| PUT | /ImportVmImage | When you export your virtual machine (VM) from its virtualization environment, that process creates a set of one or more disk container files that act as snapshots of your VM’s environment, settings, and data. The Amazon EC2 API ImportImage action uses those files to import your VM and create an AMI. To import using the CLI command, see import-image You can reference the task ID from the VM import to pull in the AMI that the import created as the base image for your Image Builder recipe. |
213
214### ListComponentBuildVersions
215| Method | Path | Description |
216|--------|------|-------------|
217| POST | /ListComponentBuildVersions | Returns the list of component build versions for the specified semantic version. The semantic version has four nodes: <major>.<minor>.<patch>/<build>. You can assign values for the first three, and can filter on all of them. Filtering: With semantic versioning, you have the flexibility to use wildcards (x) to specify the most recent versions or nodes when selecting the base image or components for your recipe. When you use a wildcard in any node, all nodes to the right of the first wildcard must also be wildcards. |
218
219### ListComponents
220| Method | Path | Description |
221|--------|------|-------------|
222| POST | /ListComponents | Returns the list of components that can be filtered by name, or by using the listed filters to streamline results. Newly created components can take up to two minutes to appear in the ListComponents API Results. The semantic version has four nodes: <major>.<minor>.<patch>/<build>. You can assign values for the first three, and can filter on all of them. Filtering: With semantic versioning, you have the flexibility to use wildcards (x) to specify the most recent versions or nodes when selecting the base image or components for your recipe. When you use a wildcard in any node, all nodes to the right of the first wildcard must also be wildcards. |
223
224### ListContainerRecipes
225| Method | Path | Description |
226|--------|------|-------------|
227| POST | /ListContainerRecipes | Returns a list of container recipes. |
228
229### ListDistributionConfigurations
230| Method | Path | Description |
231|--------|------|-------------|
232| POST | /ListDistributionConfigurations | Returns a list of distribution configurations. |
233
234### ListImageBuildVersions
235| Method | Path | Description |
236|--------|------|-------------|
237| POST | /ListImageBuildVersions | Returns a list of image build versions. |
238
239### ListImagePackages
240| Method | Path | Description |
241|--------|------|-------------|
242| POST | /ListImagePackages | List the Packages that are associated with an Image Build Version, as determined by Amazon Web Services Systems Manager Inventory at build time. |
243
244### ListImagePipelineImages
245| Method | Path | Description |
246|--------|------|-------------|
247| POST | /ListImagePipelineImages | Returns a list of images created by the specified pipeline. |
248
249### ListImagePipelines
250| Method | Path | Description |
251|--------|------|-------------|
252| POST | /ListImagePipelines | Returns a list of image pipelines. |
253
254### ListImageRecipes
255| Method | Path | Description |
256|--------|------|-------------|
257| POST | /ListImageRecipes | Returns a list of image recipes. |
258
259### ListImageScanFindingAggregations
260| Method | Path | Description |
261|--------|------|-------------|
262| POST | /ListImageScanFindingAggregations | Returns a list of image scan aggregations for your account. You can filter by the type of key that Image Builder uses to group results. For example, if you want to get a list of findings by severity level for one of your pipelines, you might specify your pipeline with the imagePipelineArn filter. If you don't specify a filter, Image Builder returns an aggregation for your account. To streamline results, you can use the following filters in your request: accountId imageBuildVersionArn imagePipelineArn vulnerabilityId |
263
264### ListImageScanFindings
265| Method | Path | Description |
266|--------|------|-------------|
267| POST | /ListImageScanFindings | Returns a list of image scan findings for your account. |
268
269### ListImages
270| Method | Path | Description |
271|--------|------|-------------|
272| POST | /ListImages | Returns the list of images that you have access to. Newly created images can take up to two minutes to appear in the ListImages API Results. |
273
274### ListInfrastructureConfigurations
275| Method | Path | Description |
276|--------|------|-------------|
277| POST | /ListInfrastructureConfigurations | Returns a list of infrastructure configurations. |
278
279### ListLifecycleExecutionResources
280| Method | Path | Description |
281|--------|------|-------------|
282| POST | /ListLifecycleExecutionResources | List resources that the runtime instance of the image lifecycle identified for lifecycle actions. |
283
284### ListLifecycleExecutions
285| Method | Path | Description |
286|--------|------|-------------|
287| POST | /ListLifecycleExecutions | Get the lifecycle runtime history for the specified resource. |
288
289### ListLifecyclePolicies
290| Method | Path | Description |
291|--------|------|-------------|
292| POST | /ListLifecyclePolicies | Get a list of lifecycle policies in your Amazon Web Services account. |
293
294### tags
295| Method | Path | Description |
296|--------|------|-------------|
297| GET | /tags/{resourceArn} | Returns the list of tags for the specified resource. |
298| POST | /tags/{resourceArn} | Adds a tag to a resource. |
299| DELETE | /tags/{resourceArn} | Removes a tag from a resource. |
300
301### ListWaitingWorkflowSteps
302| Method | Path | Description |
303|--------|------|-------------|
304| POST | /ListWaitingWorkflowSteps | Get a list of workflow steps that are waiting for action for workflows in your Amazon Web Services account. |
305
306### ListWorkflowBuildVersions
307| Method | Path | Description |
308|--------|------|-------------|
309| POST | /ListWorkflowBuildVersions | Returns a list of build versions for a specific workflow resource. |
310
311### ListWorkflowExecutions
312| Method | Path | Description |
313|--------|------|-------------|
314| POST | /ListWorkflowExecutions | Returns a list of workflow runtime instance metadata objects for a specific image build version. |
315
316### ListWorkflowStepExecutions
317| Method | Path | Description |
318|--------|------|-------------|
319| POST | /ListWorkflowStepExecutions | Returns runtime data for each step in a runtime instance of the workflow that you specify in the request. |
320
321### ListWorkflows
322| Method | Path | Description |
323|--------|------|-------------|
324| POST | /ListWorkflows | Lists workflow build versions based on filtering parameters. |
325
326### PutComponentPolicy
327| Method | Path | Description |
328|--------|------|-------------|
329| PUT | /PutComponentPolicy | Applies a policy to a component. We recommend that you call the RAM API CreateResourceShare to share resources. If you call the Image Builder API PutComponentPolicy, you must also call the RAM API PromoteResourceShareCreatedFromPolicy in order for the resource to be visible to all principals with whom the resource is shared. |
330
331### PutContainerRecipePolicy
332| Method | Path | Description |
333|--------|------|-------------|
334| PUT | /PutContainerRecipePolicy | Applies a policy to a container image. We recommend that you call the RAM API CreateResourceShare (https://docs.aws.amazon.com//ram/latest/APIReference/API_CreateResourceShare.html) to share resources. If you call the Image Builder API PutContainerImagePolicy, you must also call the RAM API PromoteResourceShareCreatedFromPolicy (https://docs.aws.amazon.com//ram/latest/APIReference/API_PromoteResourceShareCreatedFromPolicy.html) in order for the resource to be visible to all principals with whom the resource is shared. |
335
336### PutImagePolicy
337| Method | Path | Description |
338|--------|------|-------------|
339| PUT | /PutImagePolicy | Applies a policy to an image. We recommend that you call the RAM API CreateResourceShare to share resources. If you call the Image Builder API PutImagePolicy, you must also call the RAM API PromoteResourceShareCreatedFromPolicy in order for the resource to be visible to all principals with whom the resource is shared. |
340
341### PutImageRecipePolicy
342| Method | Path | Description |
343|--------|------|-------------|
344| PUT | /PutImageRecipePolicy | Applies a policy to an image recipe. We recommend that you call the RAM API CreateResourceShare to share resources. If you call the Image Builder API PutImageRecipePolicy, you must also call the RAM API PromoteResourceShareCreatedFromPolicy in order for the resource to be visible to all principals with whom the resource is shared. |
345
346### SendWorkflowStepAction
347| Method | Path | Description |
348|--------|------|-------------|
349| PUT | /SendWorkflowStepAction | Pauses or resumes image creation when the associated workflow runs a WaitForAction step. |
350
351### StartImagePipelineExecution
352| Method | Path | Description |
353|--------|------|-------------|
354| PUT | /StartImagePipelineExecution | Manually triggers a pipeline to create an image. |
355
356### StartResourceStateUpdate
357| Method | Path | Description |
358|--------|------|-------------|
359| PUT | /StartResourceStateUpdate | Begin asynchronous resource state update for lifecycle changes to the specified image resources. |
360
361### UpdateDistributionConfiguration
362| Method | Path | Description |
363|--------|------|-------------|
364| PUT | /UpdateDistributionConfiguration | Updates a new distribution configuration. Distribution configurations define and configure the outputs of your pipeline. |
365
366### UpdateImagePipeline
367| Method | Path | Description |
368|--------|------|-------------|
369| PUT | /UpdateImagePipeline | Updates an image pipeline. Image pipelines enable you to automate the creation and distribution of images. You must specify exactly one recipe for your image, using either a containerRecipeArn or an imageRecipeArn. UpdateImagePipeline does not support selective updates for the pipeline. You must specify all of the required properties in the update request, not just the properties that have changed. |
370
371### UpdateInfrastructureConfiguration
372| Method | Path | Description |
373|--------|------|-------------|
374| PUT | /UpdateInfrastructureConfiguration | Updates a new infrastructure configuration. An infrastructure configuration defines the environment in which your image will be built and tested. |
375
376### UpdateLifecyclePolicy
377| Method | Path | Description |
378|--------|------|-------------|
379| PUT | /UpdateLifecyclePolicy | Update the specified lifecycle policy. |
380
381## Common Questions
382
383Match user requests to endpoints in references/api-spec.lap. Key patterns:
384- "List all GetComponent?" -> GET /GetComponent
385- "List all GetComponentPolicy?" -> GET /GetComponentPolicy
386- "List all GetContainerRecipe?" -> GET /GetContainerRecipe
387- "List all GetContainerRecipePolicy?" -> GET /GetContainerRecipePolicy
388- "List all GetDistributionConfiguration?" -> GET /GetDistributionConfiguration
389- "List all GetImage?" -> GET /GetImage
390- "List all GetImagePipeline?" -> GET /GetImagePipeline
391- "List all GetImagePolicy?" -> GET /GetImagePolicy
392- "List all GetImageRecipe?" -> GET /GetImageRecipe
393- "List all GetImageRecipePolicy?" -> GET /GetImageRecipePolicy
394- "List all GetInfrastructureConfiguration?" -> GET /GetInfrastructureConfiguration
395- "List all GetLifecycleExecution?" -> GET /GetLifecycleExecution
396- "List all GetLifecyclePolicy?" -> GET /GetLifecyclePolicy
397- "List all GetWorkflow?" -> GET /GetWorkflow
398- "List all GetWorkflowExecution?" -> GET /GetWorkflowExecution
399- "List all GetWorkflowStepExecution?" -> GET /GetWorkflowStepExecution
400- "Create a ListComponentBuildVersion?" -> POST /ListComponentBuildVersions
401- "Create a ListComponent?" -> POST /ListComponents
402- "Create a ListContainerRecipe?" -> POST /ListContainerRecipes
403- "Create a ListDistributionConfiguration?" -> POST /ListDistributionConfigurations
404- "Create a ListImageBuildVersion?" -> POST /ListImageBuildVersions
405- "Create a ListImagePackage?" -> POST /ListImagePackages
406- "Create a ListImagePipelineImage?" -> POST /ListImagePipelineImages
407- "Create a ListImagePipeline?" -> POST /ListImagePipelines
408- "Create a ListImageRecipe?" -> POST /ListImageRecipes
409- "Create a ListImageScanFindingAggregation?" -> POST /ListImageScanFindingAggregations
410- "Create a ListImageScanFinding?" -> POST /ListImageScanFindings
411- "Create a ListImage?" -> POST /ListImages
412- "Create a ListInfrastructureConfiguration?" -> POST /ListInfrastructureConfigurations
413- "Create a ListLifecycleExecutionResource?" -> POST /ListLifecycleExecutionResources
414- "Create a ListLifecycleExecution?" -> POST /ListLifecycleExecutions
415- "Create a ListLifecyclePolicy?" -> POST /ListLifecyclePolicies
416- "Get tag details?" -> GET /tags/{resourceArn}
417- "Create a ListWaitingWorkflowStep?" -> POST /ListWaitingWorkflowSteps
418- "Create a ListWorkflowBuildVersion?" -> POST /ListWorkflowBuildVersions
419- "Create a ListWorkflowExecution?" -> POST /ListWorkflowExecutions
420- "Create a ListWorkflowStepExecution?" -> POST /ListWorkflowStepExecutions
421- "Create a ListWorkflow?" -> POST /ListWorkflows
422- "Delete a tag?" -> DELETE /tags/{resourceArn}
423- "How to authenticate?" -> See Auth section
424
425## Response Tips
426- Check response schemas in references/api-spec.lap for field details
427- Create/update endpoints typically return the created/updated object
428
429## References
430- Full spec: See references/api-spec.lap for complete endpoint details, parameter tables, and response schemas
431
432> Generated from the official API spec by [LAP](https://lap.sh)