AwsIamUser

Creates an AWS IAM user.

Remarks

This helper class provisions aws.iam.User with default tags and optional user access keys. It accepts all user arguments from the Pulumi AWS provider and can create user access keys. Access-key secret values are not exposed through this component's public outputs. The component does not configure provider PGP encryption for access-key creation because no shared PGP key is available for all consumers.

Naming:

  • Provider child type aws:iam/user:User uses readable tuple [args.name], producing ${env}-${projectHash}-${sanitised args.name}. As this plain helper has no component root, its args.name discriminator is sufficient for direct construction; facade construction supplies the AwsIam parent.
  • Provider child type aws:iam/accessKey:AccessKey uses tuple [args.name, args.accessKeys map key], producing ${env}-${projectHash}-${sanitised args.name}-${sanitised map key}. All keyed entries are collision-checked before creating either access-key resource.
  • The AWS user name uses stackAndPurpose: ${env}-${projectHash}-${args.name}. IAM allows 64 characters, so args.name is a required camelCase purpose capped at 51 characters.

Example

CODE
const user = new AwsIamUser({
  name: 'appAutomationUser',
  accessKeys: {
    2026: { status: 'Active' },
    2027: { status: 'Inactive' },
  },
});

Constructors

new AwsIamUser( args: AwsIamUserResourceArgs, options?: ResourceOptions, ): AwsIamUser

Parameters

  • args (AwsIamUserResourceArgs) — Component inputs forwarded to the underlying user resource.
  • options (ResourceOptions, optional) — Optional settings controlling resource behaviour.

Returns

AwsIamUser


Properties

accessKeys: Record<string, AwsIamUserAccessKeyMetadata>

readonly

Non-secret metadata for access keys created for this user, keyed by the input access-key identity.

arn: Output<string>

readonly

The IAM user ARN.

id: Output<string>

readonly

The provider-assigned ID for this user resource.

name: Output<string>

readonly

The IAM user name.

uniqueId: Output<string>

readonly

Stable and unique string identifying the user.

user: User

readonly

The underlying AWS IAM user resource.