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

export interface PolicyArgs extends core.ResourceArgs {
  name: string | core.StringOut;

  policy: string | core.StringOut;
}

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

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

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

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

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

  constructor(name: string, args?: PolicyArgs) {
    super(name, "aws_iot_policy", args);
  }

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