@ai-matrx/api 0.1.20 → 0.1.22
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/CHANGELOG.md +12 -0
- package/dist/account.d.cts +2 -2
- package/dist/account.d.ts +2 -2
- package/dist/agents.cjs +12 -12
- package/dist/agents.d.cts +126 -4
- package/dist/agents.d.ts +126 -4
- package/dist/agents.js +2 -2
- package/dist/ai.cjs +3 -3
- package/dist/ai.d.cts +2 -2
- package/dist/ai.d.ts +2 -2
- package/dist/ai.js +2 -2
- package/dist/apps.cjs +6 -6
- package/dist/apps.d.cts +2 -2
- package/dist/apps.d.ts +2 -2
- package/dist/apps.js +2 -2
- package/dist/architecture.cjs +11 -11
- package/dist/architecture.d.cts +2 -2
- package/dist/architecture.d.ts +2 -2
- package/dist/architecture.js +2 -2
- package/dist/audio.cjs +5 -5
- package/dist/audio.d.cts +2 -2
- package/dist/audio.d.ts +2 -2
- package/dist/audio.js +2 -2
- package/dist/chat.cjs +12 -60
- package/dist/chat.d.cts +4 -116
- package/dist/chat.d.ts +4 -116
- package/dist/chat.js +3 -43
- package/dist/{chunk-PKYPPATQ.cjs → chunk-2SXAAKGV.cjs} +45 -100
- package/dist/{chunk-JRPLPAIX.js → chunk-3M4Y376I.js} +5 -89
- package/dist/chunk-FNIYADWI.cjs +59 -0
- package/dist/{chunk-EV7AXV2X.cjs → chunk-FSXBRXRX.cjs} +8 -101
- package/dist/{chunk-PIPE5OML.js → chunk-KIEAFMKB.js} +46 -100
- package/dist/chunk-YTEOFGFC.js +57 -0
- package/dist/code.cjs +7 -7
- package/dist/code.d.cts +2 -2
- package/dist/code.d.ts +2 -2
- package/dist/code.js +2 -2
- package/dist/commerce.d.cts +2 -2
- package/dist/commerce.d.ts +2 -2
- package/dist/communications.cjs +5 -5
- package/dist/communications.d.cts +2 -2
- package/dist/communications.d.ts +2 -2
- package/dist/communications.js +2 -2
- package/dist/computer.cjs +5 -5
- package/dist/computer.d.cts +2 -2
- package/dist/computer.d.ts +2 -2
- package/dist/computer.js +2 -2
- package/dist/content.cjs +5 -5
- package/dist/content.d.cts +2 -2
- package/dist/content.d.ts +2 -2
- package/dist/content.js +2 -2
- package/dist/crm.cjs +3 -3
- package/dist/crm.d.cts +2 -2
- package/dist/crm.d.ts +2 -2
- package/dist/crm.js +2 -2
- package/dist/data.cjs +4 -4
- package/dist/data.d.cts +2 -2
- package/dist/data.d.ts +2 -2
- package/dist/data.js +2 -2
- package/dist/education.cjs +5 -5
- package/dist/education.d.cts +2 -2
- package/dist/education.d.ts +2 -2
- package/dist/education.js +2 -2
- package/dist/files.cjs +21 -21
- package/dist/files.d.cts +2 -2
- package/dist/files.d.ts +2 -2
- package/dist/files.js +2 -2
- package/dist/human-resources.d.cts +2 -2
- package/dist/human-resources.d.ts +2 -2
- package/dist/{index-YFW4xNti.d.cts → index-oZNMwcTG.d.cts} +3 -3
- package/dist/{index-YFW4xNti.d.ts → index-oZNMwcTG.d.ts} +3 -3
- package/dist/index.cjs +86 -129
- package/dist/index.d.cts +7 -122
- package/dist/index.d.ts +7 -122
- package/dist/index.js +8 -15
- package/dist/integrations.cjs +4 -4
- package/dist/integrations.d.cts +2 -2
- package/dist/integrations.d.ts +2 -2
- package/dist/integrations.js +2 -2
- package/dist/intelligence.cjs +8 -8
- package/dist/intelligence.d.cts +3 -3
- package/dist/intelligence.d.ts +3 -3
- package/dist/intelligence.js +3 -3
- package/dist/{keys.generated-DPvmbTFD.d.cts → keys.generated-DE-t9kzx.d.cts} +2 -2
- package/dist/{keys.generated-DPvmbTFD.d.ts → keys.generated-DE-t9kzx.d.ts} +2 -2
- package/dist/knowledge.cjs +43 -43
- package/dist/knowledge.d.cts +2 -2
- package/dist/knowledge.d.ts +2 -2
- package/dist/knowledge.js +2 -2
- package/dist/legal.cjs +7 -7
- package/dist/legal.d.cts +2 -2
- package/dist/legal.d.ts +2 -2
- package/dist/legal.js +2 -2
- package/dist/marketing.cjs +77 -77
- package/dist/marketing.d.cts +2 -2
- package/dist/marketing.d.ts +2 -2
- package/dist/marketing.js +2 -2
- package/dist/masterwork.cjs +33 -33
- package/dist/masterwork.d.cts +2 -2
- package/dist/masterwork.d.ts +2 -2
- package/dist/masterwork.js +2 -2
- package/dist/media.cjs +12 -12
- package/dist/media.d.cts +2 -2
- package/dist/media.d.ts +2 -2
- package/dist/media.js +2 -2
- package/dist/net.cjs +20 -19
- package/dist/net.js +2 -1
- package/dist/platform.cjs +4 -4
- package/dist/platform.d.cts +2 -2
- package/dist/platform.d.ts +2 -2
- package/dist/platform.js +2 -2
- package/dist/publish.cjs +8 -8
- package/dist/publish.d.cts +2 -2
- package/dist/publish.d.ts +2 -2
- package/dist/publish.js +2 -2
- package/dist/schemas.d.cts +3 -125
- package/dist/schemas.d.ts +3 -125
- package/dist/stream.cjs +11 -11
- package/dist/stream.d.cts +1 -1
- package/dist/stream.d.ts +1 -1
- package/dist/stream.js +2 -2
- package/dist/types.d.cts +6 -210
- package/dist/types.d.ts +6 -210
- package/dist/web.cjs +27 -27
- package/dist/web.d.cts +2 -2
- package/dist/web.d.ts +2 -2
- package/dist/web.js +2 -2
- package/dist/workflows.cjs +14 -14
- package/dist/workflows.d.cts +2 -2
- package/dist/workflows.d.ts +2 -2
- package/dist/workflows.js +2 -2
- package/package.json +2 -2
|
@@ -1,92 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk2SXAAKGV_cjs = require('./chunk-2SXAAKGV.cjs');
|
|
4
4
|
var uuid = require('@ai-matrx/kit/uuid');
|
|
5
5
|
var credentials = require('@ai-matrx/auth/credentials');
|
|
6
6
|
|
|
7
|
-
// src/core/protocol.ts
|
|
8
|
-
var MATRX_AI_API_VERSION_DEFAULT = "v2";
|
|
9
|
-
var V2_COVERED_AI_PATH_TEMPLATES = [
|
|
10
|
-
"/ai/manual",
|
|
11
|
-
"/ai/chat",
|
|
12
|
-
"/ai/agents/{agent_id}",
|
|
13
|
-
"/ai/agent/{agent_id}",
|
|
14
|
-
// singular alias — behaves identically
|
|
15
|
-
"/ai/conversations/{conversation_id}",
|
|
16
|
-
"/ai/conversation/{conversation_id}",
|
|
17
|
-
// singular alias
|
|
18
|
-
"/ai/prompts/{prompt_id}",
|
|
19
|
-
// saved-prompt execution
|
|
20
|
-
"/ai/mandates/{mandate_key}"
|
|
21
|
-
// THE MANDATE DOOR — `/v2` sibling exists (routers/v2.py)
|
|
22
|
-
];
|
|
23
|
-
function toV2Path(path) {
|
|
24
|
-
const withLead = path.startsWith("/") ? path : `/${path}`;
|
|
25
|
-
if (withLead.startsWith("/api/")) {
|
|
26
|
-
const rest = withLead.slice("/api".length);
|
|
27
|
-
return rest.startsWith("/v2/") ? withLead : `/api/v2${rest}`;
|
|
28
|
-
}
|
|
29
|
-
return withLead.startsWith("/v2/") ? withLead : `/v2${withLead}`;
|
|
30
|
-
}
|
|
31
|
-
var COVERED_INTERPOLATED_PATH = [
|
|
32
|
-
/^(?:\/api)?\/ai\/manual$/,
|
|
33
|
-
/^(?:\/api)?\/ai\/chat$/,
|
|
34
|
-
/^(?:\/api)?\/ai\/agents\/[^/]+$/,
|
|
35
|
-
/^(?:\/api)?\/ai\/agent\/[^/]+$/,
|
|
36
|
-
/^(?:\/api)?\/ai\/conversations\/[^/]+$/,
|
|
37
|
-
/^(?:\/api)?\/ai\/conversation\/[^/]+$/,
|
|
38
|
-
/^(?:\/api)?\/ai\/prompts\/[^/]+$/,
|
|
39
|
-
// `/warm` etc. deliberately don't match
|
|
40
|
-
/^(?:\/api)?\/ai\/mandates\/[^/]+$/
|
|
41
|
-
// the mandate door
|
|
42
|
-
];
|
|
43
|
-
function isCoveredAiPath(path) {
|
|
44
|
-
return COVERED_INTERPOLATED_PATH.some((re) => re.test(path));
|
|
45
|
-
}
|
|
46
|
-
function isV2Path(pathOrUrl) {
|
|
47
|
-
return /\/v2\/ai\//.test(pathOrUrl);
|
|
48
|
-
}
|
|
49
|
-
function toV1FallbackUrl(url) {
|
|
50
|
-
return url.replace(/\/v2\/ai\//, "/ai/");
|
|
51
|
-
}
|
|
52
|
-
function applyAiApiVersion(path, version) {
|
|
53
|
-
if (version !== "v2") return path;
|
|
54
|
-
return isCoveredAiPath(path) ? toV2Path(path) : path;
|
|
55
|
-
}
|
|
56
|
-
async function fetchWithMatrxProtocolFallback(url, init, opts = {}) {
|
|
57
|
-
const { onDowngrade, ...fetchOpts } = opts;
|
|
58
|
-
const logDowngrade = (reason, status2) => {
|
|
59
|
-
console.warn(
|
|
60
|
-
`[matrx] ai_v2_downgrade \u2192 retrying on v1. v2=${url} reason=${reason}`
|
|
61
|
-
);
|
|
62
|
-
onDowngrade?.({ url, reason, ...status2 !== void 0 ? { status: status2 } : {} });
|
|
63
|
-
};
|
|
64
|
-
if (!isV2Path(url)) return chunkPKYPPATQ_cjs.resilientFetch(url, init, fetchOpts);
|
|
65
|
-
let result;
|
|
66
|
-
try {
|
|
67
|
-
result = await chunkPKYPPATQ_cjs.resilientFetch(url, init, fetchOpts);
|
|
68
|
-
} catch (err) {
|
|
69
|
-
const isAbort = chunkPKYPPATQ_cjs.isNetError(err) && err.code === "aborted" || err instanceof Error && err.name === "AbortError";
|
|
70
|
-
if (isAbort) throw err;
|
|
71
|
-
logDowngrade(String(err));
|
|
72
|
-
return chunkPKYPPATQ_cjs.resilientFetch(toV1FallbackUrl(url), init, fetchOpts);
|
|
73
|
-
}
|
|
74
|
-
const status = result.response.status;
|
|
75
|
-
if (status === 404 || status === 405 || status >= 500) {
|
|
76
|
-
logDowngrade(`HTTP ${status}`, status);
|
|
77
|
-
return chunkPKYPPATQ_cjs.resilientFetch(toV1FallbackUrl(url), init, fetchOpts);
|
|
78
|
-
}
|
|
79
|
-
return result;
|
|
80
|
-
}
|
|
81
|
-
function aiVersionPathOverrides(version) {
|
|
82
|
-
if (version !== "v2") return {};
|
|
83
|
-
const map = {};
|
|
84
|
-
for (const template of V2_COVERED_AI_PATH_TEMPLATES) {
|
|
85
|
-
map[template] = toV2Path(template);
|
|
86
|
-
}
|
|
87
|
-
return map;
|
|
88
|
-
}
|
|
89
|
-
|
|
90
7
|
// src/core/backend-errors.ts
|
|
91
8
|
var BackendApiError = class extends Error {
|
|
92
9
|
/** Machine-readable error code */
|
|
@@ -820,7 +737,7 @@ async function* readMatrxSseStream(stream, options = {}) {
|
|
|
820
737
|
}
|
|
821
738
|
|
|
822
739
|
// src/deployments.generated.ts
|
|
823
|
-
var CONTRACT_SHA256 = "
|
|
740
|
+
var CONTRACT_SHA256 = "605c060bacf38697b876c603bf0260b9b2941fe22b1da1722810724c3d0c39be";
|
|
824
741
|
var DEPLOYMENTS = {
|
|
825
742
|
"files": {
|
|
826
743
|
"app": "files-standalone",
|
|
@@ -1017,7 +934,7 @@ function sendWithXhr(url, init, signal, totalTimeoutMs, onUploadProgress) {
|
|
|
1017
934
|
};
|
|
1018
935
|
xhr.ontimeout = () => {
|
|
1019
936
|
cleanup();
|
|
1020
|
-
reject(new
|
|
937
|
+
reject(new chunk2SXAAKGV_cjs.TotalTimeoutError(totalTimeoutMs ?? 0));
|
|
1021
938
|
};
|
|
1022
939
|
xhr.onabort = () => {
|
|
1023
940
|
cleanup();
|
|
@@ -1037,7 +954,7 @@ async function sendOnWire(request, auth = {}) {
|
|
|
1037
954
|
await waitForSessionReady(auth.credentials, auth.readyTimeoutMs);
|
|
1038
955
|
const credentialHeaders = auth.credentials ? credentials.credentialToHeaders(await auth.credentials.get()) : {};
|
|
1039
956
|
const attempt = (sendHeaders) => {
|
|
1040
|
-
if (request.signal?.aborted) return Promise.reject(new
|
|
957
|
+
if (request.signal?.aborted) return Promise.reject(new chunk2SXAAKGV_cjs.AbortedError(request.signal.reason));
|
|
1041
958
|
const merged = { ...sendHeaders };
|
|
1042
959
|
if (request.onUploadProgress && body !== void 0) {
|
|
1043
960
|
if (typeof XMLHttpRequest !== "undefined" && !(typeof ReadableStream !== "undefined" && body instanceof ReadableStream)) {
|
|
@@ -1051,15 +968,14 @@ async function sendOnWire(request, auth = {}) {
|
|
|
1051
968
|
);
|
|
1052
969
|
}
|
|
1053
970
|
}
|
|
1054
|
-
return
|
|
971
|
+
return chunk2SXAAKGV_cjs.resilientFetch(
|
|
1055
972
|
request.url,
|
|
1056
973
|
{ ...request.fetchOptions, method, headers: merged, ...body !== void 0 ? { body } : {} },
|
|
1057
974
|
{
|
|
1058
975
|
...request.signal ? { signal: request.signal } : {},
|
|
1059
976
|
connectTimeoutMs: request.connectTimeoutMs ?? DEFAULT_CONNECT_TIMEOUT_MS,
|
|
1060
977
|
totalTimeoutMs: request.totalTimeoutMs !== void 0 ? request.totalTimeoutMs : null,
|
|
1061
|
-
throwOnHttpError: false
|
|
1062
|
-
...request.onProtocolDowngrade ? { onDowngrade: request.onProtocolDowngrade } : {}
|
|
978
|
+
throwOnHttpError: false
|
|
1063
979
|
}
|
|
1064
980
|
).then((result) => {
|
|
1065
981
|
if (request.onUploadProgress && body !== void 0) {
|
|
@@ -1075,9 +991,9 @@ async function sendOnWire(request, auth = {}) {
|
|
|
1075
991
|
const firstHeaders = mergeHeaders(headers, credentialHeaders, over);
|
|
1076
992
|
const idempotent = method === "GET" || method === "HEAD";
|
|
1077
993
|
const attempts = Math.max(1, request.retryAttempts ?? 1);
|
|
1078
|
-
const first = idempotent && attempts > 1 && !request.stream ? await
|
|
994
|
+
const first = idempotent && attempts > 1 && !request.stream ? await chunk2SXAAKGV_cjs.withRetry(() => attempt(firstHeaders), {
|
|
1079
995
|
attempts,
|
|
1080
|
-
retryOn:
|
|
996
|
+
retryOn: chunk2SXAAKGV_cjs.isTransportFailure,
|
|
1081
997
|
...request.signal ? { signal: request.signal } : {}
|
|
1082
998
|
}) : await attempt(firstHeaders);
|
|
1083
999
|
if (first.response.status !== 401 || !auth.refreshCredentials) return first;
|
|
@@ -1285,14 +1201,10 @@ exports.CONTRACT_SHA256 = CONTRACT_SHA256;
|
|
|
1285
1201
|
exports.DEFAULT_MATRX_NDJSON_READ_AHEAD = DEFAULT_MATRX_NDJSON_READ_AHEAD;
|
|
1286
1202
|
exports.DEPLOYMENTS = DEPLOYMENTS;
|
|
1287
1203
|
exports.DOMAINS = DOMAINS;
|
|
1288
|
-
exports.MATRX_AI_API_VERSION_DEFAULT = MATRX_AI_API_VERSION_DEFAULT;
|
|
1289
1204
|
exports.MatrxApiError = MatrxApiError;
|
|
1290
1205
|
exports.OrganizationContextError = OrganizationContextError;
|
|
1291
1206
|
exports.StreamTransportError = StreamTransportError;
|
|
1292
|
-
exports.V2_COVERED_AI_PATH_TEMPLATES = V2_COVERED_AI_PATH_TEMPLATES;
|
|
1293
1207
|
exports.WIRE_FETCH_OPTION_KEYS = WIRE_FETCH_OPTION_KEYS;
|
|
1294
|
-
exports.aiVersionPathOverrides = aiVersionPathOverrides;
|
|
1295
|
-
exports.applyAiApiVersion = applyAiApiVersion;
|
|
1296
1208
|
exports.applyOrganizationContextHeader = applyOrganizationContextHeader;
|
|
1297
1209
|
exports.assertOrganizationMatchesOperation = assertOrganizationMatchesOperation;
|
|
1298
1210
|
exports.assertQueryOrganizationMatchesContext = assertQueryOrganizationMatchesContext;
|
|
@@ -1303,13 +1215,10 @@ exports.createOrganizationOperation = createOrganizationOperation;
|
|
|
1303
1215
|
exports.describeBackendFailure = describeBackendFailure;
|
|
1304
1216
|
exports.extractMatrxErrorCode = extractMatrxErrorCode;
|
|
1305
1217
|
exports.extractMatrxErrorMessage = extractMatrxErrorMessage;
|
|
1306
|
-
exports.fetchWithMatrxProtocolFallback = fetchWithMatrxProtocolFallback;
|
|
1307
1218
|
exports.getUserMessage = getUserMessage;
|
|
1308
1219
|
exports.isBinaryType = isBinaryType;
|
|
1309
|
-
exports.isCoveredAiPath = isCoveredAiPath;
|
|
1310
1220
|
exports.isGenericUserMessage = isGenericUserMessage;
|
|
1311
1221
|
exports.isStreamTransportLost = isStreamTransportLost;
|
|
1312
|
-
exports.isV2Path = isV2Path;
|
|
1313
1222
|
exports.normalizeMatrxStreamEnvelope = normalizeMatrxStreamEnvelope;
|
|
1314
1223
|
exports.openJsonOrStream = openJsonOrStream;
|
|
1315
1224
|
exports.openStream = openStream;
|
|
@@ -1323,6 +1232,4 @@ exports.readMatrxNdjsonStream = readMatrxNdjsonStream;
|
|
|
1323
1232
|
exports.readMatrxSseStream = readMatrxSseStream;
|
|
1324
1233
|
exports.requireOrganizationContext = requireOrganizationContext;
|
|
1325
1234
|
exports.sendOnWire = sendOnWire;
|
|
1326
|
-
exports.toV1FallbackUrl = toV1FallbackUrl;
|
|
1327
|
-
exports.toV2Path = toV2Path;
|
|
1328
1235
|
exports.unwrapUpstreamError = unwrapUpstreamError;
|
|
@@ -141,58 +141,6 @@ function toNetError(err) {
|
|
|
141
141
|
);
|
|
142
142
|
}
|
|
143
143
|
|
|
144
|
-
// src/net/retry.ts
|
|
145
|
-
function defaultRetryOn(err) {
|
|
146
|
-
return isNetError(err) && err.retryable;
|
|
147
|
-
}
|
|
148
|
-
function sleep(ms, signal) {
|
|
149
|
-
return new Promise((resolve, reject) => {
|
|
150
|
-
const timer = setTimeout(() => {
|
|
151
|
-
resolve();
|
|
152
|
-
if (signal) signal.removeEventListener("abort", onAbort);
|
|
153
|
-
}, ms);
|
|
154
|
-
const onAbort = () => {
|
|
155
|
-
clearTimeout(timer);
|
|
156
|
-
reject(signal?.reason ?? new Error("Aborted"));
|
|
157
|
-
};
|
|
158
|
-
if (signal) {
|
|
159
|
-
if (signal.aborted) {
|
|
160
|
-
clearTimeout(timer);
|
|
161
|
-
reject(signal.reason);
|
|
162
|
-
} else {
|
|
163
|
-
signal.addEventListener("abort", onAbort, { once: true });
|
|
164
|
-
}
|
|
165
|
-
}
|
|
166
|
-
});
|
|
167
|
-
}
|
|
168
|
-
async function withRetry(fn, opts = {}) {
|
|
169
|
-
const attempts = Math.max(1, opts.attempts ?? 3);
|
|
170
|
-
const initialDelayMs = opts.initialDelayMs ?? 250;
|
|
171
|
-
const maxDelayMs = opts.maxDelayMs ?? 4e3;
|
|
172
|
-
const factor = opts.backoffFactor ?? 2;
|
|
173
|
-
const jitter = Math.max(0, Math.min(1, opts.jitter ?? 0.25));
|
|
174
|
-
const retryOn = opts.retryOn ?? defaultRetryOn;
|
|
175
|
-
let lastErr;
|
|
176
|
-
for (let attempt = 1; attempt <= attempts; attempt++) {
|
|
177
|
-
if (opts.signal?.aborted) throw opts.signal.reason;
|
|
178
|
-
try {
|
|
179
|
-
return await fn(attempt);
|
|
180
|
-
} catch (err) {
|
|
181
|
-
lastErr = err;
|
|
182
|
-
if (attempt === attempts || !retryOn(err)) throw err;
|
|
183
|
-
const base = Math.min(
|
|
184
|
-
maxDelayMs,
|
|
185
|
-
initialDelayMs * Math.pow(factor, attempt - 1)
|
|
186
|
-
);
|
|
187
|
-
const jitterAmount = base * jitter * (Math.random() * 2 - 1);
|
|
188
|
-
const delayMs = Math.max(0, Math.round(base + jitterAmount));
|
|
189
|
-
opts.onRetry?.(attempt, err, delayMs);
|
|
190
|
-
await sleep(delayMs, opts.signal);
|
|
191
|
-
}
|
|
192
|
-
}
|
|
193
|
-
throw lastErr;
|
|
194
|
-
}
|
|
195
|
-
|
|
196
144
|
// src/net/resilient-fetch.ts
|
|
197
145
|
var DEFAULTS = {
|
|
198
146
|
connectTimeoutMs: 15e3,
|
|
@@ -261,58 +209,56 @@ async function resilientFetch(url, init = {}, opts = {}) {
|
|
|
261
209
|
}
|
|
262
210
|
}
|
|
263
211
|
|
|
264
|
-
// src/net/
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
if (
|
|
279
|
-
|
|
280
|
-
|
|
212
|
+
// src/net/retry.ts
|
|
213
|
+
function defaultRetryOn(err) {
|
|
214
|
+
return isNetError(err) && err.retryable;
|
|
215
|
+
}
|
|
216
|
+
function sleep(ms, signal) {
|
|
217
|
+
return new Promise((resolve, reject) => {
|
|
218
|
+
const timer = setTimeout(() => {
|
|
219
|
+
resolve();
|
|
220
|
+
if (signal) signal.removeEventListener("abort", onAbort);
|
|
221
|
+
}, ms);
|
|
222
|
+
const onAbort = () => {
|
|
223
|
+
clearTimeout(timer);
|
|
224
|
+
reject(signal?.reason ?? new Error("Aborted"));
|
|
225
|
+
};
|
|
226
|
+
if (signal) {
|
|
227
|
+
if (signal.aborted) {
|
|
228
|
+
clearTimeout(timer);
|
|
229
|
+
reject(signal.reason);
|
|
230
|
+
} else {
|
|
231
|
+
signal.addEventListener("abort", onAbort, { once: true });
|
|
232
|
+
}
|
|
281
233
|
}
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
}, deadline);
|
|
295
|
-
});
|
|
296
|
-
let result;
|
|
234
|
+
});
|
|
235
|
+
}
|
|
236
|
+
async function withRetry(fn, opts = {}) {
|
|
237
|
+
const attempts = Math.max(1, opts.attempts ?? 3);
|
|
238
|
+
const initialDelayMs = opts.initialDelayMs ?? 250;
|
|
239
|
+
const maxDelayMs = opts.maxDelayMs ?? 4e3;
|
|
240
|
+
const factor = opts.backoffFactor ?? 2;
|
|
241
|
+
const jitter = Math.max(0, Math.min(1, opts.jitter ?? 0.25));
|
|
242
|
+
const retryOn = opts.retryOn ?? defaultRetryOn;
|
|
243
|
+
let lastErr;
|
|
244
|
+
for (let attempt = 1; attempt <= attempts; attempt++) {
|
|
245
|
+
if (opts.signal?.aborted) throw opts.signal.reason;
|
|
297
246
|
try {
|
|
298
|
-
|
|
247
|
+
return await fn(attempt);
|
|
299
248
|
} catch (err) {
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
249
|
+
lastErr = err;
|
|
250
|
+
if (attempt === attempts || !retryOn(err)) throw err;
|
|
251
|
+
const base = Math.min(
|
|
252
|
+
maxDelayMs,
|
|
253
|
+
initialDelayMs * Math.pow(factor, attempt - 1)
|
|
254
|
+
);
|
|
255
|
+
const jitterAmount = base * jitter * (Math.random() * 2 - 1);
|
|
256
|
+
const delayMs = Math.max(0, Math.round(base + jitterAmount));
|
|
257
|
+
opts.onRetry?.(attempt, err, delayMs);
|
|
258
|
+
await sleep(delayMs, opts.signal);
|
|
310
259
|
}
|
|
311
|
-
if (timer !== null) clearTimeout(timer);
|
|
312
|
-
if (result.done) return;
|
|
313
|
-
opts.onHeartbeat?.(Date.now());
|
|
314
|
-
yield result.value;
|
|
315
260
|
}
|
|
261
|
+
throw lastErr;
|
|
316
262
|
}
|
|
317
263
|
|
|
318
|
-
export { AbortedError, ConnectTimeoutError, HeartbeatTimeoutError, HttpError, NetError, NetworkError, OfflineError, TotalTimeoutError, extractErrorMessage, isNetError, isTransportFailure,
|
|
264
|
+
export { AbortedError, ConnectTimeoutError, HeartbeatTimeoutError, HttpError, NetError, NetworkError, OfflineError, TotalTimeoutError, extractErrorMessage, isNetError, isTransportFailure, resilientFetch, toNetError, withRetry };
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { TotalTimeoutError, HeartbeatTimeoutError } from './chunk-KIEAFMKB.js';
|
|
2
|
+
|
|
3
|
+
// src/net/stream-monitor.ts
|
|
4
|
+
var DEFAULTS = {
|
|
5
|
+
heartbeatTimeoutMs: 3e4,
|
|
6
|
+
maxLifetimeMs: 6e5
|
|
7
|
+
};
|
|
8
|
+
async function* monitorStream(source, opts = {}) {
|
|
9
|
+
const heartbeatTimeoutMs = opts.heartbeatTimeoutMs ?? DEFAULTS.heartbeatTimeoutMs;
|
|
10
|
+
const maxLifetimeMs = opts.maxLifetimeMs ?? DEFAULTS.maxLifetimeMs;
|
|
11
|
+
const abort = opts.abortController;
|
|
12
|
+
const startedAt = Date.now();
|
|
13
|
+
const iter = source[Symbol.asyncIterator]();
|
|
14
|
+
while (true) {
|
|
15
|
+
const elapsed = Date.now() - startedAt;
|
|
16
|
+
const remainingLifetime = maxLifetimeMs - elapsed;
|
|
17
|
+
if (remainingLifetime <= 0) {
|
|
18
|
+
abort?.abort("total-timeout");
|
|
19
|
+
throw new TotalTimeoutError(maxLifetimeMs);
|
|
20
|
+
}
|
|
21
|
+
const deadline = Math.min(heartbeatTimeoutMs, remainingLifetime);
|
|
22
|
+
let timer = null;
|
|
23
|
+
let timedOutKind = null;
|
|
24
|
+
const timeoutPromise = new Promise((_, reject) => {
|
|
25
|
+
timer = setTimeout(() => {
|
|
26
|
+
timedOutKind = deadline === remainingLifetime ? "total" : "heartbeat";
|
|
27
|
+
abort?.abort(
|
|
28
|
+
timedOutKind === "total" ? "total-timeout" : "heartbeat-timeout"
|
|
29
|
+
);
|
|
30
|
+
reject(
|
|
31
|
+
timedOutKind === "total" ? new TotalTimeoutError(maxLifetimeMs) : new HeartbeatTimeoutError(heartbeatTimeoutMs)
|
|
32
|
+
);
|
|
33
|
+
}, deadline);
|
|
34
|
+
});
|
|
35
|
+
let result;
|
|
36
|
+
try {
|
|
37
|
+
result = await Promise.race([iter.next(), timeoutPromise]);
|
|
38
|
+
} catch (err) {
|
|
39
|
+
if (timer !== null) clearTimeout(timer);
|
|
40
|
+
try {
|
|
41
|
+
const cleanup = iter.return?.(void 0);
|
|
42
|
+
if (cleanup) {
|
|
43
|
+
void Promise.resolve(cleanup).catch(() => {
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
} catch {
|
|
47
|
+
}
|
|
48
|
+
throw err;
|
|
49
|
+
}
|
|
50
|
+
if (timer !== null) clearTimeout(timer);
|
|
51
|
+
if (result.done) return;
|
|
52
|
+
opts.onHeartbeat?.(Date.now());
|
|
53
|
+
yield result.value;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export { monitorStream };
|
package/dist/code.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('./chunk-
|
|
3
|
+
var chunkFSXBRXRX_cjs = require('./chunk-FSXBRXRX.cjs');
|
|
4
|
+
require('./chunk-2SXAAKGV.cjs');
|
|
5
5
|
|
|
6
6
|
// src/generated/code.ts
|
|
7
7
|
var $codingSessionBridge = { m: "POST", p: "/coding-sessions/bridge", d: "aidream", a: "user", o: "exempt", n: "code.coding_session_bridge" };
|
|
@@ -46,7 +46,7 @@ function claudeManagedCapabilities(api, args, options) {
|
|
|
46
46
|
}
|
|
47
47
|
var $claudeManagedStream = { m: "POST", p: "/coding-sessions/claude/stream", d: "aidream", a: "user", o: "required", s: "ndjson", n: "code.claude_managed_stream" };
|
|
48
48
|
function claudeManagedStream(api, args, options) {
|
|
49
|
-
return
|
|
49
|
+
return chunkFSXBRXRX_cjs.openStream(api, $claudeManagedStream, args, options);
|
|
50
50
|
}
|
|
51
51
|
var $cancelClaudeManagedRuntime = { m: "POST", p: "/coding-sessions/claude/runtimes/{runtime_id}/cancel", d: "aidream", a: "user", o: "required", n: "code.cancel_claude_managed_runtime" };
|
|
52
52
|
function cancelClaudeManagedRuntime(api, args, options) {
|
|
@@ -58,7 +58,7 @@ function codexManagedCapabilities(api, args, options) {
|
|
|
58
58
|
}
|
|
59
59
|
var $codexManagedStream = { m: "POST", p: "/coding-sessions/codex/stream", d: "aidream", a: "user", o: "required", s: "ndjson", n: "code.codex_managed_stream" };
|
|
60
60
|
function codexManagedStream(api, args, options) {
|
|
61
|
-
return
|
|
61
|
+
return chunkFSXBRXRX_cjs.openStream(api, $codexManagedStream, args, options);
|
|
62
62
|
}
|
|
63
63
|
var $cancelCodexManagedRuntime = { m: "POST", p: "/coding-sessions/codex/runtimes/{runtime_id}/cancel", d: "aidream", a: "user", o: "required", n: "code.cancel_codex_managed_runtime" };
|
|
64
64
|
function cancelCodexManagedRuntime(api, args, options) {
|
|
@@ -138,7 +138,7 @@ function claudeManagedCapabilitiesOnHostedBox(api, args, options) {
|
|
|
138
138
|
}
|
|
139
139
|
var $claudeManagedStreamOnHostedBox = { m: "POST", p: "/coding-sessions/claude/stream", d: "hosted-box", a: "user", o: "required", s: "ndjson", n: "code.claude_managed_stream" };
|
|
140
140
|
function claudeManagedStreamOnHostedBox(api, args, options) {
|
|
141
|
-
return
|
|
141
|
+
return chunkFSXBRXRX_cjs.openStream(api, $claudeManagedStreamOnHostedBox, args, options);
|
|
142
142
|
}
|
|
143
143
|
var $cancelClaudeManagedRuntimeOnHostedBox = { m: "POST", p: "/coding-sessions/claude/runtimes/{runtime_id}/cancel", d: "hosted-box", a: "user", o: "required", n: "code.cancel_claude_managed_runtime" };
|
|
144
144
|
function cancelClaudeManagedRuntimeOnHostedBox(api, args, options) {
|
|
@@ -150,7 +150,7 @@ function codexManagedCapabilitiesOnHostedBox(api, args, options) {
|
|
|
150
150
|
}
|
|
151
151
|
var $codexManagedStreamOnHostedBox = { m: "POST", p: "/coding-sessions/codex/stream", d: "hosted-box", a: "user", o: "required", s: "ndjson", n: "code.codex_managed_stream" };
|
|
152
152
|
function codexManagedStreamOnHostedBox(api, args, options) {
|
|
153
|
-
return
|
|
153
|
+
return chunkFSXBRXRX_cjs.openStream(api, $codexManagedStreamOnHostedBox, args, options);
|
|
154
154
|
}
|
|
155
155
|
var $cancelCodexManagedRuntimeOnHostedBox = { m: "POST", p: "/coding-sessions/codex/runtimes/{runtime_id}/cancel", d: "hosted-box", a: "user", o: "required", n: "code.cancel_codex_managed_runtime" };
|
|
156
156
|
function cancelCodexManagedRuntimeOnHostedBox(api, args, options) {
|
|
@@ -378,7 +378,7 @@ function runtimeResumable(api, args, options) {
|
|
|
378
378
|
}
|
|
379
379
|
var $runtimeEvents = { m: "GET", p: "/coding-session/runtime/{runtime_id}/events", d: "matrx-local", a: "loopback_token", o: "exempt", s: "sse", n: "code.runtime_events" };
|
|
380
380
|
function runtimeEvents(api, args, options) {
|
|
381
|
-
return
|
|
381
|
+
return chunkFSXBRXRX_cjs.openStream(api, $runtimeEvents, args, options);
|
|
382
382
|
}
|
|
383
383
|
var $getCodexUsageAllowance = { m: "GET", p: "/codex-usage/allowance", d: "matrx-local", a: "loopback_token", o: "exempt", n: "code.get_codex_usage_allowance" };
|
|
384
384
|
function getCodexUsageAllowance(api, args, options) {
|
package/dist/code.d.cts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { A as Api, C as CallOptions, a as ApiStream, N as NdjsonEvent, S as SseEvent } from './index-
|
|
1
|
+
import { A as Api, C as CallOptions, a as ApiStream, N as NdjsonEvent, S as SseEvent } from './index-oZNMwcTG.cjs';
|
|
2
2
|
import { JsonValue } from './schemas.cjs';
|
|
3
3
|
import '@ai-matrx/auth/credentials';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* GENERATED by @ai-matrx/api scripts/generate.mjs from aidream/api-contract — never edit by hand.
|
|
7
|
-
* CONTRACT_SHA256
|
|
7
|
+
* CONTRACT_SHA256 605c060bacf38697b876c603bf0260b9b2941fe22b1da1722810724c3d0c39be
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/** Opaque, display-safe provider-account provenance. Never authorization. */
|
package/dist/code.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { A as Api, C as CallOptions, a as ApiStream, N as NdjsonEvent, S as SseEvent } from './index-
|
|
1
|
+
import { A as Api, C as CallOptions, a as ApiStream, N as NdjsonEvent, S as SseEvent } from './index-oZNMwcTG.js';
|
|
2
2
|
import { JsonValue } from './schemas.js';
|
|
3
3
|
import '@ai-matrx/auth/credentials';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* GENERATED by @ai-matrx/api scripts/generate.mjs from aidream/api-contract — never edit by hand.
|
|
7
|
-
* CONTRACT_SHA256
|
|
7
|
+
* CONTRACT_SHA256 605c060bacf38697b876c603bf0260b9b2941fe22b1da1722810724c3d0c39be
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/** Opaque, display-safe provider-account provenance. Never authorization. */
|
package/dist/code.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { openStream } from './chunk-
|
|
2
|
-
import './chunk-
|
|
1
|
+
import { openStream } from './chunk-3M4Y376I.js';
|
|
2
|
+
import './chunk-KIEAFMKB.js';
|
|
3
3
|
|
|
4
4
|
// src/generated/code.ts
|
|
5
5
|
var $codingSessionBridge = { m: "POST", p: "/coding-sessions/bridge", d: "aidream", a: "user", o: "exempt", n: "code.coding_session_bridge" };
|
package/dist/commerce.d.cts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { A as Api, C as CallOptions } from './index-
|
|
1
|
+
import { A as Api, C as CallOptions } from './index-oZNMwcTG.cjs';
|
|
2
2
|
import '@ai-matrx/auth/credentials';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* GENERATED by @ai-matrx/api scripts/generate.mjs from aidream/api-contract — never edit by hand.
|
|
6
|
-
* CONTRACT_SHA256
|
|
6
|
+
* CONTRACT_SHA256 605c060bacf38697b876c603bf0260b9b2941fe22b1da1722810724c3d0c39be
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
/** EbayOAuthConnectResponse */
|
package/dist/commerce.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { A as Api, C as CallOptions } from './index-
|
|
1
|
+
import { A as Api, C as CallOptions } from './index-oZNMwcTG.js';
|
|
2
2
|
import '@ai-matrx/auth/credentials';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* GENERATED by @ai-matrx/api scripts/generate.mjs from aidream/api-contract — never edit by hand.
|
|
6
|
-
* CONTRACT_SHA256
|
|
6
|
+
* CONTRACT_SHA256 605c060bacf38697b876c603bf0260b9b2941fe22b1da1722810724c3d0c39be
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
/** EbayOAuthConnectResponse */
|
package/dist/communications.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('./chunk-
|
|
3
|
+
var chunkFSXBRXRX_cjs = require('./chunk-FSXBRXRX.cjs');
|
|
4
|
+
require('./chunk-2SXAAKGV.cjs');
|
|
5
5
|
|
|
6
6
|
// src/generated/communications.ts
|
|
7
7
|
var $conversationRelayPreparation = { m: "POST", p: "/communications/voice/conversation-relay/session-reference", d: "aidream", a: "scoped", o: "required", n: "communications.conversation_relay_preparation" };
|
|
@@ -102,7 +102,7 @@ function agentStop(api, args, options) {
|
|
|
102
102
|
}
|
|
103
103
|
var $intelligenceAsk = { m: "POST", p: "/v1/meet/intelligence/ask", d: "aidream", a: "scoped", o: "required", s: "ndjson", n: "communications.intelligence_ask" };
|
|
104
104
|
function intelligenceAsk(api, args, options) {
|
|
105
|
-
return
|
|
105
|
+
return chunkFSXBRXRX_cjs.openStream(api, $intelligenceAsk, args, options);
|
|
106
106
|
}
|
|
107
107
|
var $meetingRecord = { m: "GET", p: "/v1/meet/record", d: "aidream", a: "scoped", o: "required", n: "communications.meeting_record" };
|
|
108
108
|
function meetingRecord(api, args, options) {
|
|
@@ -142,11 +142,11 @@ function meetingGoogleCalendar(api, args, options) {
|
|
|
142
142
|
}
|
|
143
143
|
var $meetingBrief = { m: "POST", p: "/v1/meet/meetings/{meeting_id}/brief", d: "aidream", a: "user", o: "required", s: "ndjson", n: "communications.meeting_brief" };
|
|
144
144
|
function meetingBrief(api, args, options) {
|
|
145
|
-
return
|
|
145
|
+
return chunkFSXBRXRX_cjs.openStream(api, $meetingBrief, args, options);
|
|
146
146
|
}
|
|
147
147
|
var $agendaDraft = { m: "POST", p: "/v1/meet/agenda-draft", d: "aidream", a: "user", o: "required", s: "ndjson", n: "communications.agenda_draft" };
|
|
148
148
|
function agendaDraft(api, args, options) {
|
|
149
|
-
return
|
|
149
|
+
return chunkFSXBRXRX_cjs.openStream(api, $agendaDraft, args, options);
|
|
150
150
|
}
|
|
151
151
|
var $meetingModerate = { m: "POST", p: "/v1/meet/moderate", d: "aidream", a: "scoped", o: "required", n: "communications.meeting_moderate" };
|
|
152
152
|
function meetingModerate(api, args, options) {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { A as Api, C as CallOptions, a as ApiStream, N as NdjsonEvent } from './index-
|
|
1
|
+
import { A as Api, C as CallOptions, a as ApiStream, N as NdjsonEvent } from './index-oZNMwcTG.cjs';
|
|
2
2
|
import { JsonValue, CalendarCreateResult } from './schemas.cjs';
|
|
3
3
|
import '@ai-matrx/auth/credentials';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* GENERATED by @ai-matrx/api scripts/generate.mjs from aidream/api-contract — never edit by hand.
|
|
7
|
-
* CONTRACT_SHA256
|
|
7
|
+
* CONTRACT_SHA256 605c060bacf38697b876c603bf0260b9b2941fe22b1da1722810724c3d0c39be
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/** `POST /v1/meet/agenda-draft` — what the form holds right now (nothing is stored). */
|
package/dist/communications.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { A as Api, C as CallOptions, a as ApiStream, N as NdjsonEvent } from './index-
|
|
1
|
+
import { A as Api, C as CallOptions, a as ApiStream, N as NdjsonEvent } from './index-oZNMwcTG.js';
|
|
2
2
|
import { JsonValue, CalendarCreateResult } from './schemas.js';
|
|
3
3
|
import '@ai-matrx/auth/credentials';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* GENERATED by @ai-matrx/api scripts/generate.mjs from aidream/api-contract — never edit by hand.
|
|
7
|
-
* CONTRACT_SHA256
|
|
7
|
+
* CONTRACT_SHA256 605c060bacf38697b876c603bf0260b9b2941fe22b1da1722810724c3d0c39be
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/** `POST /v1/meet/agenda-draft` — what the form holds right now (nothing is stored). */
|
package/dist/communications.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { openStream } from './chunk-
|
|
2
|
-
import './chunk-
|
|
1
|
+
import { openStream } from './chunk-3M4Y376I.js';
|
|
2
|
+
import './chunk-KIEAFMKB.js';
|
|
3
3
|
|
|
4
4
|
// src/generated/communications.ts
|
|
5
5
|
var $conversationRelayPreparation = { m: "POST", p: "/communications/voice/conversation-relay/session-reference", d: "aidream", a: "scoped", o: "required", n: "communications.conversation_relay_preparation" };
|
package/dist/computer.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('./chunk-
|
|
3
|
+
var chunkFSXBRXRX_cjs = require('./chunk-FSXBRXRX.cjs');
|
|
4
|
+
require('./chunk-2SXAAKGV.cjs');
|
|
5
5
|
|
|
6
6
|
// src/generated/computer.ts
|
|
7
7
|
var $localProxyProxyToLocalPc = { m: "GET", p: "/local-proxy/{app_instance_id}/{path}", d: "aidream", a: "guest", o: "required", n: "computer.local_proxy_proxy_to_local_pc" };
|
|
@@ -50,11 +50,11 @@ function getAccessLogs(api, args, options) {
|
|
|
50
50
|
}
|
|
51
51
|
var $streamSystemLog = { m: "GET", p: "/logs/stream", d: "matrx-local", a: "loopback_token", o: "exempt", s: "sse", n: "computer.stream_system_log" };
|
|
52
52
|
function streamSystemLog(api, args, options) {
|
|
53
|
-
return
|
|
53
|
+
return chunkFSXBRXRX_cjs.openStream(api, $streamSystemLog, args, options);
|
|
54
54
|
}
|
|
55
55
|
var $streamAccessLog = { m: "GET", p: "/logs/access/stream", d: "matrx-local", a: "loopback_token", o: "exempt", s: "sse", n: "computer.stream_access_log" };
|
|
56
56
|
function streamAccessLog(api, args, options) {
|
|
57
|
-
return
|
|
57
|
+
return chunkFSXBRXRX_cjs.openStream(api, $streamAccessLog, args, options);
|
|
58
58
|
}
|
|
59
59
|
var $pushNotification = { m: "POST", p: "/notify", d: "matrx-local", a: "loopback_token", o: "exempt", n: "computer.push_notification" };
|
|
60
60
|
function pushNotification(api, args, options) {
|
|
@@ -90,7 +90,7 @@ function messages(api, args, options) {
|
|
|
90
90
|
}
|
|
91
91
|
var $events = { m: "GET", p: "/personal-messaging/beeper/events", d: "matrx-local", a: "loopback_token", o: "exempt", s: "ndjson", n: "computer.events" };
|
|
92
92
|
function events(api, args, options) {
|
|
93
|
-
return
|
|
93
|
+
return chunkFSXBRXRX_cjs.openStream(api, $events, args, options);
|
|
94
94
|
}
|
|
95
95
|
var $message = { m: "GET", p: "/personal-messaging/beeper/message", d: "matrx-local", a: "loopback_token", o: "exempt", n: "computer.message" };
|
|
96
96
|
function message(api, args, options) {
|
package/dist/computer.d.cts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { A as Api, C as CallOptions, a as ApiStream, N as NdjsonEvent, S as SseEvent } from './index-
|
|
1
|
+
import { A as Api, C as CallOptions, a as ApiStream, N as NdjsonEvent, S as SseEvent } from './index-oZNMwcTG.cjs';
|
|
2
2
|
import { TextPart } from './schemas.cjs';
|
|
3
3
|
import '@ai-matrx/auth/credentials';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* GENERATED by @ai-matrx/api scripts/generate.mjs from aidream/api-contract — never edit by hand.
|
|
7
|
-
* CONTRACT_SHA256
|
|
7
|
+
* CONTRACT_SHA256 605c060bacf38697b876c603bf0260b9b2941fe22b1da1722810724c3d0c39be
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
/** AccessLogsResponse */
|