import type { ClientRPCRequestParams, ClientRPCResponseResult } from './types.js'; import type { Session } from '../sessions/index.js'; import type { JSONRPCRequest, JSONRPCResponse, MiddlewareFactory } from '@matrixai/rpc'; import type SessionManager from '../sessions/SessionManager.js'; import type KeyRing from '../keys/KeyRing.js'; declare function middlewareServer(sessionManager: SessionManager, keyRing: KeyRing, customMiddlewareFactory?: MiddlewareFactory, JSONRPCRequest, JSONRPCResponse, JSONRPCResponse>): MiddlewareFactory, JSONRPCRequest, JSONRPCResponse, JSONRPCResponse>; declare function middlewareClient(session: Session, customMiddlewareFactory?: MiddlewareFactory, JSONRPCRequest, JSONRPCResponse, JSONRPCResponse>): MiddlewareFactory, JSONRPCRequest, JSONRPCResponse, JSONRPCResponse>; export { middlewareServer, middlewareClient };