@standardagents/builder 0.18.3 → 0.19.1
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/built-in-routes.js +89 -21
- package/dist/built-in-routes.js.map +1 -1
- package/dist/client/CompositionView.js +1 -1
- package/dist/client/ConfirmDialog.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/client/JsonViewer.js +1 -1
- package/dist/client/LoginView.js +1 -1
- package/dist/client/Modal.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/client/ModelModal.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/client/ModelsView.js +1 -1
- package/dist/client/PromptsView.js +1 -1
- package/dist/client/ProvidersView.js +1 -1
- package/dist/client/ThreadInspectorPane.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/client/ToolsView.js +1 -1
- package/dist/client/assets/index.css +1 -1
- package/dist/client/index.js +2 -2
- package/dist/index.js +17 -2
- package/dist/index.js.map +1 -1
- package/dist/plugin.js +10 -2
- package/dist/plugin.js.map +1 -1
- package/dist/runtime.d.ts +1 -0
- package/dist/runtime.js +7 -0
- package/dist/runtime.js.map +1 -1
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -19781,11 +19781,19 @@ function platformEndpoint(env) {
|
|
|
19781
19781
|
}
|
|
19782
19782
|
|
|
19783
19783
|
function hostedInstanceRedirectId(request, env) {
|
|
19784
|
-
const configured = env && (env.
|
|
19784
|
+
const configured = env && (env.STANDARD_AGENTS_INSTANCE_HOST || env.STANDARD_AGENTS_INSTANCE_SUBDOMAIN || env.STANDARD_AGENTS_INSTANCE_ID);
|
|
19785
19785
|
if (typeof configured === 'string' && configured.trim()) {
|
|
19786
19786
|
return configured.trim();
|
|
19787
19787
|
}
|
|
19788
|
-
|
|
19788
|
+
const hostname = new URL(request.url).hostname;
|
|
19789
|
+
if (hostname && hostname !== 'localhost' && hostname !== '127.0.0.1' && hostname !== 'standardagents.internal') {
|
|
19790
|
+
return hostname;
|
|
19791
|
+
}
|
|
19792
|
+
const projectId = env && env.STANDARD_AGENTS_PROJECT_ID;
|
|
19793
|
+
if (typeof projectId === 'string' && projectId.trim()) {
|
|
19794
|
+
return projectId.trim();
|
|
19795
|
+
}
|
|
19796
|
+
return hostname;
|
|
19789
19797
|
}
|
|
19790
19798
|
|
|
19791
19799
|
function platformLoginUrl(request, env) {
|
|
@@ -29051,6 +29059,13 @@ ${result ?? error ?? "No result content."}${attachmentSummary}`;
|
|
|
29051
29059
|
for (const replicaUser of snapshot.users) {
|
|
29052
29060
|
const user = await this.upsertPlatformReplicaUser(replicaUser);
|
|
29053
29061
|
activeUserIds.add(user.id);
|
|
29062
|
+
if (typeof replicaUser.session_revoked_at === "number" && Number.isFinite(replicaUser.session_revoked_at)) {
|
|
29063
|
+
await this.ctx.storage.sql.exec(
|
|
29064
|
+
`DELETE FROM sessions WHERE user_id = ? AND created_at <= ?`,
|
|
29065
|
+
user.id,
|
|
29066
|
+
Math.floor(replicaUser.session_revoked_at)
|
|
29067
|
+
);
|
|
29068
|
+
}
|
|
29054
29069
|
}
|
|
29055
29070
|
const activeList = Array.from(activeUserIds);
|
|
29056
29071
|
if (activeList.length > 0) {
|