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

export interface AccountArgs extends core.ResourceArgs {
  closeOnDeletion?: boolean | core.BooleanOut;

  createGovcloud?: boolean | core.BooleanOut;

  email: string | core.StringOut;

  iamUserAccessToBilling?: string | core.StringOut;

  name: string | core.StringOut;

  parentId?: string | core.StringOut;

  roleName?: string | core.StringOut;

  tags?: core.Map<string, string> | core.MapOut<core.StringOut>;

  tagsAll?: core.Map<string, string> | core.MapOut<core.StringOut>;
}

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

  @core.attr(Boolean)
  public closeOnDeletion?: boolean | core.BooleanOut;

  @core.attr(Boolean)
  public createGovcloud?: boolean | core.BooleanOut;

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

  @core.attr(String, { computed: true })
  public govcloudId!: string | core.StringOut;

  @core.attr(String)
  public iamUserAccessToBilling?: string | core.StringOut;

  @core.attr(String, { computed: true })
  public id!: string | core.StringOut;

  @core.attr(String, { computed: true })
  public joinedMethod!: string | core.StringOut;

  @core.attr(String, { computed: true })
  public joinedTimestamp!: string | core.StringOut;

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

  @core.attr(String, { computed: true })
  public parentId?: string | core.StringOut;

  @core.attr(String)
  public roleName?: string | core.StringOut;

  @core.attr(String, { computed: true })
  public status!: string | core.StringOut;

  @core.attr(String, { kind: "map" })
  public tags?: core.Map<string, string> | core.MapOut<core.StringOut>;

  @core.attr(String, { computed: true, kind: "map" })
  public tagsAll?: core.Map<string, string> | core.MapOut<core.StringOut>;

  constructor(name: string, args?: AccountArgs) {
    super(name, "aws_organizations_account", args);
  }

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