@arbidocs/sdk 0.3.138 → 0.3.140
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/{browser-DSk5KK4x.d.cts → browser-B9JRGjYZ.d.cts} +119 -136
- package/dist/{browser-DSk5KK4x.d.ts → browser-B9JRGjYZ.d.ts} +119 -136
- package/dist/browser.cjs +32 -34
- package/dist/browser.cjs.map +1 -1
- package/dist/browser.d.cts +1 -1
- package/dist/browser.d.ts +1 -1
- package/dist/browser.js +32 -34
- package/dist/browser.js.map +1 -1
- package/dist/index.cjs +27 -26
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +6 -6
- package/dist/index.d.ts +6 -6
- package/dist/index.js +27 -26
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/browser.cjs
CHANGED
|
@@ -3953,6 +3953,7 @@ async function streamSSE(response, callbacks = {}) {
|
|
|
3953
3953
|
}
|
|
3954
3954
|
if (data.context) {
|
|
3955
3955
|
context = data.context;
|
|
3956
|
+
callbacks.onContextUpdate?.(data.context);
|
|
3956
3957
|
}
|
|
3957
3958
|
if (data.t != null) callbacks.onElapsedTime?.(data.t);
|
|
3958
3959
|
callbacks.onComplete?.();
|
|
@@ -5560,46 +5561,43 @@ async function runTask(arbi, taskId) {
|
|
|
5560
5561
|
);
|
|
5561
5562
|
}
|
|
5562
5563
|
|
|
5563
|
-
// src/operations/
|
|
5564
|
-
var
|
|
5565
|
-
__export(
|
|
5566
|
-
|
|
5567
|
-
|
|
5568
|
-
|
|
5569
|
-
|
|
5570
|
-
|
|
5564
|
+
// src/operations/notes.ts
|
|
5565
|
+
var notes_exports = {};
|
|
5566
|
+
__export(notes_exports, {
|
|
5567
|
+
createNote: () => createNote,
|
|
5568
|
+
deleteNote: () => deleteNote,
|
|
5569
|
+
listNotes: () => listNotes,
|
|
5570
|
+
searchNotes: () => searchNotes,
|
|
5571
|
+
updateNote: () => updateNote
|
|
5571
5572
|
});
|
|
5572
|
-
async function
|
|
5573
|
-
return requireData(await arbi.fetch.POST("/v1/
|
|
5573
|
+
async function createNote(arbi, body) {
|
|
5574
|
+
return requireData(await arbi.fetch.POST("/v1/notes/", { body }), "Failed to create note");
|
|
5574
5575
|
}
|
|
5575
|
-
async function
|
|
5576
|
+
async function listNotes(arbi, options) {
|
|
5576
5577
|
return requireData(
|
|
5577
|
-
await arbi.fetch.GET("/v1/
|
|
5578
|
+
await arbi.fetch.GET("/v1/notes/list", {
|
|
5578
5579
|
params: { query: { pinned_only: options?.pinnedOnly ?? false } }
|
|
5579
5580
|
}),
|
|
5580
|
-
"Failed to list
|
|
5581
|
+
"Failed to list notes"
|
|
5581
5582
|
);
|
|
5582
5583
|
}
|
|
5583
|
-
async function
|
|
5584
|
-
return requireData(
|
|
5585
|
-
await arbi.fetch.POST("/v1/memory/search", { body }),
|
|
5586
|
-
"Failed to search memories"
|
|
5587
|
-
);
|
|
5584
|
+
async function searchNotes(arbi, body) {
|
|
5585
|
+
return requireData(await arbi.fetch.POST("/v1/notes/search", { body }), "Failed to search notes");
|
|
5588
5586
|
}
|
|
5589
|
-
async function
|
|
5587
|
+
async function updateNote(arbi, memoryId, body) {
|
|
5590
5588
|
return requireData(
|
|
5591
|
-
await arbi.fetch.PATCH("/v1/
|
|
5592
|
-
params: { path: {
|
|
5589
|
+
await arbi.fetch.PATCH("/v1/notes/{note_ext_id}", {
|
|
5590
|
+
params: { path: { note_ext_id: memoryId } },
|
|
5593
5591
|
body
|
|
5594
5592
|
}),
|
|
5595
|
-
"Failed to update
|
|
5593
|
+
"Failed to update note"
|
|
5596
5594
|
);
|
|
5597
5595
|
}
|
|
5598
|
-
async function
|
|
5599
|
-
const { error } = await arbi.fetch.DELETE("/v1/
|
|
5600
|
-
params: { path: {
|
|
5596
|
+
async function deleteNote(arbi, memoryId) {
|
|
5597
|
+
const { error } = await arbi.fetch.DELETE("/v1/notes/{note_ext_id}", {
|
|
5598
|
+
params: { path: { note_ext_id: memoryId } }
|
|
5601
5599
|
});
|
|
5602
|
-
if (error) throw new Error("Failed to delete
|
|
5600
|
+
if (error) throw new Error("Failed to delete note");
|
|
5603
5601
|
}
|
|
5604
5602
|
|
|
5605
5603
|
// src/arbi.ts
|
|
@@ -6078,13 +6076,13 @@ var Arbi = class {
|
|
|
6078
6076
|
delete: (taskId) => deleteTask(this.requireClient(), taskId),
|
|
6079
6077
|
run: (taskId) => runTask(this.requireClient(), taskId)
|
|
6080
6078
|
};
|
|
6081
|
-
// ── Workspace
|
|
6082
|
-
|
|
6083
|
-
create: (body) =>
|
|
6084
|
-
list: (options) =>
|
|
6085
|
-
search: (body) =>
|
|
6086
|
-
update: (
|
|
6087
|
-
delete: (
|
|
6079
|
+
// ── Workspace notes ─────────────────────────────────────────────────
|
|
6080
|
+
notes = {
|
|
6081
|
+
create: (body) => createNote(this.requireClient(), body),
|
|
6082
|
+
list: (options) => listNotes(this.requireClient(), options),
|
|
6083
|
+
search: (body) => searchNotes(this.requireClient(), body),
|
|
6084
|
+
update: (noteId, body) => updateNote(this.requireClient(), noteId, body),
|
|
6085
|
+
delete: (noteId) => deleteNote(this.requireClient(), noteId)
|
|
6088
6086
|
};
|
|
6089
6087
|
// ── Sessions ────────────────────────────────────────────────────────
|
|
6090
6088
|
sessions = {
|
|
@@ -6204,7 +6202,7 @@ exports.formatWorkspaceChoices = formatWorkspaceChoices;
|
|
|
6204
6202
|
exports.getErrorMessage = getErrorMessage;
|
|
6205
6203
|
exports.getRawWorkspaceKey = getRawWorkspaceKey;
|
|
6206
6204
|
exports.health = health_exports;
|
|
6207
|
-
exports.
|
|
6205
|
+
exports.notes = notes_exports;
|
|
6208
6206
|
exports.parseSSEEvents = parseSSEEvents;
|
|
6209
6207
|
exports.parseSlashCommand = parseSlashCommand;
|
|
6210
6208
|
exports.parseSlashTokenInProgress = parseSlashTokenInProgress;
|