@agent-native/core 0.160.0 → 0.161.0
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/corpus/README.md +1 -1
- package/corpus/templates/analytics/actions/bigquery.ts +57 -0
- package/corpus/templates/analytics/actions/restore-analysis-revision.ts +5 -2
- package/corpus/templates/analytics/actions/restore-dashboard-revision.ts +5 -2
- package/corpus/templates/analytics/app/components/analysis/AnalysisHistoryPanel.tsx +14 -3
- package/corpus/templates/analytics/app/components/dashboard/DashboardHistoryPanel.tsx +14 -3
- package/corpus/templates/analytics/app/components/layout/Sidebar.tsx +3 -0
- package/corpus/templates/analytics/app/hooks/use-analysis-revisions.ts +1 -0
- package/corpus/templates/analytics/app/hooks/use-dashboard-revisions.ts +16 -1
- package/corpus/templates/analytics/app/lib/use-auto-focus-select.ts +19 -0
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/PanelEditorDialog.tsx +0 -1
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/dashboard-sync.ts +14 -0
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/index.tsx +19 -0
- package/corpus/templates/analytics/changelog/2026-08-17-fixed-dashboard-editing-focus-history-recovery-panel-setup-f.md +6 -0
- package/corpus/templates/calendar/actions/create-event.ts +7 -3
- package/corpus/templates/calendar/actions/manage-event-draft.ts +8 -0
- package/corpus/templates/calendar/app/components/calendar/CreateEventDialog.tsx +64 -0
- package/corpus/templates/calendar/app/components/calendar/EventDetailPopover.tsx +5 -1
- package/corpus/templates/calendar/app/hooks/use-events.ts +1 -0
- package/corpus/templates/calendar/changelog/2026-08-17-booking-links-now-respect-each-required-host-s-saved-availab.md +6 -0
- package/corpus/templates/calendar/server/lib/booking-host-availability.ts +76 -0
- package/corpus/templates/calendar/server/lib/google-calendar.ts +2 -0
- package/corpus/templates/calendar/shared/api.ts +1 -1
- package/corpus/templates/clips/app/components/player/signed-out-share-actions.tsx +47 -0
- package/corpus/templates/clips/app/components/player/transcript-panel.tsx +3 -1
- package/corpus/templates/clips/app/routes/share.$shareId.tsx +27 -19
- package/corpus/templates/clips/changelog/2026-08-17-shared-clips-sign-in-comment-no-audio.md +6 -0
- package/corpus/templates/clips/server/routes/api/public-recording.get.ts +6 -5
- package/corpus/templates/content/.agents/skills/document-editing/references/databases.md +13 -0
- package/corpus/templates/content/AGENTS.md +2 -0
- package/corpus/templates/content/actions/_blocks-field-identity.ts +17 -0
- package/corpus/templates/content/actions/_database-block-actions.ts +958 -0
- package/corpus/templates/content/actions/_database-row-mutation.ts +7 -7
- package/corpus/templates/content/actions/list-content-database-blocks.ts +31 -0
- package/corpus/templates/content/actions/mutate-content-database-block.ts +49 -0
- package/corpus/templates/content/changelog/2026-08-10-agents-can-safely-insert-update-upsert-delete-and-reorder-on.md +6 -0
- package/corpus/templates/content/docs/product/capabilities/content.object.block.md +6 -2
- package/corpus/templates/content/docs/product/capabilities/content.object.blocks-field.md +2 -1
- package/corpus/templates/content/parity/matrix.md +30 -30
- package/corpus/templates/content/parity/matrix.ts +4 -1
- package/corpus/templates/content/shared/blocks-field-identity.ts +114 -37
- package/corpus/templates/content/shared/database-block-actions.ts +82 -0
- package/corpus/templates/content/shared/database-block-mutations.ts +366 -0
- package/corpus/templates/content/shared/nfm.ts +3 -2
- package/corpus/templates/mail/.agents/skills/email-drafts/SKILL.md +24 -0
- package/corpus/templates/mail/actions/get-mail-settings.ts +1 -1
- package/corpus/templates/mail/actions/update-mail-settings.ts +7 -3
- package/corpus/templates/mail/app/i18n/en-US.ts +3 -1
- package/corpus/templates/mail/app/pages/SettingsPage.tsx +63 -0
- package/corpus/templates/mail/changelog/2026-08-17-gmail-signatures-now-preserve-images-and-support-paste-or-up.md +6 -0
- package/corpus/templates/mail/changelog/2026-08-17-mail-now-updates-durable-drafting-preferences-without-openin.md +6 -0
- package/corpus/templates/mail/server/plugins/agent-chat.ts +19 -0
- package/corpus/templates/mail/shared/gmail-signature.ts +14 -2
- package/corpus/templates/mail/shared/signature.ts +1 -10
- package/corpus/templates/slides/actions/generate-slides-ai.ts +2 -0
- package/corpus/templates/slides/actions/patch-deck.ts +1 -1
- package/corpus/templates/slides/app/components/ThemeToggle.tsx +1 -0
- package/corpus/templates/slides/app/components/editor/SlideThumbnailContextMenu.tsx +59 -0
- package/corpus/templates/slides/app/global.css +1 -0
- package/corpus/templates/slides/app/lib/normalize-slide-padding.ts +40 -11
- package/corpus/templates/slides/changelog/2026-08-17-stable-layout-and-slide-editing.md +6 -0
- package/corpus/templates/slides/shared/deck-title.ts +12 -4
- package/dist/agent/production-agent.js +27 -15
- package/dist/agent/tool-approval-migrations.d.ts +2 -0
- package/dist/agent/tool-approval-migrations.js +20 -0
- package/dist/agent/tool-approval-store.d.ts +17 -3
- package/dist/agent/tool-approval-store.js +56 -6
- package/dist/agent/types.d.ts +3 -1
- package/dist/cli/code-agent-connector.js +79 -7
- package/dist/cli/portal-transfer.d.ts +43 -0
- package/dist/cli/portal-transfer.js +201 -0
- package/dist/client/AssistantChat.js +3 -1
- package/dist/file-upload/actions/upload-image.d.ts +1 -1
- package/dist/localization/core-messages/ar-SA.js +1 -0
- package/dist/localization/core-messages/de-DE.js +1 -0
- package/dist/localization/core-messages/en-US.d.ts +1 -0
- package/dist/localization/core-messages/en-US.js +1 -0
- package/dist/localization/core-messages/es-ES.js +1 -0
- package/dist/localization/core-messages/fr-FR.js +1 -0
- package/dist/localization/core-messages/hi-IN.js +1 -0
- package/dist/localization/core-messages/ja-JP.js +1 -0
- package/dist/localization/core-messages/ko-KR.js +1 -0
- package/dist/localization/core-messages/pt-BR.js +1 -0
- package/dist/localization/core-messages/zh-CN.js +1 -0
- package/dist/localization/core-messages/zh-TW.js +1 -0
- package/dist/localization/core-messages.d.ts +1 -0
- package/dist/mcp/screen-memory-stdio.d.ts +7 -7
- package/dist/resources/handlers.d.ts +1 -1
- package/dist/scripts/resources/read.js +4 -4
- package/dist/scripts/resources/save-memory.js +15 -2
- package/dist/scripts/resources/write.js +3 -3
- package/dist/server/agent-chat/script-entries.d.ts +1 -0
- package/dist/server/agent-chat/script-entries.js +8 -0
- package/dist/server/realtime-token.d.ts +1 -1
- package/dist/server/transcribe-voice.d.ts +1 -1
- package/docs/content/onboarding.mdx +13 -2
- package/package.json +1 -1
|
@@ -137,13 +137,13 @@ export declare function screenMemoryMcpToolDefinitions(): ({
|
|
|
137
137
|
inputSchema: {
|
|
138
138
|
type: string;
|
|
139
139
|
properties: {
|
|
140
|
-
count?: undefined;
|
|
141
140
|
query?: undefined;
|
|
142
141
|
minutes?: undefined;
|
|
143
142
|
limit?: undefined;
|
|
144
143
|
clientHint?: undefined;
|
|
145
144
|
timestamp?: undefined;
|
|
146
145
|
chapterId?: undefined;
|
|
146
|
+
count?: undefined;
|
|
147
147
|
startAt?: undefined;
|
|
148
148
|
endAt?: undefined;
|
|
149
149
|
reason?: undefined;
|
|
@@ -159,7 +159,6 @@ export declare function screenMemoryMcpToolDefinitions(): ({
|
|
|
159
159
|
inputSchema: {
|
|
160
160
|
type: string;
|
|
161
161
|
properties: {
|
|
162
|
-
count?: undefined;
|
|
163
162
|
query: {
|
|
164
163
|
type: string;
|
|
165
164
|
description: string;
|
|
@@ -175,6 +174,7 @@ export declare function screenMemoryMcpToolDefinitions(): ({
|
|
|
175
174
|
clientHint?: undefined;
|
|
176
175
|
timestamp?: undefined;
|
|
177
176
|
chapterId?: undefined;
|
|
177
|
+
count?: undefined;
|
|
178
178
|
startAt?: undefined;
|
|
179
179
|
endAt?: undefined;
|
|
180
180
|
reason?: undefined;
|
|
@@ -190,7 +190,6 @@ export declare function screenMemoryMcpToolDefinitions(): ({
|
|
|
190
190
|
inputSchema: {
|
|
191
191
|
type: string;
|
|
192
192
|
properties: {
|
|
193
|
-
count?: undefined;
|
|
194
193
|
minutes: {
|
|
195
194
|
type: string;
|
|
196
195
|
description: string;
|
|
@@ -200,6 +199,7 @@ export declare function screenMemoryMcpToolDefinitions(): ({
|
|
|
200
199
|
clientHint?: undefined;
|
|
201
200
|
timestamp?: undefined;
|
|
202
201
|
chapterId?: undefined;
|
|
202
|
+
count?: undefined;
|
|
203
203
|
startAt?: undefined;
|
|
204
204
|
endAt?: undefined;
|
|
205
205
|
reason?: undefined;
|
|
@@ -216,7 +216,6 @@ export declare function screenMemoryMcpToolDefinitions(): ({
|
|
|
216
216
|
type: string;
|
|
217
217
|
required: string[];
|
|
218
218
|
properties: {
|
|
219
|
-
count?: undefined;
|
|
220
219
|
query: {
|
|
221
220
|
type: string;
|
|
222
221
|
description: string;
|
|
@@ -235,6 +234,7 @@ export declare function screenMemoryMcpToolDefinitions(): ({
|
|
|
235
234
|
};
|
|
236
235
|
timestamp?: undefined;
|
|
237
236
|
chapterId?: undefined;
|
|
237
|
+
count?: undefined;
|
|
238
238
|
startAt?: undefined;
|
|
239
239
|
endAt?: undefined;
|
|
240
240
|
reason?: undefined;
|
|
@@ -250,7 +250,6 @@ export declare function screenMemoryMcpToolDefinitions(): ({
|
|
|
250
250
|
type: string;
|
|
251
251
|
required: string[];
|
|
252
252
|
properties: {
|
|
253
|
-
count?: undefined;
|
|
254
253
|
query?: undefined;
|
|
255
254
|
minutes?: undefined;
|
|
256
255
|
limit?: undefined;
|
|
@@ -264,6 +263,7 @@ export declare function screenMemoryMcpToolDefinitions(): ({
|
|
|
264
263
|
description: string;
|
|
265
264
|
};
|
|
266
265
|
chapterId?: undefined;
|
|
266
|
+
count?: undefined;
|
|
267
267
|
startAt?: undefined;
|
|
268
268
|
endAt?: undefined;
|
|
269
269
|
includeMicrophone?: undefined;
|
|
@@ -314,13 +314,13 @@ export declare function screenMemoryMcpToolDefinitions(): ({
|
|
|
314
314
|
type: string;
|
|
315
315
|
required: string[];
|
|
316
316
|
properties: {
|
|
317
|
-
count?: undefined;
|
|
318
317
|
query?: undefined;
|
|
319
318
|
minutes?: undefined;
|
|
320
319
|
limit?: undefined;
|
|
321
320
|
clientHint?: undefined;
|
|
322
321
|
timestamp?: undefined;
|
|
323
322
|
chapterId?: undefined;
|
|
323
|
+
count?: undefined;
|
|
324
324
|
startAt: {
|
|
325
325
|
type: string;
|
|
326
326
|
description: string;
|
|
@@ -349,13 +349,13 @@ export declare function screenMemoryMcpToolDefinitions(): ({
|
|
|
349
349
|
type: string;
|
|
350
350
|
required: string[];
|
|
351
351
|
properties: {
|
|
352
|
-
count?: undefined;
|
|
353
352
|
query?: undefined;
|
|
354
353
|
minutes?: undefined;
|
|
355
354
|
limit?: undefined;
|
|
356
355
|
clientHint?: undefined;
|
|
357
356
|
timestamp?: undefined;
|
|
358
357
|
chapterId?: undefined;
|
|
358
|
+
count?: undefined;
|
|
359
359
|
startAt?: undefined;
|
|
360
360
|
endAt?: undefined;
|
|
361
361
|
reason?: undefined;
|
|
@@ -48,8 +48,8 @@ export declare function handleUpdateResource(event: any): Promise<import("./stor
|
|
|
48
48
|
}>;
|
|
49
49
|
/** DELETE /_agent-native/resources/:id — delete a resource */
|
|
50
50
|
export declare function handleDeleteResource(event: any): Promise<{
|
|
51
|
-
error: string;
|
|
52
51
|
ok?: undefined;
|
|
52
|
+
error: string;
|
|
53
53
|
} | {
|
|
54
54
|
error?: undefined;
|
|
55
55
|
ok: boolean;
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
* Usage:
|
|
7
7
|
* pnpm action resource-read --path <path> [--scope personal|shared|workspace]
|
|
8
8
|
*/
|
|
9
|
-
import { resourceGetByPath, ensurePersonalDefaults,
|
|
10
|
-
import { getAmbientUserEmail, getRequestUserEmail, } from "../../server/request-context.js";
|
|
9
|
+
import { resourceGetByPath, ensurePersonalDefaults, sharedResourceOwner, WORKSPACE_OWNER, } from "../../resources/store.js";
|
|
10
|
+
import { getAmbientUserEmail, getRequestOrgId, getRequestUserEmail, } from "../../server/request-context.js";
|
|
11
11
|
import { parseArgs, fail } from "../utils.js";
|
|
12
12
|
export default async function resourceReadScript(args) {
|
|
13
13
|
const parsed = parseArgs(args);
|
|
@@ -44,7 +44,7 @@ Options:
|
|
|
44
44
|
return;
|
|
45
45
|
}
|
|
46
46
|
if (scope === "shared") {
|
|
47
|
-
const resource = await resourceGetByPath(
|
|
47
|
+
const resource = await resourceGetByPath(sharedResourceOwner(getRequestOrgId()), resourcePath);
|
|
48
48
|
if (!resource) {
|
|
49
49
|
console.log(`Resource not found: ${resourcePath} (scope: shared). You can create it with resource-write.`);
|
|
50
50
|
return;
|
|
@@ -63,7 +63,7 @@ Options:
|
|
|
63
63
|
console.log(`Resource not found: ${resourcePath} (scope: personal). You can create it with resource-write.`);
|
|
64
64
|
return;
|
|
65
65
|
}
|
|
66
|
-
const shared = await resourceGetByPath(
|
|
66
|
+
const shared = await resourceGetByPath(sharedResourceOwner(getRequestOrgId()), resourcePath);
|
|
67
67
|
if (shared) {
|
|
68
68
|
process.stdout.write(shared.content);
|
|
69
69
|
return;
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* and maintains a `memory/MEMORY.md` index.
|
|
7
7
|
*/
|
|
8
8
|
import { resourcePut, resourceGetByPath } from "../../resources/store.js";
|
|
9
|
-
import { getAmbientUserEmail, getRequestUserEmail, } from "../../server/request-context.js";
|
|
9
|
+
import { getAmbientUserEmail, getRequestRunContext, getRequestUserEmail, } from "../../server/request-context.js";
|
|
10
10
|
import { parseArgs, fail } from "../utils.js";
|
|
11
11
|
const VALID_TYPES = ["user", "feedback", "project", "reference"];
|
|
12
12
|
const EMPTY_INDEX = `# Memory Index
|
|
@@ -26,7 +26,9 @@ export default async function saveMemoryScript(args) {
|
|
|
26
26
|
const content = parsed.content;
|
|
27
27
|
if (!content)
|
|
28
28
|
fail("--content is required");
|
|
29
|
-
const owner =
|
|
29
|
+
const owner = getRequestRunContext()?.owner ??
|
|
30
|
+
getRequestUserEmail() ??
|
|
31
|
+
getAmbientUserEmail();
|
|
30
32
|
if (!owner) {
|
|
31
33
|
fail("save-memory requires an authenticated user (request context or AGENT_USER_EMAIL env var).");
|
|
32
34
|
}
|
|
@@ -76,5 +78,16 @@ ${content}`;
|
|
|
76
78
|
console.log(`Warning: Memory index has ${lineCount} lines (recommended: <200). Consider consolidating or removing old memories.`);
|
|
77
79
|
}
|
|
78
80
|
await resourcePut(owner, indexPath, updatedIndex, "text/markdown");
|
|
81
|
+
// Do not report success until both writes are visible through the resource
|
|
82
|
+
// read path. This catches storage or ownership mismatches that would
|
|
83
|
+
// otherwise leave the caller believing a memory was saved.
|
|
84
|
+
const persistedMemory = await resourceGetByPath(owner, memoryPath);
|
|
85
|
+
if (persistedMemory?.content !== fileContent) {
|
|
86
|
+
fail(`save-memory could not verify persisted memory "${name}".`);
|
|
87
|
+
}
|
|
88
|
+
const persistedIndex = await resourceGetByPath(owner, indexPath);
|
|
89
|
+
if (persistedIndex?.content !== updatedIndex) {
|
|
90
|
+
fail("save-memory could not verify persisted memory index.");
|
|
91
|
+
}
|
|
79
92
|
console.log(`Saved memory "${name}" (${type}): ${description}`);
|
|
80
93
|
}
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
* Usage:
|
|
7
7
|
* pnpm action resource-write --path <path> --content <content> [--scope personal|shared] [--mime <mime-type>] [--visibility workspace|agent_scratch]
|
|
8
8
|
*/
|
|
9
|
-
import { canWriteLocalWorkspaceResourcePath, resourcePut,
|
|
10
|
-
import { getAmbientUserEmail, getRequestUserEmail, } from "../../server/request-context.js";
|
|
9
|
+
import { canWriteLocalWorkspaceResourcePath, resourcePut, sharedResourceOwner, WORKSPACE_OWNER, } from "../../resources/store.js";
|
|
10
|
+
import { getAmbientUserEmail, getRequestOrgId, getRequestUserEmail, } from "../../server/request-context.js";
|
|
11
11
|
import { parseArgs, fail } from "../utils.js";
|
|
12
12
|
const EXTENSION_MIME_MAP = {
|
|
13
13
|
".md": "text/markdown",
|
|
@@ -101,7 +101,7 @@ Options:
|
|
|
101
101
|
const expiresAt = parseOptionalNumber(parsed["expires-at"] ?? parsed.expiresAt, "--expires-at");
|
|
102
102
|
let owner;
|
|
103
103
|
if (scope === "shared") {
|
|
104
|
-
owner =
|
|
104
|
+
owner = sharedResourceOwner(getRequestOrgId());
|
|
105
105
|
}
|
|
106
106
|
else if (scope === "workspace") {
|
|
107
107
|
owner = WORKSPACE_OWNER;
|
|
@@ -23,6 +23,7 @@ export declare function createDocsScriptEntries(): Promise<Record<string, Action
|
|
|
23
23
|
* Creates resource ScriptEntries available in both prod and dev modes.
|
|
24
24
|
*/
|
|
25
25
|
export declare function shouldDefaultResourceWriteToWorkspace(path: string): boolean;
|
|
26
|
+
export declare function shouldDefaultResourceWriteToShared(path: string): boolean;
|
|
26
27
|
export declare function createResourceScriptEntries(): Promise<Record<string, ActionEntry>>;
|
|
27
28
|
/**
|
|
28
29
|
* Creates a unified chat-history ActionEntry that dispatches to search, open,
|
|
@@ -287,6 +287,9 @@ export function shouldDefaultResourceWriteToWorkspace(path) {
|
|
|
287
287
|
normalized.startsWith("agents/") ||
|
|
288
288
|
normalized.startsWith("remote-agents/"));
|
|
289
289
|
}
|
|
290
|
+
export function shouldDefaultResourceWriteToShared(path) {
|
|
291
|
+
return path.replace(/^\/+/, "") === "LEARNINGS.md";
|
|
292
|
+
}
|
|
290
293
|
export async function createResourceScriptEntries() {
|
|
291
294
|
try {
|
|
292
295
|
const [list, read, effective, write, del, saveMem, delMem, store] = await Promise.all([
|
|
@@ -407,6 +410,11 @@ export async function createResourceScriptEntries() {
|
|
|
407
410
|
rest.content === null)
|
|
408
411
|
return "Error: path and content are required for write";
|
|
409
412
|
rest.createdBy = "agent";
|
|
413
|
+
rest.scope =
|
|
414
|
+
rest.scope ??
|
|
415
|
+
(shouldDefaultResourceWriteToShared(String(rest.path))
|
|
416
|
+
? "shared"
|
|
417
|
+
: undefined);
|
|
410
418
|
rest.visibility =
|
|
411
419
|
rest.visibility ??
|
|
412
420
|
(shouldDefaultResourceWriteToWorkspace(String(rest.path))
|
|
@@ -26,8 +26,8 @@ export declare function createRealtimeTokenHandler(): import("h3").EventHandlerW
|
|
|
26
26
|
expiresAt?: undefined;
|
|
27
27
|
ttlSeconds?: undefined;
|
|
28
28
|
} | {
|
|
29
|
+
error?: undefined;
|
|
29
30
|
token: string;
|
|
30
31
|
expiresAt: string;
|
|
31
32
|
ttlSeconds: number;
|
|
32
|
-
error?: undefined;
|
|
33
33
|
}>>;
|
|
@@ -212,6 +212,10 @@ You can check connection readiness in your `isComplete` callback using the conne
|
|
|
212
212
|
|
|
213
213
|
```ts filename="server/plugins/my-onboarding.ts"
|
|
214
214
|
import { listWorkspaceConnectionProviderCatalogForApp } from "@agent-native/core/workspace-connections";
|
|
215
|
+
import {
|
|
216
|
+
getRequestOrgId,
|
|
217
|
+
getRequestUserEmail,
|
|
218
|
+
} from "@agent-native/core/server";
|
|
215
219
|
|
|
216
220
|
// Inside registerOnboardingStep:
|
|
217
221
|
isComplete: async () => {
|
|
@@ -230,8 +234,15 @@ isComplete: async () => {
|
|
|
230
234
|
return true;
|
|
231
235
|
}
|
|
232
236
|
|
|
233
|
-
//
|
|
234
|
-
|
|
237
|
+
// If there is no reusable connection, check the caller-scoped credential
|
|
238
|
+
// store - never a deployment environment variable.
|
|
239
|
+
const { resolveCredential } = await import("@agent-native/core/credentials");
|
|
240
|
+
return Boolean(
|
|
241
|
+
await resolveCredential("GMAIL_REFRESH_TOKEN", {
|
|
242
|
+
userEmail: getRequestUserEmail(),
|
|
243
|
+
orgId: getRequestOrgId(),
|
|
244
|
+
}),
|
|
245
|
+
);
|
|
235
246
|
};
|
|
236
247
|
```
|
|
237
248
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agent-native/core",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.161.0",
|
|
4
4
|
"description": "Framework for agent-native application development — where AI agents and UI share SQL state, actions, and context",
|
|
5
5
|
"homepage": "https://github.com/BuilderIO/agent-native#readme",
|
|
6
6
|
"bugs": {
|