

# Using Amazon Infrastructure Composer with Amazon Q Developer
<a name="using-composer-ide-cw"></a>

 Amazon Infrastructure Composer from the Amazon Toolkit for Visual Studio Code provides an integration with Amazon Q. You can use Amazon Q within Infrastructure Composer to generate the infrastructure code for your Amazon resources as you design your application.

Amazon Q is a general purpose, machine learning-powered code generator. To learn more, see [What is Amazon Q?](https://docs.amazonaws.cn/amazonq/latest/qdeveloper-ug/what-is.html) in the *Amazon Q Developer User Guide*.

For **standard resource** and **standard component** cards, you can use Amazon Q to generate infrastructure code suggestions for your resources.

![\[Amazon Q generating a code suggestion in Infrastructure Composer\]](http://docs.amazonaws.cn/en_us/infrastructure-composer/latest/dg/images/aac_use_ide_cw_01.gif)


**Standard resource** and **standard component** cards can represent an Amazon CloudFormation resource or a collection of Amazon CloudFormation resources. To learn more, see [Configure and modify cards in Infrastructure Composer](using-composer-cards.md).

## Setting up
<a name="using-composer-ide-cw-setup"></a>

To use Amazon Q in Infrastructure Composer, you must authenticate with Amazon Q in the Toolkit. For instructions, see [Getting started with Amazon Q in VS Code and JetBrains](https://docs.amazonaws.cn/amazonq/latest/qdeveloper-ug/q-in-IDE.html) in the *Amazon Q Developer User Guide*.

## Using Amazon Q Developer in Infrastructure Composer
<a name="using-composer-ide-cw-use"></a>

You can use Amazon Q Developer from the **Resource properties** panel of any **standard resource** or **standard component** card.

**To use Amazon Q in Infrastructure Composer**

1. From a **standard resource** or **standard component** card, open the **Resource properties** panel.

1. Locate the **Resource configuration** field. This field contains the infrastructure code for the card.

1. Select the **Generate suggestions** button. Amazon Q will generate a suggestion.
**Note**  
Code generated at this stage will not overwrite existing infrastructure code from your template.

1. To generate more suggestions, select **Regenerate**. You can toggle through the samples to compare results.

1. To select an option, choose **Select**. You can modify the code here before saving it to your application. To exit without saving, select the **exit icon (X)**.

1. To save the code to your application template, select **Save** from the **Resource properties** panel.

## Learn more
<a name="using-composer-ide-cw-learn"></a>

To learn more about Amazon Q, see [What is Amazon Q?](https://docs.amazonaws.cn/amazonq/latest/qdeveloper-ug/what-is.html) in the *Amazon Q Developer User Guide*.