import * as core from "@terrascript/core";

export interface UserPolicyAttachmentArgs extends core.ResourceArgs {
  policyArn: string | core.StringOut;

  user: string | core.StringOut;
}

export class UserPolicyAttachment extends core.Resource<UserPolicyAttachmentArgs> {
  @core.attr(String, { computed: true })
  public id!: string | core.StringOut;

  @core.attr(String)
  public policyArn!: string | core.StringOut;

  @core.attr(String)
  public user!: string | core.StringOut;

  constructor(name: string, args?: UserPolicyAttachmentArgs) {
    super(name, "aws_iam_user_policy_attachment", args);
  }

  public override getNamespace(): string {
    return "aws_iam";
  }
}
