/**
 * Cloudflare EMAIL-SENDING API
 *
 * Generated from Cloudflare TypeScript SDK.
 * DO NOT EDIT - regenerate with: bun scripts/generate.ts --service email-sending
 */
import * as Schema from "effect/Schema";
import type * as HttpClient from "effect/unstable/http/HttpClient";
import * as API from "../client/api.ts";
import type { Credentials } from "../credentials.ts";
import { type DefaultErrors } from "../errors.ts";
export interface SendEmailSendingRequest {
    /** Path param: Identifier of the account. */
    accountId: string;
    /** Body param: Sender email address. Either a plain string or an object with address and name. */
    from: string | {
        address: string;
        name: string;
    };
    /** Body param: Email subject line. */
    subject: string;
    /** Body param: Recipient(s). A single email string or an array of email strings. */
    to: string | string[];
    /** Body param: File attachments and inline images. */
    attachments?: ({
        content: string;
        contentId: string;
        disposition: "inline";
        filename: string;
        type: string;
    } | {
        content: string;
        disposition: "attachment";
        filename: string;
        type: string;
    })[];
    /** Body param: BCC recipient(s). A single email string or an array of email strings. */
    bcc?: string | string[];
    /** Body param: CC recipient(s). A single email string or an array of email strings. */
    cc?: string | string[];
    /** Body param: Custom email headers as key-value pairs. */
    headers?: Record<string, unknown>;
    /** Body param: HTML body of the email. At least one of text or html must be provided. */
    html?: string;
    /** Body param: Reply-to address. Either a plain string or an object with address and name. */
    replyTo?: string | {
        address: string;
        name: string;
    };
    /** Body param: Plain text body of the email. At least one of text or html must be provided. */
    text?: string;
}
export declare const SendEmailSendingRequest: Schema.Schema<SendEmailSendingRequest>;
export interface SendEmailSendingResponse {
    /** Email addresses to which the message was delivered immediately. */
    delivered: string[];
    /** Email addresses that permanently bounced. */
    permanentBounces: string[];
    /** Email addresses for which delivery was queued for later. */
    queued: string[];
}
export declare const SendEmailSendingResponse: Schema.Schema<SendEmailSendingResponse>;
export type SendEmailSendingError = DefaultErrors;
export declare const sendEmailSending: API.OperationMethod<SendEmailSendingRequest, SendEmailSendingResponse, SendEmailSendingError, Credentials | HttpClient.HttpClient>;
export interface SendRawEmailSendingRequest {
    /** Path param: Identifier of the account. */
    accountId: string;
    /** Body param: Sender email address. */
    from: string;
    /** Body param: The full MIME-encoded email message. Should include standard RFC 5322 headers such as From, To, Subject, and Content-Type. The from and recipients fields in the request body control SMTP e */
    mimeMessage: string;
    /** Body param: List of recipient email addresses. */
    recipients: string[];
}
export declare const SendRawEmailSendingRequest: Schema.Schema<SendRawEmailSendingRequest>;
export interface SendRawEmailSendingResponse {
    /** Email addresses to which the message was delivered immediately. */
    delivered: string[];
    /** Email addresses that permanently bounced. */
    permanentBounces: string[];
    /** Email addresses for which delivery was queued for later. */
    queued: string[];
}
export declare const SendRawEmailSendingResponse: Schema.Schema<SendRawEmailSendingResponse>;
export type SendRawEmailSendingError = DefaultErrors;
export declare const sendRawEmailSending: API.OperationMethod<SendRawEmailSendingRequest, SendRawEmailSendingResponse, SendRawEmailSendingError, Credentials | HttpClient.HttpClient>;
export interface GetSubdomainRequest {
    subdomainId: string;
    /** Identifier. */
    zoneId: string;
}
export declare const GetSubdomainRequest: Schema.Schema<GetSubdomainRequest>;
export interface GetSubdomainResponse {
    /** Whether Email Sending is enabled on this subdomain. */
    enabled: boolean;
    /** The subdomain domain name. */
    name: string;
    /** Sending subdomain identifier. */
    tag: string;
    /** The date and time the destination address has been created. */
    created?: string | null;
    /** The DKIM selector used for email signing. */
    dkimSelector?: string | null;
    /** The date and time the destination address was last modified. */
    modified?: string | null;
    /** The return-path domain used for bounce handling. */
    returnPathDomain?: string | null;
}
export declare const GetSubdomainResponse: Schema.Schema<GetSubdomainResponse>;
export type GetSubdomainError = DefaultErrors;
export declare const getSubdomain: API.OperationMethod<GetSubdomainRequest, GetSubdomainResponse, GetSubdomainError, Credentials | HttpClient.HttpClient>;
export interface ListSubdomainsRequest {
    /** Identifier. */
    zoneId: string;
}
export declare const ListSubdomainsRequest: Schema.Schema<ListSubdomainsRequest>;
export interface ListSubdomainsResponse {
    result: {
        enabled: boolean;
        name: string;
        tag: string;
        created?: string | null;
        dkimSelector?: string | null;
        modified?: string | null;
        returnPathDomain?: string | null;
    }[];
}
export declare const ListSubdomainsResponse: Schema.Schema<ListSubdomainsResponse>;
export type ListSubdomainsError = DefaultErrors;
export declare const listSubdomains: API.PaginatedOperationMethod<ListSubdomainsRequest, ListSubdomainsResponse, ListSubdomainsError, Credentials | HttpClient.HttpClient>;
export interface CreateSubdomainRequest {
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: The subdomain name. Must be within the zone. */
    name: string;
}
export declare const CreateSubdomainRequest: Schema.Schema<CreateSubdomainRequest>;
export interface CreateSubdomainResponse {
    /** Whether Email Sending is enabled on this subdomain. */
    enabled: boolean;
    /** The subdomain domain name. */
    name: string;
    /** Sending subdomain identifier. */
    tag: string;
    /** The date and time the destination address has been created. */
    created?: string | null;
    /** The DKIM selector used for email signing. */
    dkimSelector?: string | null;
    /** The date and time the destination address was last modified. */
    modified?: string | null;
    /** The return-path domain used for bounce handling. */
    returnPathDomain?: string | null;
}
export declare const CreateSubdomainResponse: Schema.Schema<CreateSubdomainResponse>;
export type CreateSubdomainError = DefaultErrors;
export declare const createSubdomain: API.OperationMethod<CreateSubdomainRequest, CreateSubdomainResponse, CreateSubdomainError, Credentials | HttpClient.HttpClient>;
export interface DeleteSubdomainRequest {
    subdomainId: string;
    /** Identifier. */
    zoneId: string;
}
export declare const DeleteSubdomainRequest: Schema.Schema<DeleteSubdomainRequest>;
export interface DeleteSubdomainResponse {
    errors: {
        code: number;
        message: string;
        documentationUrl?: string | null;
        source?: {
            pointer?: string | null;
        } | null;
    }[];
    messages: {
        code: number;
        message: string;
        documentationUrl?: string | null;
        source?: {
            pointer?: string | null;
        } | null;
    }[];
    /** Whether the API call was successful. */
    success: true;
}
export declare const DeleteSubdomainResponse: Schema.Schema<DeleteSubdomainResponse>;
export type DeleteSubdomainError = DefaultErrors;
export declare const deleteSubdomain: API.OperationMethod<DeleteSubdomainRequest, DeleteSubdomainResponse, DeleteSubdomainError, Credentials | HttpClient.HttpClient>;
export interface GetSubdomainDnsRequest {
    subdomainId: string;
    /** Identifier. */
    zoneId: string;
}
export declare const GetSubdomainDnsRequest: Schema.Schema<GetSubdomainDnsRequest>;
export interface GetSubdomainDnsResponse {
    result: {
        content?: string | null;
        name?: string | null;
        priority?: number | null;
        ttl?: number | "1" | null;
        type?: "A" | "AAAA" | "CNAME" | "HTTPS" | "TXT" | "SRV" | "LOC" | "MX" | "NS" | "CERT" | "DNSKEY" | "DS" | "NAPTR" | "SMIMEA" | "SSHFP" | "SVCB" | "TLSA" | "URI" | null;
    }[];
}
export declare const GetSubdomainDnsResponse: Schema.Schema<GetSubdomainDnsResponse>;
export type GetSubdomainDnsError = DefaultErrors;
export declare const getSubdomainDns: API.PaginatedOperationMethod<GetSubdomainDnsRequest, GetSubdomainDnsResponse, GetSubdomainDnsError, Credentials | HttpClient.HttpClient>;
//# sourceMappingURL=email-sending.d.ts.map