TypeScript SDK
@h3llo/sdk — ESM, fetch-based, с поддержкой AbortSignal.
npm install @h3llo/sdkМинимальный пример
import { H3Client } from "@h3llo/sdk";
const h3 = new H3Client({ token: process.env.H3_TOKEN! });
const { items } = await h3.instances.list({ project: "prod" });
for (const i of items) {
console.log(i.name, i.network.publicIPv4);
}Long-running
const op = await h3.k8s.upgrade("prod", { version: "1.32" });
const result = await op.wait();AbortSignal
const ac = new AbortController();
setTimeout(() => ac.abort(), 5_000);
const { items } = await h3.instances.list(
{ project: "prod" },
{ signal: ac.signal },
);