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

export interface BaiduChannelArgs extends core.ResourceArgs {
  /**
   * (Required) Platform credential API key from Baidu.
   */
  apiKey: string | core.StringOut;

  /**
   * (Required) The application ID.
   */
  applicationId: string | core.StringOut;

  /**
   * (Optional) Specifies whether to enable the channel. Defaults to `true`.
   */
  enabled?: boolean | core.BooleanOut;

  /**
   * (Required) Platform credential Secret key from Baidu.
   */
  secretKey: string | core.StringOut;
}

export class BaiduChannel extends core.Resource<BaiduChannelArgs> {
  /**
   * (Required) Platform credential API key from Baidu.
   */
  @core.attr(String)
  public apiKey!: string | core.StringOut;

  /**
   * (Required) The application ID.
   */
  @core.attr(String)
  public applicationId!: string | core.StringOut;

  /**
   * (Optional) Specifies whether to enable the channel. Defaults to `true`.
   */
  @core.attr(Boolean)
  public enabled?: boolean | core.BooleanOut;

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

  /**
   * (Required) Platform credential Secret key from Baidu.
   */
  @core.attr(String)
  public secretKey!: string | core.StringOut;

  constructor(name: string, args?: BaiduChannelArgs) {
    super(name, "aws_pinpoint_baidu_channel", args);
  }

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