UNPKG

@anthropic-ai/sdk

Version:

The official TypeScript library for the Anthropic API

15 lines (13 loc) 474 B
/** * Disclaimer: modules in _shims aren't intended to be imported by SDK users. */ import { type Shims } from "./registry.js"; import { getRuntime as getWebRuntime } from "./web-runtime.js"; import { ReadStream as FsReadStream } from 'node:fs'; export function getRuntime(): Shims { const runtime = getWebRuntime(); function isFsReadStream(value: any): value is FsReadStream { return value instanceof FsReadStream; } return { ...runtime, isFsReadStream }; }