@hcmai/sdk 0.3.14 → 0.3.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -65,10 +65,11 @@ var manifest = JSON.parse(
65
65
  var SDK_VERSION = manifest.version;
66
66
 
67
67
  // src/http/client.ts
68
+ var DEFAULT_HTTP_TIMEOUT_MS = 6e4;
68
69
  function createHttpClient(opts) {
69
70
  const client = axios.create({
70
71
  baseURL: opts.endpoint,
71
- timeout: opts.timeoutMs ?? 6e4,
72
+ timeout: opts.timeoutMs ?? DEFAULT_HTTP_TIMEOUT_MS,
72
73
  headers: { "User-Agent": opts.userAgent ?? `hcmai-sdk/${SDK_VERSION}` }
73
74
  });
74
75
  attachTrace(client);
@@ -5446,8 +5447,20 @@ function parseSettingAssignment(raw) {
5446
5447
  }
5447
5448
 
5448
5449
  // src/fde/layout.ts
5449
- import { createHash as createHash3 } from "crypto";
5450
- import { existsSync as existsSync2, mkdirSync, readFileSync as readFileSync2, writeFileSync } from "fs";
5450
+ import { createHash as createHash3, randomBytes as randomBytes2 } from "crypto";
5451
+ import {
5452
+ closeSync,
5453
+ existsSync as existsSync2,
5454
+ fsyncSync,
5455
+ linkSync,
5456
+ mkdirSync,
5457
+ openSync,
5458
+ readFileSync as readFileSync2,
5459
+ renameSync,
5460
+ unlinkSync,
5461
+ writeFileSync,
5462
+ writeSync
5463
+ } from "fs";
5451
5464
  import * as path6 from "path";
5452
5465
  var UNSAFE = /[^A-Za-z0-9._-]/g;
5453
5466
  function slug(value) {
@@ -5776,7 +5789,7 @@ function networkOutcome() {
5776
5789
  }
5777
5790
 
5778
5791
  // src/fde/recon/runner.ts
5779
- import { randomBytes as randomBytes2 } from "crypto";
5792
+ import { randomBytes as randomBytes3 } from "crypto";
5780
5793
  import { existsSync as existsSync4, readFileSync as readFileSync3, readdirSync } from "fs";
5781
5794
  import * as path8 from "path";
5782
5795
 
@@ -7143,7 +7156,7 @@ function parseRoundStamp(stamp) {
7143
7156
  return new Date(Date.UTC(+y, +mo - 1, +d, +h, +mi, +s));
7144
7157
  }
7145
7158
  function newRoundId(started) {
7146
- return `${roundStamp(started)}-${randomBytes2(4).toString("hex")}`;
7159
+ return `${roundStamp(started)}-${randomBytes3(4).toString("hex")}`;
7147
7160
  }
7148
7161
  function isRecord5(v) {
7149
7162
  return Boolean(v) && typeof v === "object" && !Array.isArray(v);