@devries-cameron20 / t3code Mirror · read-only
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 21, 04:45 UTC

main
ts 12 lines 571 Bytes
Raw
1 import { WsRpcGroup } from "@t3tools/contracts";
2 import * as Effect from "effect/Effect";
3 import { RpcClient } from "effect/rpc";
4
5 export const makeWsRpcProtocolClient = RpcClient.make(WsRpcGroup);
6 type RpcClientFactory = typeof makeWsRpcProtocolClient;
7 export type WsRpcProtocolClient =
8 RpcClientFactory extends Effect.Effect<infer Client, any, any> ? Client : never;
9
10 // Pings go out every 5 seconds, and a server busy for a few seconds stops
11 // answering them. Allow 15 seconds without any frame before dropping the socket.
12 export const PING_TIMEOUT = "15 seconds";