/**
 * Client-side protocol failures reported by unstable RPC transports.
 *
 * `RpcClientError` is the error type generated clients use when a call fails
 * before a remote handler can return its declared typed error. Its `reason`
 * covers built-in transport failures from HTTP, sockets, and workers, plus
 * `RpcClientDefect` values for malformed or incompatible protocol data.
 *
 * **Mental model**
 *
 * Handler errors belong to the RPC's declared error schema and are decoded from
 * the response exit. Client errors describe the client or transport boundary:
 * unavailable transport, aborted connections, unreadable response bodies,
 * failed response decoding, or protocol shapes that do not match the RPC group
 * the client was built for. Treat them as infrastructure or compatibility
 * failures rather than business-domain failures.
 *
 * **Common tasks**
 *
 * Inspect `error.reason._tag` to decide whether to retry, reconnect, report a
 * transport issue, or surface a schema or codec mismatch. Custom protocols can
 * use `RpcClientDefect` to put invalid client-side protocol state in the same
 * public error channel used by the built-in transports.
 *
 * **Gotchas**
 *
 * Server defects are sent through protocol messages and normally fail the call
 * as defects rather than as declared RPC errors. Serialization and schema
 * decode failures can appear as client defects because the client cannot safely
 * produce the typed success or error value promised by the RPC definition.
 *
 * @since 4.0.0
 */
import * as Schema from "../../Schema.ts";
import { HttpClientErrorSchema } from "../http/HttpClientError.ts";
declare const TypeId = "~effect/rpc/RpcClientError";
declare const RpcClientDefect_base: Schema.Class<RpcClientDefect, Schema.Struct<{
    readonly _tag: Schema.tag<"RpcClientDefect">;
    readonly message: Schema.String;
    readonly cause: Schema.Defect;
}>, import("../../Cause.ts").YieldableError>;
/**
 * Represents a client-side RPC defect, such as a protocol violation or
 * decoding failure, with a message and original cause.
 *
 * @category errors
 * @since 4.0.0
 */
export declare class RpcClientDefect extends RpcClientDefect_base {
}
declare const RpcClientError_base: Schema.Class<RpcClientError, Schema.Struct<{
    readonly _tag: Schema.tag<"RpcClientError">;
    readonly reason: Schema.Union<readonly [Schema.Union<[typeof import("../workers/WorkerError.ts").WorkerSpawnError, typeof import("../workers/WorkerError.ts").WorkerSendError, typeof import("../workers/WorkerError.ts").WorkerReceiveError, typeof import("../workers/WorkerError.ts").WorkerUnknownError]>, Schema.Union<readonly [typeof import("../socket/Socket.ts").SocketReadError, typeof import("../socket/Socket.ts").SocketWriteError, typeof import("../socket/Socket.ts").SocketOpenError, typeof import("../socket/Socket.ts").SocketCloseError]>, typeof HttpClientErrorSchema, typeof RpcClientDefect]>;
}>, import("../../Cause.ts").YieldableError>;
/**
 * Error wrapper for RPC client failures, including worker, socket, HTTP client,
 * and client protocol defect failures.
 *
 * @category errors
 * @since 4.0.0
 */
export declare class RpcClientError extends RpcClientError_base {
    /**
     * Marks this value as an RPC client error for runtime guards.
     *
     * @since 4.0.0
     */
    readonly [TypeId] = "~effect/rpc/RpcClientError";
    get message(): string;
}
export {};
//# sourceMappingURL=RpcClientError.d.ts.map