/** * OpenRPC `components.errors` derived from the closed `FaultCode` union. * * @module server/openrpc-errors */ import { z } from 'zod'; export declare const UnauthorizedDataSchema: z.ZodObject<{ reason: z.ZodString; }, z.core.$strip>; export declare const ForbiddenDataSchema: z.ZodObject<{ reason: z.ZodString; }, z.core.$strip>; export declare const NotFoundDataSchema: z.ZodObject<{ resource: z.ZodString; identifier: z.ZodOptional; }, z.core.$strip>; export declare const ConflictDataSchema: z.ZodObject<{ reason: z.ZodString; }, z.core.$strip>; export declare const UnprocessableDataSchema: z.ZodObject<{ reason: z.ZodString; }, z.core.$strip>; export declare const TimeoutDataSchema: z.ZodObject<{ operationName: z.ZodOptional; }, z.core.$strip>; export declare const PayloadTooLargeDataSchema: z.ZodObject<{ maxBytes: z.ZodNumber; }, z.core.$strip>; export declare const NotImplementedDataSchema: z.ZodObject<{}, z.core.$strip>; export declare const UnsupportedTransportDataSchema: z.ZodObject<{ transport: z.ZodEnum<{ "http-rest": "http-rest"; jsonRpcHttp: "jsonRpcHttp"; jsonRpcWebSocket: "jsonRpcWebSocket"; jsonRpcStdio: "jsonRpcStdio"; }>; supported: z.ZodReadonly>>; }, z.core.$strip>; export declare const SubscriptionOverflowDataSchema: z.ZodObject<{ subscriptionId: z.ZodString; droppedCount: z.ZodNumber; }, z.core.$strip>; export declare const InvalidParamsDataSchema: z.ZodObject<{ issues: z.ZodReadonly>>; message: z.ZodString; code: z.ZodString; }, z.core.$strip>>>; }, z.core.$strip>; export declare const MethodNotFoundDataSchema: z.ZodObject<{ method: z.ZodString; }, z.core.$strip>; export declare const EngineFailureDataSchema: z.ZodObject<{}, z.core.$strip>; type OpenRpcError = { code: number; message: string; data?: Record; 'x-http-status': number; }; /** * Build the `components.errors` array for an OpenRPC document. * * Derived from `FAULT_CODE_TO_JSON_RPC_CODE` (the single source of truth). * Every `FaultCode` in the closed union gets one entry with: * - `code`: JSON-RPC error code * - `message`: human-readable fault name * - `data`: JSON Schema from the Zod schema for that fault's data payload * - `x-http-status`: HTTP status code for REST callers */ export declare function buildOpenRpcComponentsErrors(): Record; export {};