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

export interface DelegatedAdministratorsBlkArgs extends core.SchemaArgs {
  arn: string | core.StringOut;

  delegationEnabledDate: string | core.StringOut;

  email: string | core.StringOut;

  id: string | core.StringOut;

  joinedMethod: string | core.StringOut;

  joinedTimestamp: string | core.StringOut;

  name: string | core.StringOut;

  status: string | core.StringOut;
}

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

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

  @core.attr(String, { computed: true })
  public email!: 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, { computed: true })
  public name!: string | core.StringOut;

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

export interface DsDelegatedAdministratorsArgs {
  servicePrincipal?: string | core.StringOut;
}

export class DsDelegatedAdministrators extends core.Data<DsDelegatedAdministratorsArgs> {
  @core.attr(DelegatedAdministratorsBlk, { computed: true, kind: "array" })
  public delegatedAdministrators!:
    | core.Array<DelegatedAdministratorsBlk>
    | core.ArrayOut<DelegatedAdministratorsBlk>;

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

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

  constructor(name: string, args?: DsDelegatedAdministratorsArgs) {
    super(name, "aws_organizations_delegated_administrators", args);
  }

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