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

export interface EndpointPolicyArgs extends core.ResourceArgs {
  policy?: string | core.StringOut;

  vpcEndpointId: string | core.StringOut;
}

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

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

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

  constructor(name: string, args?: EndpointPolicyArgs) {
    super(name, "aws_vpc_endpoint_policy", args);
  }

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