import http from 'http'; import type { OnThreadStop } from '../../core/types.js'; import type { HttpAdminContext } from '../context.js'; type JsonRpcId = string | number | null; type JsonRpcSuccess = { jsonrpc: '2.0'; id: JsonRpcId; result: Record; }; type JsonRpcError = { jsonrpc: '2.0'; id: JsonRpcId; error: { code: number; message: string; data?: Record; }; }; type SupenRpcContext = { adminContext: HttpAdminContext | null; onMessage: (chatJid: string, msg: any) => void; onThreadStop?: OnThreadStop; surface?: 'web' | 'cli' | 'dingtalk' | 'github' | 'system'; }; export declare function executeSupenRpc(request: unknown, context: SupenRpcContext): Promise; export declare function handleRpcRoutes(req: http.IncomingMessage, res: http.ServerResponse, pathname: string, method: string, adminContext: HttpAdminContext | null, onMessage: (chatJid: string, msg: any) => void, onThreadStop?: OnThreadStop): Promise; export {}; //# sourceMappingURL=rpc.d.ts.map