Amazon IAM Iam Instance Profile API
The Iam Instance Profile API from Amazon IAM — 7 operation(s) for iam instance profile.
The Iam Instance Profile API from Amazon IAM — 7 operation(s) for iam instance profile.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/amazon-iam:amazon-iam-instance-profile-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: AWS Identity and Access Management Instance Profile API
version: '2010-05-08'
description: Generated from AWS's published Smithy model for AWS Identity and Access Management. 7 operation(s).
contact:
name: Amazon Web Services
url: https://aws.amazon.com/contact-us/
license:
name: Apache 2.0
identifier: Apache-2.0
url: https://github.com/aws/api-models-aws/blob/main/LICENSE
servers:
- url: https://iam.{region}.amazonaws.com
variables:
region:
default: us-east-1
security:
- sigv4: []
tags:
- name: Instance Profile
paths:
/?Action=CreateInstanceProfile:
post:
operationId: CreateInstanceProfile
summary: Create Instance Profile
description: Creates a new instance profile. For information about instance profiles, see Using roles for applications on Amazon EC2 in the IAM User Guide, and Instance profiles in the Amazon EC2 User Guide. For information about the number of instance profiles you can create, see IAM object quotas in the IAM User Guide.
responses:
'200':
description: Success
content:
text/xml:
schema:
$ref: '#/components/schemas/CreateInstanceProfileResponse'
example:
InstanceProfile:
InstanceProfileId: AIPAJMBYC7DLSPEXAMPLE
Roles: []
CreateDate: '2015-03-09T20:33:19.626Z'
InstanceProfileName: Webserver
Path: /
Arn: arn:aws:iam::123456789012:instance-profile/Webserver
'409':
description: ConcurrentModificationException; EntityAlreadyExistsException; LimitExceededException
content:
text/xml:
schema:
$ref: '#/components/schemas/ConcurrentModificationException'
'400':
description: InvalidInputException
content:
text/xml:
schema:
$ref: '#/components/schemas/InvalidInputException'
'500':
description: ServiceFailureException
content:
text/xml:
schema:
$ref: '#/components/schemas/ServiceFailureException'
requestBody:
required: true
content:
application/x-www-form-urlencoded:
schema:
allOf:
- type: object
required:
- Action
- Version
properties:
Action:
type: string
const: CreateInstanceProfile
Version:
type: string
const: '2010-05-08'
- $ref: '#/components/schemas/CreateInstanceProfileRequest'
example:
InstanceProfileName: Webserver
tags:
- Instance Profile
/?Action=DeleteInstanceProfile:
post:
operationId: DeleteInstanceProfile
summary: Delete Instance Profile
description: Deletes the specified instance profile. The instance profile must not have an associated role. Make sure that you do not have any Amazon EC2 instances running with the instance profile you are about to delete. Deleting a role or instance profile that is associated with a running instance will break any applications running on the instance. For more information about instance profiles, see Using instance profiles in the IAM User Guide.
responses:
'200':
description: Success
content:
text/xml:
schema:
type: string
'409':
description: DeleteConflictException; LimitExceededException
content:
text/xml:
schema:
$ref: '#/components/schemas/DeleteConflictException'
'404':
description: NoSuchEntityException
content:
text/xml:
schema:
$ref: '#/components/schemas/NoSuchEntityException'
'500':
description: ServiceFailureException
content:
text/xml:
schema:
$ref: '#/components/schemas/ServiceFailureException'
requestBody:
required: true
content:
application/x-www-form-urlencoded:
schema:
allOf:
- type: object
required:
- Action
- Version
properties:
Action:
type: string
const: DeleteInstanceProfile
Version:
type: string
const: '2010-05-08'
- $ref: '#/components/schemas/DeleteInstanceProfileRequest'
example:
InstanceProfileName: ExampleInstanceProfile
tags:
- Instance Profile
/?Action=GetInstanceProfile:
post:
operationId: GetInstanceProfile
summary: Get Instance Profile
description: Retrieves information about the specified instance profile, including the instance profile's path, GUID, ARN, and role. For more information about instance profiles, see Using instance profiles in the IAM User Guide.
responses:
'200':
description: Success
content:
text/xml:
schema:
$ref: '#/components/schemas/GetInstanceProfileResponse'
example:
InstanceProfile:
InstanceProfileId: AID2MAB8DPLSRHEXAMPLE
Roles:
- AssumeRolePolicyDocument: <URL-encoded-JSON>
RoleId: AIDGPMS9RO4H3FEXAMPLE
CreateDate: '2013-01-09T06:33:26Z'
Path: /
RoleName: Test-Role
Arn: arn:aws:iam::336924118301:role/Test-Role
CreateDate: '2013-06-12T23:52:02Z'
InstanceProfileName: ExampleInstanceProfile
Path: /
Arn: arn:aws:iam::336924118301:instance-profile/ExampleInstanceProfile
'404':
description: NoSuchEntityException
content:
text/xml:
schema:
$ref: '#/components/schemas/NoSuchEntityException'
'500':
description: ServiceFailureException
content:
text/xml:
schema:
$ref: '#/components/schemas/ServiceFailureException'
requestBody:
required: true
content:
application/x-www-form-urlencoded:
schema:
allOf:
- type: object
required:
- Action
- Version
properties:
Action:
type: string
const: GetInstanceProfile
Version:
type: string
const: '2010-05-08'
- $ref: '#/components/schemas/GetInstanceProfileRequest'
example:
InstanceProfileName: ExampleInstanceProfile
tags:
- Instance Profile
/?Action=ListInstanceProfiles:
post:
operationId: ListInstanceProfiles
summary: List Instance Profiles
description: Lists the instance profiles that have the specified path prefix. If there are none, the operation returns an empty list. For more information about instance profiles, see Using instance profiles in the IAM User Guide. IAM resource-listing operations return a subset of the available attributes for the resource. For example, this operation does not return tags, even though they are an attribute of the returned object. To view all of the information for an instance profile, see GetInstanceProfile. You can paginate the results using the MaxItems and Marker parameters.
responses:
'200':
description: Success
content:
text/xml:
schema:
$ref: '#/components/schemas/ListInstanceProfilesResponse'
'500':
description: ServiceFailureException
content:
text/xml:
schema:
$ref: '#/components/schemas/ServiceFailureException'
requestBody:
required: true
content:
application/x-www-form-urlencoded:
schema:
allOf:
- type: object
required:
- Action
- Version
properties:
Action:
type: string
const: ListInstanceProfiles
Version:
type: string
const: '2010-05-08'
- $ref: '#/components/schemas/ListInstanceProfilesRequest'
tags:
- Instance Profile
/?Action=ListInstanceProfilesForRole:
post:
operationId: ListInstanceProfilesForRole
summary: List Instance Profiles For Role
description: Lists the instance profiles that have the specified associated IAM role. If there are none, the operation returns an empty list. For more information about instance profiles, go to Using instance profiles in the IAM User Guide. You can paginate the results using the MaxItems and Marker parameters.
responses:
'200':
description: Success
content:
text/xml:
schema:
$ref: '#/components/schemas/ListInstanceProfilesForRoleResponse'
'404':
description: NoSuchEntityException
content:
text/xml:
schema:
$ref: '#/components/schemas/NoSuchEntityException'
'500':
description: ServiceFailureException
content:
text/xml:
schema:
$ref: '#/components/schemas/ServiceFailureException'
requestBody:
required: true
content:
application/x-www-form-urlencoded:
schema:
allOf:
- type: object
required:
- Action
- Version
properties:
Action:
type: string
const: ListInstanceProfilesForRole
Version:
type: string
const: '2010-05-08'
- $ref: '#/components/schemas/ListInstanceProfilesForRoleRequest'
tags:
- Instance Profile
/?Action=TagInstanceProfile:
post:
operationId: TagInstanceProfile
summary: Tag Instance Profile
description: 'Adds one or more tags to an IAM instance profile. If a tag with the same key name already exists, then that tag is overwritten with the new value. Each tag consists of a key name and an associated value. By assigning tags to your resources, you can do the following: Administrative grouping and discovery - Attach tags to resources to aid in organization and search. For example, you could search for all resources with the key name Project and the value MyImportantProject. Or search for all resources with the key name Cost Center and the value 41200. Access control - Include tags in IAM user-based and resource-based policies. You can use tags to restrict access to only an IAM instance profile that has a specified tag attached. For examples of policies that show how to use tags to control access, see Control access using IAM tags in the IAM User Guide. If any one of the tags is invalid or if you exceed the allowed maximum number of tags, then the entire request fails and the resource is not created. For more information about tagging, see Tagging IAM resources in the IAM User Guide. Amazon Web Services always interprets the tag Value as a single string. If you need to store an array, y'
responses:
'200':
description: Success
content:
text/xml:
schema:
type: string
'409':
description: ConcurrentModificationException; LimitExceededException
content:
text/xml:
schema:
$ref: '#/components/schemas/ConcurrentModificationException'
'400':
description: InvalidInputException
content:
text/xml:
schema:
$ref: '#/components/schemas/InvalidInputException'
'404':
description: NoSuchEntityException
content:
text/xml:
schema:
$ref: '#/components/schemas/NoSuchEntityException'
'500':
description: ServiceFailureException
content:
text/xml:
schema:
$ref: '#/components/schemas/ServiceFailureException'
requestBody:
required: true
content:
application/x-www-form-urlencoded:
schema:
allOf:
- type: object
required:
- Action
- Version
properties:
Action:
type: string
const: TagInstanceProfile
Version:
type: string
const: '2010-05-08'
- $ref: '#/components/schemas/TagInstanceProfileRequest'
tags:
- Instance Profile
/?Action=UntagInstanceProfile:
post:
operationId: UntagInstanceProfile
summary: Untag Instance Profile
description: Removes the specified tags from the IAM instance profile. For more information about tagging, see Tagging IAM resources in the IAM User Guide.
responses:
'200':
description: Success
content:
text/xml:
schema:
type: string
'409':
description: ConcurrentModificationException
content:
text/xml:
schema:
$ref: '#/components/schemas/ConcurrentModificationException'
'400':
description: InvalidInputException
content:
text/xml:
schema:
$ref: '#/components/schemas/InvalidInputException'
'404':
description: NoSuchEntityException
content:
text/xml:
schema:
$ref: '#/components/schemas/NoSuchEntityException'
'500':
description: ServiceFailureException
content:
text/xml:
schema:
$ref: '#/components/schemas/ServiceFailureException'
requestBody:
required: true
content:
application/x-www-form-urlencoded:
schema:
allOf:
- type: object
required:
- Action
- Version
properties:
Action:
type: string
const: UntagInstanceProfile
Version:
type: string
const: '2010-05-08'
- $ref: '#/components/schemas/UntagInstanceProfileRequest'
tags:
- Instance Profile
components:
schemas:
CreateInstanceProfileRequest:
type: object
properties:
InstanceProfileName:
type: string
description: 'The name of the instance profile to create. This parameter allows (through its regex pattern) a string of characters consisting of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: _+=,.@-'
Path:
type: string
description: The path to the instance profile. For more information about paths, see IAM Identifiers in the IAM User Guide. This parameter is optional. If it is not included, it defaults to a slash (/). This parameter allows (through its regex pattern) a string of characters consisting of either a forward slash (/) by itself or a string that must begin and end with forward slashes. In addition, it can contain any ASCII character from the ! (\u0021) through the DEL character (\u007F), including most punctuation characters, digits, and upper and lowercased letters.
Tags:
type: array
items:
$ref: '#/components/schemas/Tag'
description: A list of tags that you want to attach to the newly created IAM instance profile. Each tag consists of a key name and an associated value. For more information about tagging, see Tagging IAM resources in the IAM User Guide. If any one of the tags is invalid or if you exceed the allowed maximum number of tags, then the entire request fails and the resource is not created.
required:
- InstanceProfileName
DeleteInstanceProfileRequest:
type: object
properties:
InstanceProfileName:
type: string
description: 'The name of the instance profile to delete. This parameter allows (through its regex pattern) a string of characters consisting of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: _+=,.@-'
required:
- InstanceProfileName
InvalidInputException:
type: object
properties:
message:
type: string
InstanceProfile:
type: object
properties:
Path:
type: string
description: The path to the instance profile. For more information about paths, see IAM identifiers in the IAM User Guide.
InstanceProfileName:
type: string
description: The name identifying the instance profile.
InstanceProfileId:
type: string
description: The stable and unique string identifying the instance profile. For more information about IDs, see IAM identifiers in the IAM User Guide.
Arn:
type: string
description: The Amazon Resource Name (ARN) specifying the instance profile. For more information about ARNs and how to use them in policies, see IAM identifiers in the IAM User Guide.
CreateDate:
type: string
format: date-time
description: The date when the instance profile was created.
Roles:
type: array
items:
$ref: '#/components/schemas/Role'
description: The role associated with the instance profile.
Tags:
type: array
items:
$ref: '#/components/schemas/Tag'
description: A list of tags that are attached to the instance profile. For more information about tagging, see Tagging IAM resources in the IAM User Guide.
required:
- Path
- InstanceProfileName
- InstanceProfileId
- Arn
- CreateDate
- Roles
SourceRoleTemplate:
type: object
properties:
TemplateArn:
type: string
description: The Amazon Resource Name (ARN) of the role template that the role was created from.
TemplateMinorVersion:
type: integer
description: The minor version of the role template that was used to create the role.
required:
- TemplateArn
- TemplateMinorVersion
GetInstanceProfileRequest:
type: object
properties:
InstanceProfileName:
type: string
description: 'The name of the instance profile to get information about. This parameter allows (through its regex pattern) a string of characters consisting of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: _+=,.@-'
required:
- InstanceProfileName
ServiceFailureException:
type: object
properties:
message:
type: string
NoSuchEntityException:
type: object
properties:
message:
type: string
ListInstanceProfilesRequest:
type: object
properties:
PathPrefix:
type: string
description: The path prefix for filtering the results. For example, the prefix /application_abc/component_xyz/ gets all instance profiles whose path starts with /application_abc/component_xyz/. This parameter is optional. If it is not included, it defaults to a slash (/), listing all instance profiles. This parameter allows (through its regex pattern) a string of characters consisting of either a forward slash (/) by itself or a string that must begin and end with forward slashes. In addition, it can contain any ASCII character from the ! (\u0021) through the DEL character (\u007F), including most punctua
Marker:
type: string
description: Use this parameter only when paginating results and only after you receive a response indicating that the results are truncated. Set it to the value of the Marker element in the response that you received to indicate where the next call should start.
MaxItems:
type: integer
description: Use this only when paginating results to indicate the maximum number of items you want in the response. If additional items exist beyond the maximum you specify, the IsTruncated response element is true. If you do not include this parameter, the number of items defaults to 100. Note that IAM might return fewer results, even when there are more results available. In that case, the IsTruncated response element returns true, and Marker contains a value to include in the subsequent call that tells the service where to continue from.
Tag:
type: object
properties:
Key:
type: string
description: The key name that can be used to look up or retrieve the associated value. For example, Department or Cost Center are common choices.
Value:
type: string
description: The value associated with this tag. For example, tags with a key name of Department could have values such as Human Resources, Accounting, and Support. Tags with a key name of Cost Center might have values that consist of the number associated with the different cost centers in your company. Typically, many resources have tags with the same key name but with different values.
required:
- Key
- Value
AttachedPermissionsBoundary:
type: object
properties:
PermissionsBoundaryType:
type: string
enum:
- PermissionsBoundaryPolicy
description: The permissions boundary usage type that indicates what type of IAM resource is used as the permissions boundary for an entity. This data type can only have a value of Policy.
PermissionsBoundaryArn:
type: string
description: The ARN of the policy used to set the permissions boundary for the user or role.
TagInstanceProfileRequest:
type: object
properties:
InstanceProfileName:
type: string
description: 'The name of the IAM instance profile to which you want to add tags. This parameter allows (through its regex pattern) a string of characters consisting of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: _+=,.@-'
Tags:
type: array
items:
$ref: '#/components/schemas/Tag'
description: The list of tags that you want to attach to the IAM instance profile. Each tag consists of a key name and an associated value.
required:
- InstanceProfileName
- Tags
GetInstanceProfileResponse:
type: object
properties:
InstanceProfile:
$ref: '#/components/schemas/InstanceProfile'
required:
- InstanceProfile
ListInstanceProfilesResponse:
type: object
properties:
InstanceProfiles:
type: array
items:
$ref: '#/components/schemas/InstanceProfile'
description: A list of instance profiles.
IsTruncated:
type: boolean
description: A flag that indicates whether there are more items to return. If your results were truncated, you can make a subsequent pagination request using the Marker request parameter to retrieve more items. Note that IAM might return fewer than the MaxItems number of results even when there are more results available. We recommend that you check IsTruncated after every call to ensure that you receive all your results.
Marker:
type: string
description: When IsTruncated is true, this element is present and contains the value to use for the Marker parameter in a subsequent pagination request.
required:
- InstanceProfiles
ListInstanceProfilesForRoleRequest:
type: object
properties:
RoleName:
type: string
description: 'The name of the role to list instance profiles for. This parameter allows (through its regex pattern) a string of characters consisting of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: _+=,.@-'
Marker:
type: string
description: Use this parameter only when paginating results and only after you receive a response indicating that the results are truncated. Set it to the value of the Marker element in the response that you received to indicate where the next call should start.
MaxItems:
type: integer
description: Use this only when paginating results to indicate the maximum number of items you want in the response. If additional items exist beyond the maximum you specify, the IsTruncated response element is true. If you do not include this parameter, the number of items defaults to 100. Note that IAM might return fewer results, even when there are more results available. In that case, the IsTruncated response element returns true, and Marker contains a value to include in the subsequent call that tells the service where to continue from.
required:
- RoleName
ConcurrentModificationException:
type: object
properties:
message:
type: string
ListInstanceProfilesForRoleResponse:
type: object
properties:
InstanceProfiles:
type: array
items:
$ref: '#/components/schemas/InstanceProfile'
description: A list of instance profiles.
IsTruncated:
type: boolean
description: A flag that indicates whether there are more items to return. If your results were truncated, you can make a subsequent pagination request using the Marker request parameter to retrieve more items. Note that IAM might return fewer than the MaxItems number of results even when there are more results available. We recommend that you check IsTruncated after every call to ensure that you receive all your results.
Marker:
type: string
description: When IsTruncated is true, this element is present and contains the value to use for the Marker parameter in a subsequent pagination request.
required:
- InstanceProfiles
CreateInstanceProfileResponse:
type: object
properties:
InstanceProfile:
$ref: '#/components/schemas/InstanceProfile'
required:
- InstanceProfile
RoleLastUsed:
type: object
properties:
LastUsedDate:
type: string
format: date-time
description: The date and time, in ISO 8601 date-time format that the role was last used. This field is null if the role has not been used within the IAM tracking period. For more information about the tracking period, see Regions where data is tracked in the IAM User Guide.
Region:
type: string
description: The name of the Amazon Web Services Region in which the role was last used.
Role:
type: object
properties:
Path:
type: string
description: The path to the role. For more information about paths, see IAM identifiers in the IAM User Guide.
RoleName:
type: string
description: The friendly name that identifies the role.
RoleId:
type: string
description: The stable and unique string identifying the role. For more information about IDs, see IAM identifiers in the IAM User Guide.
Arn:
type: string
description: The Amazon Resource Name (ARN) specifying the role. For more information about ARNs and how to use them in policies, see IAM identifiers in the IAM User Guide guide.
CreateDate:
type: string
format: date-time
description: The date and time, in ISO 8601 date-time format, when the role was created.
AssumeRolePolicyDocument:
type: string
description: The policy that grants an entity permission to assume the role.
Description:
type: string
description: A description of the role that you provide.
MaxSessionDuration:
type: integer
description: The maximum session duration (in seconds) for the specified role. Anyone who uses the CLI, or API to assume the role can specify the duration using the optional DurationSeconds API parameter or duration-seconds CLI parameter.
PermissionsBoundary:
$ref: '#/components/schemas/AttachedPermissionsBoundary'
Tags:
type: array
items:
$ref: '#/components/schemas/Tag'
description: A list of tags that are attached to the role. For more information about tagging, see Tagging IAM resources in the IAM User Guide.
RoleLastUsed:
$ref: '#/components/schemas/RoleLastUsed'
SourceRoleTemplate:
$ref: '#/components/schemas/SourceRoleTemplate'
required:
- Path
- RoleName
- RoleId
- Arn
- CreateDate
DeleteConflictException:
type: object
properties:
message:
type: string
UntagInstanceProfileRequest:
type: object
properties:
InstanceProfileName:
type: string
description: 'The name of the IAM instance profile from which you want to remove tags. This parameter allows (through its regex pattern) a string of characters consisting of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: _+=,.@-'
TagKeys:
type: array
items:
type: string
description: A list of key names as a simple array of strings. The tags with matching keys are removed from the specified instance profile.
required:
- InstanceProfileName
- TagKeys
securitySchemes:
sigv4:
type: apiKey
in: header
name: Authorization
description: AWS Signature Version 4. The Authorization header carries an AWS4-HMAC-SHA256 signature over the canonical request, with X-Amz-Date (and X-Amz-Security-Token for temporary credentials). Not a bearer token.
x-aws-sigv4:
signingName: iam
x-provenance:
method: harvested
publisher: Amazon Web Services
source: https://raw.githubusercontent.com/aws/api-models-aws/582e55931c45b944739742a2c1620b6026dd2d13/models/iam/service/2010-05-08/iam-2010-05-08.json
note: converted by smithy-to-openapi.py from AWS's Smithy model (roadmap#1001)