GET /#Action=ModifyImageAttribute

Modifies the specified attribute of the specified AMI. You can specify only one attribute at a time.

To specify the attribute, you can use the Attribute parameter, or one of the following parameters: Description, ImdsSupport, or LaunchPermission.

Images with an Amazon Web Services Marketplace product code cannot be made public.

To enable the SriovNetSupport enhanced networking attribute of an image, enable SriovNetSupport on an instance and create an AMI from the instance.

Servers

Request headers

Name Type Required Description
X-Amz-Content-Sha256 String No
X-Amz-Credential String No
X-Amz-Date String No
X-Amz-Algorithm String No
X-Amz-SignedHeaders String No
X-Amz-Security-Token String No
X-Amz-Signature String No

Query parameters

Name Type Required Description
Version String Yes

Possible values:

  • "2016-11-15"
ImageId String Yes

The ID of the AMI.

Attribute String No

The name of the attribute to modify.

Valid values: description | imdsSupport | launchPermission

ProductCode[] Array No

Not supported.

UserId[] Array No

The Amazon Web Services account IDs. This parameter can be used only when the Attribute parameter is launchPermission.

OperationType String No

The operation type. This parameter can be used only when the Attribute parameter is launchPermission.

Possible values:

  • "remove"
  • "add"
Description Object No

A new description for the AMI.

Value String No

The value of the attribute being modified. This parameter can be used only when the Attribute parameter is description or imdsSupport.

UserGroup[] Array No

The user groups. This parameter can be used only when the Attribute parameter is launchPermission.

ImdsSupport Object No

Set to v2.0 to indicate that IMDSv2 is specified in the AMI. Instances launched from this AMI will have HttpTokens automatically set to required so that, by default, the instance requires that IMDSv2 is used when requesting instance metadata. In addition, HttpPutResponseHopLimit is set to 2. For more information, see Configure the AMI in the Amazon EC2 User Guide.

Do not use this parameter unless your AMI software supports IMDSv2. After you set the value to v2.0, you can't undo it. The only way to “reset” your AMI is to create a new AMI from the underlying snapshot.

LaunchPermission Object No

A new launch permission for the AMI.

OrganizationalUnitArn[] Array No

The Amazon Resource Name (ARN) of an organizational unit (OU). This parameter can be used only when the Attribute parameter is launchPermission.

DryRun Boolean No

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

OrganizationArn[] Array No

The Amazon Resource Name (ARN) of an organization. This parameter can be used only when the Attribute parameter is launchPermission.

Action String Yes

Possible values:

  • "ModifyImageAttribute"

How to start integrating

  1. Add HTTP Task to your workflow definition.
  2. Search for the API you want to integrate with and click on the name.
    • This loads the API reference documentation and prepares the Http request settings.
  3. Click Test request to test run your request to the API and see the API's response.