/**
 * Cloudflare EMAIL-ROUTING API
 *
 * Generated from Cloudflare TypeScript SDK.
 * DO NOT EDIT - regenerate with: bun scripts/generate.ts --service email-routing
 */
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 GetAddressRequest {
    destinationAddressIdentifier: string;
    /** Identifier. */
    accountId: string;
}
export declare const GetAddressRequest: Schema.Schema<GetAddressRequest>;
export interface GetAddressResponse {
    /** Destination address identifier. */
    id?: string | null;
    /** The date and time the destination address has been created. */
    created?: string | null;
    /** The contact email address of the user. */
    email?: string | null;
    /** The date and time the destination address was last modified. */
    modified?: string | null;
    /** @deprecated Destination address tag. (Deprecated, replaced by destination address identifier) */
    tag?: string | null;
    /** The date and time the destination address has been verified. Null means not verified yet. */
    verified?: string | null;
}
export declare const GetAddressResponse: Schema.Schema<GetAddressResponse>;
export type GetAddressError = DefaultErrors;
export declare const getAddress: API.OperationMethod<GetAddressRequest, GetAddressResponse, GetAddressError, Credentials | HttpClient.HttpClient>;
export interface ListAddressesRequest {
    /** Path param: Identifier. */
    accountId: string;
    page?: number;
    perPage?: number;
    /** Query param: Sorts results in an ascending or descending order. */
    direction?: "asc" | "desc";
    /** Query param: Filter by verified destination addresses. */
    verified?: true | false;
}
export declare const ListAddressesRequest: Schema.Schema<ListAddressesRequest>;
export interface ListAddressesResponse {
    result: {
        id?: string | null;
        created?: string | null;
        email?: string | null;
        modified?: string | null;
        tag?: string | null;
        verified?: string | null;
    }[];
    resultInfo?: {
        count?: number | null;
        page?: number | null;
        perPage?: number | null;
        totalCount?: number | null;
    } | null;
}
export declare const ListAddressesResponse: Schema.Schema<ListAddressesResponse>;
export type ListAddressesError = DefaultErrors;
export declare const listAddresses: API.PaginatedOperationMethod<ListAddressesRequest, ListAddressesResponse, ListAddressesError, Credentials | HttpClient.HttpClient>;
export interface CreateAddressRequest {
    /** Path param: Identifier. */
    accountId: string;
    /** Body param: The contact email address of the user. */
    email: string;
}
export declare const CreateAddressRequest: Schema.Schema<CreateAddressRequest>;
export interface CreateAddressResponse {
    /** Destination address identifier. */
    id?: string | null;
    /** The date and time the destination address has been created. */
    created?: string | null;
    /** The contact email address of the user. */
    email?: string | null;
    /** The date and time the destination address was last modified. */
    modified?: string | null;
    /** @deprecated Destination address tag. (Deprecated, replaced by destination address identifier) */
    tag?: string | null;
    /** The date and time the destination address has been verified. Null means not verified yet. */
    verified?: string | null;
}
export declare const CreateAddressResponse: Schema.Schema<CreateAddressResponse>;
export type CreateAddressError = DefaultErrors;
export declare const createAddress: API.OperationMethod<CreateAddressRequest, CreateAddressResponse, CreateAddressError, Credentials | HttpClient.HttpClient>;
export interface DeleteAddressRequest {
    destinationAddressIdentifier: string;
    /** Identifier. */
    accountId: string;
}
export declare const DeleteAddressRequest: Schema.Schema<DeleteAddressRequest>;
export interface DeleteAddressResponse {
    /** Destination address identifier. */
    id?: string | null;
    /** The date and time the destination address has been created. */
    created?: string | null;
    /** The contact email address of the user. */
    email?: string | null;
    /** The date and time the destination address was last modified. */
    modified?: string | null;
    /** @deprecated Destination address tag. (Deprecated, replaced by destination address identifier) */
    tag?: string | null;
    /** The date and time the destination address has been verified. Null means not verified yet. */
    verified?: string | null;
}
export declare const DeleteAddressResponse: Schema.Schema<DeleteAddressResponse>;
export type DeleteAddressError = DefaultErrors;
export declare const deleteAddress: API.OperationMethod<DeleteAddressRequest, DeleteAddressResponse, DeleteAddressError, Credentials | HttpClient.HttpClient>;
export interface GetDnsRequest {
    /** Path param: Identifier. */
    zoneId: string;
    /** Query param: Domain of your zone. */
    subdomain?: string;
}
export declare const GetDnsRequest: Schema.Schema<GetDnsRequest>;
export type GetDnsResponse = {
    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;
    }[];
    success: true;
    result?: {
        errors?: {
            code?: string | null;
            missing?: {
                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;
            } | null;
        }[] | null;
        record?: {
            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;
        }[] | null;
    } | null;
    resultInfo?: {
        count?: number | null;
        page?: number | null;
        perPage?: number | null;
        totalCount?: number | null;
    } | null;
} | {
    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;
    }[];
    success: true;
    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;
    }[] | null;
    resultInfo?: {
        count?: number | null;
        page?: number | null;
        perPage?: number | null;
        totalCount?: number | null;
    } | null;
};
export declare const GetDnsResponse: Schema.Schema<GetDnsResponse>;
export type GetDnsError = DefaultErrors;
export declare const getDns: API.OperationMethod<GetDnsRequest, GetDnsResponse, GetDnsError, Credentials | HttpClient.HttpClient>;
export interface CreateDnsRequest {
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: Domain of your zone. */
    name?: string;
}
export declare const CreateDnsRequest: Schema.Schema<CreateDnsRequest>;
export interface CreateDnsResponse {
    /** Email Routing settings identifier. */
    id: string;
    /** State of the zone settings for Email Routing. */
    enabled: true | false;
    /** Domain of your zone. */
    name: string;
    /** The date and time the settings have been created. */
    created?: string | null;
    /** The date and time the settings have been modified. */
    modified?: string | null;
    /** Flag to check if the user skipped the configuration wizard. */
    skipWizard?: true | false | null;
    /** Show the state of your account, and the type or configuration error. */
    status?: "ready" | "unconfigured" | "misconfigured" | "misconfigured/locked" | "unlocked" | null;
    /** @deprecated Email Routing settings tag. (Deprecated, replaced by Email Routing settings identifier) */
    tag?: string | null;
}
export declare const CreateDnsResponse: Schema.Schema<CreateDnsResponse>;
export type CreateDnsError = DefaultErrors;
export declare const createDns: API.OperationMethod<CreateDnsRequest, CreateDnsResponse, CreateDnsError, Credentials | HttpClient.HttpClient>;
export interface PatchDnsRequest {
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: Domain of your zone. */
    name?: string;
}
export declare const PatchDnsRequest: Schema.Schema<PatchDnsRequest>;
export interface PatchDnsResponse {
    /** Email Routing settings identifier. */
    id: string;
    /** State of the zone settings for Email Routing. */
    enabled: true | false;
    /** Domain of your zone. */
    name: string;
    /** The date and time the settings have been created. */
    created?: string | null;
    /** The date and time the settings have been modified. */
    modified?: string | null;
    /** Flag to check if the user skipped the configuration wizard. */
    skipWizard?: true | false | null;
    /** Show the state of your account, and the type or configuration error. */
    status?: "ready" | "unconfigured" | "misconfigured" | "misconfigured/locked" | "unlocked" | null;
    /** @deprecated Email Routing settings tag. (Deprecated, replaced by Email Routing settings identifier) */
    tag?: string | null;
}
export declare const PatchDnsResponse: Schema.Schema<PatchDnsResponse>;
export type PatchDnsError = DefaultErrors;
export declare const patchDns: API.OperationMethod<PatchDnsRequest, PatchDnsResponse, PatchDnsError, Credentials | HttpClient.HttpClient>;
export interface DeleteDnsRequest {
    /** Identifier. */
    zoneId: string;
}
export declare const DeleteDnsRequest: Schema.Schema<DeleteDnsRequest>;
export interface DeleteDnsResponse {
    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 DeleteDnsResponse: Schema.Schema<DeleteDnsResponse>;
export type DeleteDnsError = DefaultErrors;
export declare const deleteDns: API.PaginatedOperationMethod<DeleteDnsRequest, DeleteDnsResponse, DeleteDnsError, Credentials | HttpClient.HttpClient>;
export interface GetEmailRoutingRequest {
    /** Identifier. */
    zoneId: string;
}
export declare const GetEmailRoutingRequest: Schema.Schema<GetEmailRoutingRequest>;
export interface GetEmailRoutingResponse {
    /** Email Routing settings identifier. */
    id: string;
    /** State of the zone settings for Email Routing. */
    enabled: true | false;
    /** Domain of your zone. */
    name: string;
    /** The date and time the settings have been created. */
    created?: string | null;
    /** The date and time the settings have been modified. */
    modified?: string | null;
    /** Flag to check if the user skipped the configuration wizard. */
    skipWizard?: true | false | null;
    /** Show the state of your account, and the type or configuration error. */
    status?: "ready" | "unconfigured" | "misconfigured" | "misconfigured/locked" | "unlocked" | null;
    /** @deprecated Email Routing settings tag. (Deprecated, replaced by Email Routing settings identifier) */
    tag?: string | null;
}
export declare const GetEmailRoutingResponse: Schema.Schema<GetEmailRoutingResponse>;
export type GetEmailRoutingError = DefaultErrors;
export declare const getEmailRouting: API.OperationMethod<GetEmailRoutingRequest, GetEmailRoutingResponse, GetEmailRoutingError, Credentials | HttpClient.HttpClient>;
export interface EnableEmailRoutingRequest {
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: */
    body: unknown;
}
export declare const EnableEmailRoutingRequest: Schema.Schema<EnableEmailRoutingRequest>;
export interface EnableEmailRoutingResponse {
    /** Email Routing settings identifier. */
    id: string;
    /** State of the zone settings for Email Routing. */
    enabled: true | false;
    /** Domain of your zone. */
    name: string;
    /** The date and time the settings have been created. */
    created?: string | null;
    /** The date and time the settings have been modified. */
    modified?: string | null;
    /** Flag to check if the user skipped the configuration wizard. */
    skipWizard?: true | false | null;
    /** Show the state of your account, and the type or configuration error. */
    status?: "ready" | "unconfigured" | "misconfigured" | "misconfigured/locked" | "unlocked" | null;
    /** @deprecated Email Routing settings tag. (Deprecated, replaced by Email Routing settings identifier) */
    tag?: string | null;
}
export declare const EnableEmailRoutingResponse: Schema.Schema<EnableEmailRoutingResponse>;
export type EnableEmailRoutingError = DefaultErrors;
export declare const enableEmailRouting: API.OperationMethod<EnableEmailRoutingRequest, EnableEmailRoutingResponse, EnableEmailRoutingError, Credentials | HttpClient.HttpClient>;
export interface DisableEmailRoutingRequest {
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: */
    body: unknown;
}
export declare const DisableEmailRoutingRequest: Schema.Schema<DisableEmailRoutingRequest>;
export interface DisableEmailRoutingResponse {
    /** Email Routing settings identifier. */
    id: string;
    /** State of the zone settings for Email Routing. */
    enabled: true | false;
    /** Domain of your zone. */
    name: string;
    /** The date and time the settings have been created. */
    created?: string | null;
    /** The date and time the settings have been modified. */
    modified?: string | null;
    /** Flag to check if the user skipped the configuration wizard. */
    skipWizard?: true | false | null;
    /** Show the state of your account, and the type or configuration error. */
    status?: "ready" | "unconfigured" | "misconfigured" | "misconfigured/locked" | "unlocked" | null;
    /** @deprecated Email Routing settings tag. (Deprecated, replaced by Email Routing settings identifier) */
    tag?: string | null;
}
export declare const DisableEmailRoutingResponse: Schema.Schema<DisableEmailRoutingResponse>;
export type DisableEmailRoutingError = DefaultErrors;
export declare const disableEmailRouting: API.OperationMethod<DisableEmailRoutingRequest, DisableEmailRoutingResponse, DisableEmailRoutingError, Credentials | HttpClient.HttpClient>;
export interface GetRuleRequest {
    ruleIdentifier: string;
    /** Identifier. */
    zoneId: string;
}
export declare const GetRuleRequest: Schema.Schema<GetRuleRequest>;
export interface GetRuleResponse {
    /** Routing rule identifier. */
    id?: string | null;
    /** List actions patterns. */
    actions?: {
        type: "drop" | "forward" | "worker";
        value?: string[] | null;
    }[] | null;
    /** Routing rule status. */
    enabled?: true | false | null;
    /** Matching patterns to forward to your actions. */
    matchers?: {
        type: "all" | "literal";
        field?: "to" | null;
        value?: string | null;
    }[] | null;
    /** Routing rule name. */
    name?: string | null;
    /** Priority of the routing rule. */
    priority?: number | null;
    /** @deprecated Routing rule tag. (Deprecated, replaced by routing rule identifier) */
    tag?: string | null;
}
export declare const GetRuleResponse: Schema.Schema<GetRuleResponse>;
export type GetRuleError = DefaultErrors;
export declare const getRule: API.OperationMethod<GetRuleRequest, GetRuleResponse, GetRuleError, Credentials | HttpClient.HttpClient>;
export interface ListRulesRequest {
    /** Path param: Identifier. */
    zoneId: string;
    page?: number;
    perPage?: number;
    /** Query param: Filter by enabled routing rules. */
    enabled?: true | false;
}
export declare const ListRulesRequest: Schema.Schema<ListRulesRequest>;
export interface ListRulesResponse {
    result: {
        id?: string | null;
        actions?: {
            type: "drop" | "forward" | "worker";
            value?: string[] | null;
        }[] | null;
        enabled?: true | false | null;
        matchers?: {
            type: "all" | "literal";
            field?: "to" | null;
            value?: string | null;
        }[] | null;
        name?: string | null;
        priority?: number | null;
        tag?: string | null;
    }[];
    resultInfo?: {
        count?: number | null;
        page?: number | null;
        perPage?: number | null;
        totalCount?: number | null;
    } | null;
}
export declare const ListRulesResponse: Schema.Schema<ListRulesResponse>;
export type ListRulesError = DefaultErrors;
export declare const listRules: API.PaginatedOperationMethod<ListRulesRequest, ListRulesResponse, ListRulesError, Credentials | HttpClient.HttpClient>;
export interface CreateRuleRequest {
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: List actions patterns. */
    actions: {
        type: "drop" | "forward" | "worker";
        value?: string[];
    }[];
    /** Body param: Matching patterns to forward to your actions. */
    matchers: {
        type: "all" | "literal";
        field?: "to";
        value?: string;
    }[];
    /** Body param: Routing rule status. */
    enabled?: true | false;
    /** Body param: Routing rule name. */
    name?: string;
    /** Body param: Priority of the routing rule. */
    priority?: number;
}
export declare const CreateRuleRequest: Schema.Schema<CreateRuleRequest>;
export interface CreateRuleResponse {
    /** Routing rule identifier. */
    id?: string | null;
    /** List actions patterns. */
    actions?: {
        type: "drop" | "forward" | "worker";
        value?: string[] | null;
    }[] | null;
    /** Routing rule status. */
    enabled?: true | false | null;
    /** Matching patterns to forward to your actions. */
    matchers?: {
        type: "all" | "literal";
        field?: "to" | null;
        value?: string | null;
    }[] | null;
    /** Routing rule name. */
    name?: string | null;
    /** Priority of the routing rule. */
    priority?: number | null;
    /** @deprecated Routing rule tag. (Deprecated, replaced by routing rule identifier) */
    tag?: string | null;
}
export declare const CreateRuleResponse: Schema.Schema<CreateRuleResponse>;
export type CreateRuleError = DefaultErrors;
export declare const createRule: API.OperationMethod<CreateRuleRequest, CreateRuleResponse, CreateRuleError, Credentials | HttpClient.HttpClient>;
export interface UpdateRuleRequest {
    ruleIdentifier: string;
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: List actions patterns. */
    actions: {
        type: "drop" | "forward" | "worker";
        value?: string[];
    }[];
    /** Body param: Matching patterns to forward to your actions. */
    matchers: {
        type: "all" | "literal";
        field?: "to";
        value?: string;
    }[];
    /** Body param: Routing rule status. */
    enabled?: true | false;
    /** Body param: Routing rule name. */
    name?: string;
    /** Body param: Priority of the routing rule. */
    priority?: number;
}
export declare const UpdateRuleRequest: Schema.Schema<UpdateRuleRequest>;
export interface UpdateRuleResponse {
    /** Routing rule identifier. */
    id?: string | null;
    /** List actions patterns. */
    actions?: {
        type: "drop" | "forward" | "worker";
        value?: string[] | null;
    }[] | null;
    /** Routing rule status. */
    enabled?: true | false | null;
    /** Matching patterns to forward to your actions. */
    matchers?: {
        type: "all" | "literal";
        field?: "to" | null;
        value?: string | null;
    }[] | null;
    /** Routing rule name. */
    name?: string | null;
    /** Priority of the routing rule. */
    priority?: number | null;
    /** @deprecated Routing rule tag. (Deprecated, replaced by routing rule identifier) */
    tag?: string | null;
}
export declare const UpdateRuleResponse: Schema.Schema<UpdateRuleResponse>;
export type UpdateRuleError = DefaultErrors;
export declare const updateRule: API.OperationMethod<UpdateRuleRequest, UpdateRuleResponse, UpdateRuleError, Credentials | HttpClient.HttpClient>;
export interface DeleteRuleRequest {
    ruleIdentifier: string;
    /** Identifier. */
    zoneId: string;
}
export declare const DeleteRuleRequest: Schema.Schema<DeleteRuleRequest>;
export interface DeleteRuleResponse {
    /** Routing rule identifier. */
    id?: string | null;
    /** List actions patterns. */
    actions?: {
        type: "drop" | "forward" | "worker";
        value?: string[] | null;
    }[] | null;
    /** Routing rule status. */
    enabled?: true | false | null;
    /** Matching patterns to forward to your actions. */
    matchers?: {
        type: "all" | "literal";
        field?: "to" | null;
        value?: string | null;
    }[] | null;
    /** Routing rule name. */
    name?: string | null;
    /** Priority of the routing rule. */
    priority?: number | null;
    /** @deprecated Routing rule tag. (Deprecated, replaced by routing rule identifier) */
    tag?: string | null;
}
export declare const DeleteRuleResponse: Schema.Schema<DeleteRuleResponse>;
export type DeleteRuleError = DefaultErrors;
export declare const deleteRule: API.OperationMethod<DeleteRuleRequest, DeleteRuleResponse, DeleteRuleError, Credentials | HttpClient.HttpClient>;
export interface GetRuleCatchAllRequest {
    /** Identifier. */
    zoneId: string;
}
export declare const GetRuleCatchAllRequest: Schema.Schema<GetRuleCatchAllRequest>;
export interface GetRuleCatchAllResponse {
    /** Routing rule identifier. */
    id?: string | null;
    /** List actions for the catch-all routing rule. */
    actions?: {
        type: "drop" | "forward" | "worker";
        value?: string[] | null;
    }[] | null;
    /** Routing rule status. */
    enabled?: true | false | null;
    /** List of matchers for the catch-all routing rule. */
    matchers?: {
        type: "all";
    }[] | null;
    /** Routing rule name. */
    name?: string | null;
    /** @deprecated Routing rule tag. (Deprecated, replaced by routing rule identifier) */
    tag?: string | null;
}
export declare const GetRuleCatchAllResponse: Schema.Schema<GetRuleCatchAllResponse>;
export type GetRuleCatchAllError = DefaultErrors;
export declare const getRuleCatchAll: API.OperationMethod<GetRuleCatchAllRequest, GetRuleCatchAllResponse, GetRuleCatchAllError, Credentials | HttpClient.HttpClient>;
export interface PutRuleCatchAllRequest {
    /** Path param: Identifier. */
    zoneId: string;
    /** Body param: List actions for the catch-all routing rule. */
    actions: {
        type: "drop" | "forward" | "worker";
        value?: string[];
    }[];
    /** Body param: List of matchers for the catch-all routing rule. */
    matchers: {
        type: "all";
    }[];
    /** Body param: Routing rule status. */
    enabled?: true | false;
    /** Body param: Routing rule name. */
    name?: string;
}
export declare const PutRuleCatchAllRequest: Schema.Schema<PutRuleCatchAllRequest>;
export interface PutRuleCatchAllResponse {
    /** Routing rule identifier. */
    id?: string | null;
    /** List actions for the catch-all routing rule. */
    actions?: {
        type: "drop" | "forward" | "worker";
        value?: string[] | null;
    }[] | null;
    /** Routing rule status. */
    enabled?: true | false | null;
    /** List of matchers for the catch-all routing rule. */
    matchers?: {
        type: "all";
    }[] | null;
    /** Routing rule name. */
    name?: string | null;
    /** @deprecated Routing rule tag. (Deprecated, replaced by routing rule identifier) */
    tag?: string | null;
}
export declare const PutRuleCatchAllResponse: Schema.Schema<PutRuleCatchAllResponse>;
export type PutRuleCatchAllError = DefaultErrors;
export declare const putRuleCatchAll: API.OperationMethod<PutRuleCatchAllRequest, PutRuleCatchAllResponse, PutRuleCatchAllError, Credentials | HttpClient.HttpClient>;
//# sourceMappingURL=email-routing.d.ts.map