UNPKG

@juspay/neurolink

Version:

The pipe layer of an AI nervous system: one interface connecting provider neurons to your application, across three inference types — generate, stream and decide. `decide` returns typed, calibrated judgements from a non-generative model (~400ms, ~$0.00002

25 lines (24 loc) • 892 B
/** * Types for the safe-fetch utility (SSRF-hardened binary downloads). * * Runtime helper lives in `src/lib/utils/safeFetch.ts`. */ /** * One validated address the pinned connect layer is allowed to dial. * Produced by `ssrfGuard.ts:validateAndResolveUrl`, consumed by * `safeFetch.ts:buildPinnedAgent`. */ export type PinnedAddress = { ip: string; family: 4 | 6; }; export type SafeDownloadOptions = { /** Hard cap on response size in bytes. Pass MAX_VIDEO_BYTES/MAX_AUDIO_BYTES/MAX_IMAGE_BYTES from sizeGuard. */ maxBytes: number; /** Human-readable identifier used in error messages (e.g. "HeyGen video"). */ label: string; /** Optional abort signal for caller-driven cancellation. */ signal?: AbortSignal; /** Optional HTTP transfer timeout (ms), covering headers and body after URL validation. Default: 60_000. */ timeoutMs?: number; };