Amazon Elastic Compute Cloud
API Reference (API Version 2016-11-15)

DescribeIamInstanceProfileAssociations

Describes your IAM instance profile associations.

Request Parameters

The following parameters are for this specific action. For more information about required and optional parameters that are common to all actions, see Common Query Parameters.

AssociationId.N

The IAM instance profile associations.

Type: Array of strings

Required: No

Filter.N

The filters.

  • instance-id - The ID of the instance.

  • state - The state of the association (associating | associated | disassociating | disassociated).

Type: Array of Filter objects

Required: No

MaxResults

The maximum number of results to return in a single call. To retrieve the remaining results, make another call with the returned NextToken value.

Type: Integer

Required: No

NextToken

The token to request the next page of results.

Type: String

Required: No

Response Elements

The following elements are returned by the service.

iamInstanceProfileAssociationSet

Information about the IAM instance profile associations.

Type: Array of IamInstanceProfileAssociation objects

nextToken

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

Type: String

requestId

The ID of the request.

Type: String

Errors

For information about the errors that are common to all actions, see Common Client Errors.

Example

Example

This example describes all of your IAM instance profile associations.

Sample Request

https://ec2.amazonaws.com/?Action=DescribeIamInstanceProfileAssociations &AUTHPARAMS

Sample Response

<DescribeIamInstanceProfileAssociationsResponse xmlns="http://ec2.amazonaws.com/doc/2016-11-15/"> <requestId>84c2d2a6-12dc-491f-a9ee-example</requestId> <iamInstanceProfileAssociations> <item> <associationId>iip-assoc-08049da59357d598c</associationId> <iamInstanceProfile> <arn>arn:aws:iam::123456789012:instance-profile/AdminProfile</arn> <id>AIPAJEDNCAA64SSD265D6</id> </iamInstanceProfile> <instanceId>i-1234567890abcdef0</instanceId> <state>associated</state> </item> </iamInstanceProfileAssociations> </DescribeIamInstanceProfileAssociationsResponse>

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: