@burdenoff/microfe-botmanor 2026.1027.2 → 2026.1027.3
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/botlit/BotlitRoutes.js +142 -132
- package/dist/botlit/BotlitRoutes.js.map +1 -1
- package/dist/botlit/components/AgentApprovalPanel.js +144 -126
- package/dist/botlit/components/AgentApprovalPanel.js.map +1 -1
- package/dist/botlit/components/ModelRegistrationPanel.js +4 -4
- package/dist/botlit/components/VersionHistoryPanel.js +92 -83
- package/dist/botlit/components/VersionHistoryPanel.js.map +1 -1
- package/dist/botlit/pages/A2AAgentDetailPage.js +212 -203
- package/dist/botlit/pages/A2AAgentDetailPage.js.map +1 -1
- package/dist/botlit/pages/A2ARegistryPage.js +129 -117
- package/dist/botlit/pages/A2ARegistryPage.js.map +1 -1
- package/dist/botlit/pages/AgentApprovalsPage.js +122 -110
- package/dist/botlit/pages/AgentApprovalsPage.js.map +1 -1
- package/dist/botlit/pages/AgentBuilderPage.js +18 -18
- package/dist/botlit/pages/AgentDetailPage.js +298 -273
- package/dist/botlit/pages/AgentDetailPage.js.map +1 -1
- package/dist/botlit/pages/AgentsListPage.js +145 -121
- package/dist/botlit/pages/AgentsListPage.js.map +1 -1
- package/dist/botlit/pages/BotChannelsTab.js +238 -226
- package/dist/botlit/pages/BotChannelsTab.js.map +1 -1
- package/dist/botlit/pages/BotDetailPage.js +307 -288
- package/dist/botlit/pages/BotDetailPage.js.map +1 -1
- package/dist/botlit/pages/BotWorkflowTab.js +125 -116
- package/dist/botlit/pages/BotWorkflowTab.js.map +1 -1
- package/dist/botlit/pages/BotsListPage.js +159 -144
- package/dist/botlit/pages/BotsListPage.js.map +1 -1
- package/dist/botlit/pages/BucketsPage.js +279 -258
- package/dist/botlit/pages/BucketsPage.js.map +1 -1
- package/dist/botlit/pages/ChannelDetailPage.js +346 -328
- package/dist/botlit/pages/ChannelDetailPage.js.map +1 -1
- package/dist/botlit/pages/ChannelRoutesPage.js +10 -10
- package/dist/botlit/pages/ChannelsPage.js +163 -148
- package/dist/botlit/pages/ChannelsPage.js.map +1 -1
- package/dist/botlit/pages/DashboardPage.js +129 -114
- package/dist/botlit/pages/DashboardPage.js.map +1 -1
- package/dist/botlit/pages/ExecutionDetailPage.js +145 -139
- package/dist/botlit/pages/ExecutionDetailPage.js.map +1 -1
- package/dist/botlit/pages/ExecutionsPage.js +14 -14
- package/dist/botlit/pages/InstalledPackagesPage.js +245 -227
- package/dist/botlit/pages/InstalledPackagesPage.js.map +1 -1
- package/dist/botlit/pages/KnowledgeBaseDetailPage.js +168 -156
- package/dist/botlit/pages/KnowledgeBaseDetailPage.js.map +1 -1
- package/dist/botlit/pages/KnowledgeBasesPage.js +91 -79
- package/dist/botlit/pages/KnowledgeBasesPage.js.map +1 -1
- package/dist/botlit/pages/MCPServerDetailPage.js +200 -188
- package/dist/botlit/pages/MCPServerDetailPage.js.map +1 -1
- package/dist/botlit/pages/MCPServersPage.js +170 -155
- package/dist/botlit/pages/MCPServersPage.js.map +1 -1
- package/dist/botlit/pages/PoliciesPage.js +113 -104
- package/dist/botlit/pages/PoliciesPage.js.map +1 -1
- package/dist/botlit/pages/PolicyDetailPage.js +145 -133
- package/dist/botlit/pages/PolicyDetailPage.js.map +1 -1
- package/dist/botlit/pages/PromptStudioPage.js +106 -97
- package/dist/botlit/pages/PromptStudioPage.js.map +1 -1
- package/dist/botlit/pages/PromptTemplateDetailPage.js +359 -347
- package/dist/botlit/pages/PromptTemplateDetailPage.js.map +1 -1
- package/dist/botlit/pages/PromptTemplatesPage.js +127 -112
- package/dist/botlit/pages/PromptTemplatesPage.js.map +1 -1
- package/dist/botlit/pages/RetrievalProfileDetailPage.js +219 -210
- package/dist/botlit/pages/RetrievalProfileDetailPage.js.map +1 -1
- package/dist/botlit/pages/RetrievalProfilesPage.js +112 -103
- package/dist/botlit/pages/RetrievalProfilesPage.js.map +1 -1
- package/dist/botlit/pages/SettingsPage.js +264 -252
- package/dist/botlit/pages/SettingsPage.js.map +1 -1
- package/dist/botlit/pages/SkillDetailPage.js +235 -226
- package/dist/botlit/pages/SkillDetailPage.js.map +1 -1
- package/dist/botlit/pages/SkillsPage.js +115 -106
- package/dist/botlit/pages/SkillsPage.js.map +1 -1
- package/dist/botlit/pages/StorePackageDetailPage.js +194 -188
- package/dist/botlit/pages/StorePackageDetailPage.js.map +1 -1
- package/dist/botlit/pages/StorePage.js +161 -155
- package/dist/botlit/pages/StorePage.js.map +1 -1
- package/dist/botlit/permissions/PermissionRequired.js +45 -0
- package/dist/botlit/permissions/PermissionRequired.js.map +1 -0
- package/dist/botlit/permissions/botmanorPermissions.js +72 -0
- package/dist/botlit/permissions/botmanorPermissions.js.map +1 -0
- package/dist/botlit/permissions/index.js +3 -0
- package/dist/botlit/permissions/useBotmanorPermissions.js +19 -0
- package/dist/botlit/permissions/useBotmanorPermissions.js.map +1 -0
- package/package.json +1 -1
|
@@ -1,24 +1,27 @@
|
|
|
1
1
|
import { useBotlit as e } from "../providers/BotlitProvider.js";
|
|
2
2
|
import { formatRelativeTime as t } from "../utils/formatters.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
3
|
+
import { BOTMANOR_PERMISSIONS as n } from "../permissions/botmanorPermissions.js";
|
|
4
|
+
import { BotmanorPermissionGate as r } from "../permissions/useBotmanorPermissions.js";
|
|
5
|
+
import { PageLayout as i } from "../components/PageLayout.js";
|
|
6
|
+
import { Button as a } from "../components/Button.js";
|
|
7
|
+
import "../permissions/index.js";
|
|
8
|
+
import { Card as o, CardContent as s, CardDescription as c, CardHeader as l, CardTitle as u } from "../components/Card.js";
|
|
6
9
|
import { Badge as ee, StatusBadge as te } from "../components/Badge.js";
|
|
7
|
-
import { isNative as
|
|
10
|
+
import { isNative as d, nativeImpact as ne, nativeNotify as f } from "../../utils/nativeBridge.js";
|
|
8
11
|
import { EmptyState as re } from "../components/EmptyState.js";
|
|
9
|
-
import { FormField as
|
|
10
|
-
import { useCreatePolicy as
|
|
11
|
-
import { toUnion as
|
|
12
|
+
import { FormField as p, Input as m, Textarea as h } from "../components/Input.js";
|
|
13
|
+
import { useCreatePolicy as ie, useDeletePolicy as ae, usePolicy as oe, useUpdatePolicy as se } from "../hooks/usePolicies.js";
|
|
14
|
+
import { toUnion as g } from "../utils/unions.js";
|
|
12
15
|
import "../hooks/index.js";
|
|
13
|
-
import { A2A_TRUST_LEVELS as
|
|
14
|
-
import { useState as
|
|
15
|
-
import { PagePurpose as
|
|
16
|
-
import { Fragment as
|
|
17
|
-
import { useParams as
|
|
18
|
-
import { AlertTriangle as b, ArrowLeft as
|
|
16
|
+
import { A2A_TRUST_LEVELS as ce, CREATABLE_POLICY_TYPES as le, EMPTY_POLICY_FORM as ue, TOOL_RISK_LEVELS as de, buildPolicyConfig as fe, isCreatablePolicyType as pe, unenforcedConfigKeys as me } from "../utils/policyConfig.js";
|
|
17
|
+
import { useState as _ } from "react";
|
|
18
|
+
import { PagePurpose as he } from "@burdenoff/fe-libs/ui";
|
|
19
|
+
import { Fragment as ge, jsx as v, jsxs as y } from "react/jsx-runtime";
|
|
20
|
+
import { useParams as _e } from "react-router";
|
|
21
|
+
import { AlertTriangle as b, ArrowLeft as ve, Clock as x, Database as S, DollarSign as C, Edit as ye, FileText as w, Power as be, Save as T, Settings as xe, Shield as E, Trash2 as D, Wrench as O } from "lucide-react";
|
|
19
22
|
import { toast as k } from "sonner";
|
|
20
23
|
//#region src/botlit/pages/PolicyDetailPage.tsx
|
|
21
|
-
var
|
|
24
|
+
var Se = [
|
|
22
25
|
"CONTENT",
|
|
23
26
|
"TOOL",
|
|
24
27
|
"DATA",
|
|
@@ -26,7 +29,7 @@ var be = [
|
|
|
26
29
|
"BUDGET",
|
|
27
30
|
"RATE_LIMIT",
|
|
28
31
|
"RETENTION"
|
|
29
|
-
],
|
|
32
|
+
], Ce = [
|
|
30
33
|
"PRIVATE",
|
|
31
34
|
"WORKSPACE",
|
|
32
35
|
"PUBLIC"
|
|
@@ -47,32 +50,32 @@ var be = [
|
|
|
47
50
|
RATE_LIMIT: "Rate Limit Policy",
|
|
48
51
|
RETENTION: "Retention Policy"
|
|
49
52
|
}, N = ({ isNew: S }) => {
|
|
50
|
-
let { policyId: N } =
|
|
53
|
+
let { policyId: N } = _e(), { navigateTo: P } = e(), { data: F, loading: we, refetch: I } = oe(S ? void 0 : N), { create: Te, loading: Ee } = ie(), { update: L, loading: R } = se(), { remove: De, loading: Oe } = ae(), [z, B] = _(!1), [ke, V] = _(!1), [H, U] = _({
|
|
51
54
|
name: "",
|
|
52
55
|
description: "",
|
|
53
56
|
type: "CONTENT",
|
|
54
57
|
visibility: "PRIVATE"
|
|
55
|
-
}), [W, G] =
|
|
58
|
+
}), [W, G] = _({
|
|
56
59
|
name: "",
|
|
57
60
|
description: "",
|
|
58
61
|
visibility: "PRIVATE"
|
|
59
|
-
}), [K,
|
|
60
|
-
J(null),
|
|
62
|
+
}), [K, Ae] = _(ue), [q, J] = _(null), Y = (e, t) => {
|
|
63
|
+
J(null), Ae((n) => ({
|
|
61
64
|
...n,
|
|
62
65
|
[e]: {
|
|
63
66
|
...n[e],
|
|
64
67
|
...t
|
|
65
68
|
}
|
|
66
69
|
}));
|
|
67
|
-
}, [X,
|
|
70
|
+
}, [X, je] = _(!1), Me = async () => {
|
|
68
71
|
if (!H.name) return;
|
|
69
|
-
let e =
|
|
72
|
+
let e = fe(H.type, K);
|
|
70
73
|
if (!e.ok) {
|
|
71
74
|
J(e.error), k.error(e.error);
|
|
72
75
|
return;
|
|
73
76
|
}
|
|
74
77
|
try {
|
|
75
|
-
await
|
|
78
|
+
await Te({
|
|
76
79
|
name: H.name,
|
|
77
80
|
description: H.description,
|
|
78
81
|
type: H.type,
|
|
@@ -85,7 +88,7 @@ var be = [
|
|
|
85
88
|
return;
|
|
86
89
|
}
|
|
87
90
|
k.success(`Policy "${H.name}" created`), P("policies");
|
|
88
|
-
},
|
|
91
|
+
}, Ne = async () => {
|
|
89
92
|
if (!(!N || !W.name)) {
|
|
90
93
|
try {
|
|
91
94
|
await L({
|
|
@@ -102,13 +105,13 @@ var be = [
|
|
|
102
105
|
}
|
|
103
106
|
await I(), k.success("Policy updated"), B(!1);
|
|
104
107
|
}
|
|
105
|
-
},
|
|
108
|
+
}, Pe = async () => {
|
|
106
109
|
if (N) try {
|
|
107
|
-
await
|
|
110
|
+
await De(N), d() && f("success"), P("policies");
|
|
108
111
|
} catch (e) {
|
|
109
|
-
throw
|
|
112
|
+
throw d() && f("error"), e;
|
|
110
113
|
}
|
|
111
|
-
}, Z = F?.status === "ACTIVE",
|
|
114
|
+
}, Z = F?.status === "ACTIVE", Fe = async () => {
|
|
112
115
|
if (!N) return;
|
|
113
116
|
let e = Z ? "DRAFT" : "ACTIVE";
|
|
114
117
|
try {
|
|
@@ -121,26 +124,26 @@ var be = [
|
|
|
121
124
|
return;
|
|
122
125
|
}
|
|
123
126
|
await I(), k.success(e === "ACTIVE" ? "Policy is now enforced" : "Policy is no longer enforced");
|
|
124
|
-
},
|
|
127
|
+
}, Ie = () => {
|
|
125
128
|
F && (G({
|
|
126
129
|
name: F.name,
|
|
127
130
|
description: F.description || "",
|
|
128
|
-
visibility:
|
|
131
|
+
visibility: g(F.visibility, Ce, "PRIVATE")
|
|
129
132
|
}), B(!0));
|
|
130
133
|
};
|
|
131
|
-
if (S) return /* @__PURE__ */ v(
|
|
134
|
+
if (S) return /* @__PURE__ */ v(i, {
|
|
132
135
|
title: "Create Policy",
|
|
133
136
|
description: "Define guardrails and constraints for your AI agents",
|
|
134
137
|
actions: /* @__PURE__ */ y("div", {
|
|
135
138
|
className: "flex gap-2",
|
|
136
|
-
children: [/* @__PURE__ */ v(
|
|
139
|
+
children: [/* @__PURE__ */ v(a, {
|
|
137
140
|
variant: "outline",
|
|
138
141
|
onClick: () => P("policies"),
|
|
139
142
|
children: "Cancel"
|
|
140
|
-
}), /* @__PURE__ */ v(
|
|
143
|
+
}), /* @__PURE__ */ v(a, {
|
|
141
144
|
leftIcon: /* @__PURE__ */ v(T, { size: 16 }),
|
|
142
|
-
onClick:
|
|
143
|
-
isLoading:
|
|
145
|
+
onClick: Me,
|
|
146
|
+
isLoading: Ee,
|
|
144
147
|
disabled: !H.name,
|
|
145
148
|
children: "Create"
|
|
146
149
|
})]
|
|
@@ -148,13 +151,13 @@ var be = [
|
|
|
148
151
|
children: /* @__PURE__ */ y("div", {
|
|
149
152
|
className: "max-w-2xl space-y-6",
|
|
150
153
|
children: [
|
|
151
|
-
/* @__PURE__ */ y(
|
|
154
|
+
/* @__PURE__ */ y(o, { children: [/* @__PURE__ */ v(l, { children: /* @__PURE__ */ v(u, { children: "Basic Information" }) }), /* @__PURE__ */ y(s, {
|
|
152
155
|
className: "space-y-4",
|
|
153
156
|
children: [
|
|
154
|
-
/* @__PURE__ */ v(
|
|
157
|
+
/* @__PURE__ */ v(p, {
|
|
155
158
|
label: "Policy Name",
|
|
156
159
|
required: !0,
|
|
157
|
-
children: /* @__PURE__ */ v(
|
|
160
|
+
children: /* @__PURE__ */ v(m, {
|
|
158
161
|
placeholder: "e.g., Production Content Policy",
|
|
159
162
|
value: H.name,
|
|
160
163
|
onChange: (e) => U({
|
|
@@ -163,9 +166,9 @@ var be = [
|
|
|
163
166
|
})
|
|
164
167
|
})
|
|
165
168
|
}),
|
|
166
|
-
/* @__PURE__ */ v(
|
|
169
|
+
/* @__PURE__ */ v(p, {
|
|
167
170
|
label: "Description",
|
|
168
|
-
children: /* @__PURE__ */ v(
|
|
171
|
+
children: /* @__PURE__ */ v(h, {
|
|
169
172
|
placeholder: "What does this policy enforce?",
|
|
170
173
|
value: H.description,
|
|
171
174
|
onChange: (e) => U({
|
|
@@ -177,7 +180,7 @@ var be = [
|
|
|
177
180
|
}),
|
|
178
181
|
/* @__PURE__ */ y("div", {
|
|
179
182
|
className: "grid grid-cols-2 gap-4",
|
|
180
|
-
children: [/* @__PURE__ */ v(
|
|
183
|
+
children: [/* @__PURE__ */ v(p, {
|
|
181
184
|
label: "Policy Type",
|
|
182
185
|
required: !0,
|
|
183
186
|
children: /* @__PURE__ */ v("select", {
|
|
@@ -185,17 +188,17 @@ var be = [
|
|
|
185
188
|
value: H.type,
|
|
186
189
|
onChange: (e) => {
|
|
187
190
|
let t = e.target.value;
|
|
188
|
-
|
|
191
|
+
pe(t) && (J(null), U({
|
|
189
192
|
...H,
|
|
190
193
|
type: t
|
|
191
194
|
}));
|
|
192
195
|
},
|
|
193
|
-
children:
|
|
196
|
+
children: le.map((e) => /* @__PURE__ */ v("option", {
|
|
194
197
|
value: e,
|
|
195
198
|
children: M[e]
|
|
196
199
|
}, e))
|
|
197
200
|
})
|
|
198
|
-
}), /* @__PURE__ */ v(
|
|
201
|
+
}), /* @__PURE__ */ v(p, {
|
|
199
202
|
label: "Visibility",
|
|
200
203
|
children: /* @__PURE__ */ y("select", {
|
|
201
204
|
className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
|
|
@@ -223,10 +226,10 @@ var be = [
|
|
|
223
226
|
})
|
|
224
227
|
]
|
|
225
228
|
})] }),
|
|
226
|
-
H.type === "CONTENT" && /* @__PURE__ */ y(
|
|
229
|
+
H.type === "CONTENT" && /* @__PURE__ */ y(o, { children: [/* @__PURE__ */ y(l, { children: [/* @__PURE__ */ y(u, {
|
|
227
230
|
className: "flex items-center gap-2",
|
|
228
231
|
children: [/* @__PURE__ */ v(b, { size: 18 }), "Content Policy Configuration"]
|
|
229
|
-
}), /* @__PURE__ */ v(
|
|
232
|
+
}), /* @__PURE__ */ v(c, { children: "Checked against every message sent to an agent and every response it gives. A blocked message is refused; a blocked response is replaced with a refusal." })] }), /* @__PURE__ */ y(s, {
|
|
230
233
|
className: "space-y-4",
|
|
231
234
|
children: [
|
|
232
235
|
/* @__PURE__ */ y("div", {
|
|
@@ -249,19 +252,19 @@ var be = [
|
|
|
249
252
|
})]
|
|
250
253
|
})]
|
|
251
254
|
}),
|
|
252
|
-
/* @__PURE__ */ v(
|
|
255
|
+
/* @__PURE__ */ v(p, {
|
|
253
256
|
label: "Blocked Keywords",
|
|
254
257
|
description: "Comma-separated. Case-insensitive; any occurrence blocks the text.",
|
|
255
|
-
children: /* @__PURE__ */ v(
|
|
258
|
+
children: /* @__PURE__ */ v(m, {
|
|
256
259
|
placeholder: "e.g., internal-only, project-x",
|
|
257
260
|
value: K.content.blockedKeywords,
|
|
258
261
|
onChange: (e) => Y("content", { blockedKeywords: e.target.value })
|
|
259
262
|
})
|
|
260
263
|
}),
|
|
261
|
-
/* @__PURE__ */ v(
|
|
264
|
+
/* @__PURE__ */ v(p, {
|
|
262
265
|
label: "Blocked Patterns",
|
|
263
266
|
description: "One regular expression per line, matched case-insensitively.",
|
|
264
|
-
children: /* @__PURE__ */ v(
|
|
267
|
+
children: /* @__PURE__ */ v(h, {
|
|
265
268
|
placeholder: "e.g., \\bACME-\\d{6}\\b",
|
|
266
269
|
value: K.content.blockedPatterns,
|
|
267
270
|
onChange: (e) => Y("content", { blockedPatterns: e.target.value }),
|
|
@@ -270,25 +273,25 @@ var be = [
|
|
|
270
273
|
})
|
|
271
274
|
]
|
|
272
275
|
})] }),
|
|
273
|
-
H.type === "TOOL" && /* @__PURE__ */ y(
|
|
276
|
+
H.type === "TOOL" && /* @__PURE__ */ y(o, { children: [/* @__PURE__ */ y(l, { children: [/* @__PURE__ */ y(u, {
|
|
274
277
|
className: "flex items-center gap-2",
|
|
275
278
|
children: [/* @__PURE__ */ v(O, { size: 18 }), "Tool Policy Configuration"]
|
|
276
|
-
}), /* @__PURE__ */ v(
|
|
279
|
+
}), /* @__PURE__ */ v(c, { children: "Applies to MCP tool calls made by agents and through Call Tool, and to agent delegation. Leave a field empty to not restrict it." })] }), /* @__PURE__ */ y(s, {
|
|
277
280
|
className: "space-y-4",
|
|
278
281
|
children: [
|
|
279
|
-
/* @__PURE__ */ v(
|
|
282
|
+
/* @__PURE__ */ v(p, {
|
|
280
283
|
label: "Allowed Tools",
|
|
281
284
|
description: "Comma-separated MCP tool names. End an entry with * to allow a prefix. Empty allows every tool.",
|
|
282
|
-
children: /* @__PURE__ */ v(
|
|
285
|
+
children: /* @__PURE__ */ v(m, {
|
|
283
286
|
placeholder: "e.g., search, read_*",
|
|
284
287
|
value: K.tool.allowedTools,
|
|
285
288
|
onChange: (e) => Y("tool", { allowedTools: e.target.value })
|
|
286
289
|
})
|
|
287
290
|
}),
|
|
288
|
-
/* @__PURE__ */ v(
|
|
291
|
+
/* @__PURE__ */ v(p, {
|
|
289
292
|
label: "Denied Tools",
|
|
290
293
|
description: "Comma-separated MCP tool names that may never run. A deny always wins.",
|
|
291
|
-
children: /* @__PURE__ */ v(
|
|
294
|
+
children: /* @__PURE__ */ v(m, {
|
|
292
295
|
placeholder: "e.g., delete_*, execute_code",
|
|
293
296
|
value: K.tool.deniedTools,
|
|
294
297
|
onChange: (e) => Y("tool", { deniedTools: e.target.value })
|
|
@@ -296,7 +299,7 @@ var be = [
|
|
|
296
299
|
}),
|
|
297
300
|
/* @__PURE__ */ y("div", {
|
|
298
301
|
className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
|
|
299
|
-
children: [/* @__PURE__ */ v(
|
|
302
|
+
children: [/* @__PURE__ */ v(p, {
|
|
300
303
|
label: "Max Tool Risk Level",
|
|
301
304
|
children: /* @__PURE__ */ y("select", {
|
|
302
305
|
className: A,
|
|
@@ -305,12 +308,12 @@ var be = [
|
|
|
305
308
|
children: [/* @__PURE__ */ v("option", {
|
|
306
309
|
value: "",
|
|
307
310
|
children: "Any risk level"
|
|
308
|
-
}),
|
|
311
|
+
}), de.map((e) => /* @__PURE__ */ y("option", {
|
|
309
312
|
value: e,
|
|
310
313
|
children: ["Up to ", e.toLowerCase()]
|
|
311
314
|
}, e))]
|
|
312
315
|
})
|
|
313
|
-
}), /* @__PURE__ */ v(
|
|
316
|
+
}), /* @__PURE__ */ v(p, {
|
|
314
317
|
label: "Minimum A2A Trust Level",
|
|
315
318
|
description: "For delegation to external registry agents.",
|
|
316
319
|
children: /* @__PURE__ */ y("select", {
|
|
@@ -320,7 +323,7 @@ var be = [
|
|
|
320
323
|
children: [/* @__PURE__ */ v("option", {
|
|
321
324
|
value: "",
|
|
322
325
|
children: "Default (verified publisher)"
|
|
323
|
-
}),
|
|
326
|
+
}), ce.map((e) => /* @__PURE__ */ v("option", {
|
|
324
327
|
value: e,
|
|
325
328
|
children: e === "VERIFIED_PUBLISHER" ? "Verified publisher" : e.charAt(0) + e.slice(1).toLowerCase()
|
|
326
329
|
}, e))]
|
|
@@ -329,20 +332,20 @@ var be = [
|
|
|
329
332
|
}),
|
|
330
333
|
/* @__PURE__ */ y("div", {
|
|
331
334
|
className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
|
|
332
|
-
children: [/* @__PURE__ */ v(
|
|
335
|
+
children: [/* @__PURE__ */ v(p, {
|
|
333
336
|
label: "Max Tool Calls Per Execution",
|
|
334
337
|
description: "Tool calls allowed in one agent turn.",
|
|
335
|
-
children: /* @__PURE__ */ v(
|
|
338
|
+
children: /* @__PURE__ */ v(m, {
|
|
336
339
|
type: "number",
|
|
337
340
|
min: 1,
|
|
338
341
|
placeholder: "No limit",
|
|
339
342
|
value: K.tool.maxCallsPerExecution,
|
|
340
343
|
onChange: (e) => Y("tool", { maxCallsPerExecution: e.target.value })
|
|
341
344
|
})
|
|
342
|
-
}), /* @__PURE__ */ v(
|
|
345
|
+
}), /* @__PURE__ */ v(p, {
|
|
343
346
|
label: "Tool Call Timeout (seconds)",
|
|
344
347
|
description: "Can only shorten the platform's own timeout.",
|
|
345
|
-
children: /* @__PURE__ */ v(
|
|
348
|
+
children: /* @__PURE__ */ v(m, {
|
|
346
349
|
type: "number",
|
|
347
350
|
min: 1,
|
|
348
351
|
placeholder: "Platform default",
|
|
@@ -353,27 +356,27 @@ var be = [
|
|
|
353
356
|
})
|
|
354
357
|
]
|
|
355
358
|
})] }),
|
|
356
|
-
H.type === "BUDGET" && /* @__PURE__ */ y(
|
|
359
|
+
H.type === "BUDGET" && /* @__PURE__ */ y(o, { children: [/* @__PURE__ */ y(l, { children: [/* @__PURE__ */ y(u, {
|
|
357
360
|
className: "flex items-center gap-2",
|
|
358
361
|
children: [/* @__PURE__ */ v(C, { size: 18 }), "Budget Policy Configuration"]
|
|
359
|
-
}), /* @__PURE__ */ v(
|
|
362
|
+
}), /* @__PURE__ */ v(c, { children: "Token budgets apply per agent. Leave a field empty to not restrict it." })] }), /* @__PURE__ */ v(s, {
|
|
360
363
|
className: "space-y-4",
|
|
361
364
|
children: /* @__PURE__ */ y("div", {
|
|
362
365
|
className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
|
|
363
|
-
children: [/* @__PURE__ */ v(
|
|
366
|
+
children: [/* @__PURE__ */ v(p, {
|
|
364
367
|
label: "Max Tokens Per Day",
|
|
365
368
|
description: "An agent that has used this many tokens today (UTC) is refused.",
|
|
366
|
-
children: /* @__PURE__ */ v(
|
|
369
|
+
children: /* @__PURE__ */ v(m, {
|
|
367
370
|
type: "number",
|
|
368
371
|
min: 1,
|
|
369
372
|
placeholder: "No limit",
|
|
370
373
|
value: K.budget.maxTokensPerDay,
|
|
371
374
|
onChange: (e) => Y("budget", { maxTokensPerDay: e.target.value })
|
|
372
375
|
})
|
|
373
|
-
}), /* @__PURE__ */ v(
|
|
376
|
+
}), /* @__PURE__ */ v(p, {
|
|
374
377
|
label: "Max Output Tokens Per Model Call",
|
|
375
378
|
description: "Lowers the agent's own max-tokens setting when it is higher.",
|
|
376
|
-
children: /* @__PURE__ */ v(
|
|
379
|
+
children: /* @__PURE__ */ v(m, {
|
|
377
380
|
type: "number",
|
|
378
381
|
min: 1,
|
|
379
382
|
placeholder: "No limit",
|
|
@@ -383,17 +386,17 @@ var be = [
|
|
|
383
386
|
})]
|
|
384
387
|
})
|
|
385
388
|
})] }),
|
|
386
|
-
H.type === "RATE_LIMIT" && /* @__PURE__ */ y(
|
|
389
|
+
H.type === "RATE_LIMIT" && /* @__PURE__ */ y(o, { children: [/* @__PURE__ */ y(l, { children: [/* @__PURE__ */ y(u, {
|
|
387
390
|
className: "flex items-center gap-2",
|
|
388
391
|
children: [/* @__PURE__ */ v(x, { size: 18 }), "Rate Limit Configuration"]
|
|
389
|
-
}), /* @__PURE__ */ v(
|
|
392
|
+
}), /* @__PURE__ */ v(c, { children: "Every limit is counted per agent. Leave a field empty to not restrict it." })] }), /* @__PURE__ */ v(s, {
|
|
390
393
|
className: "space-y-4",
|
|
391
394
|
children: /* @__PURE__ */ y("div", {
|
|
392
395
|
className: "grid grid-cols-1 sm:grid-cols-3 gap-4",
|
|
393
396
|
children: [
|
|
394
|
-
/* @__PURE__ */ v(
|
|
397
|
+
/* @__PURE__ */ v(p, {
|
|
395
398
|
label: "Requests / Minute",
|
|
396
|
-
children: /* @__PURE__ */ v(
|
|
399
|
+
children: /* @__PURE__ */ v(m, {
|
|
397
400
|
type: "number",
|
|
398
401
|
min: 1,
|
|
399
402
|
placeholder: "No limit",
|
|
@@ -401,9 +404,9 @@ var be = [
|
|
|
401
404
|
onChange: (e) => Y("rateLimit", { requestsPerMinute: e.target.value })
|
|
402
405
|
})
|
|
403
406
|
}),
|
|
404
|
-
/* @__PURE__ */ v(
|
|
407
|
+
/* @__PURE__ */ v(p, {
|
|
405
408
|
label: "Requests / Hour",
|
|
406
|
-
children: /* @__PURE__ */ v(
|
|
409
|
+
children: /* @__PURE__ */ v(m, {
|
|
407
410
|
type: "number",
|
|
408
411
|
min: 1,
|
|
409
412
|
placeholder: "No limit",
|
|
@@ -411,9 +414,9 @@ var be = [
|
|
|
411
414
|
onChange: (e) => Y("rateLimit", { requestsPerHour: e.target.value })
|
|
412
415
|
})
|
|
413
416
|
}),
|
|
414
|
-
/* @__PURE__ */ v(
|
|
417
|
+
/* @__PURE__ */ v(p, {
|
|
415
418
|
label: "Tokens / Minute",
|
|
416
|
-
children: /* @__PURE__ */ v(
|
|
419
|
+
children: /* @__PURE__ */ v(m, {
|
|
417
420
|
type: "number",
|
|
418
421
|
min: 1,
|
|
419
422
|
placeholder: "No limit",
|
|
@@ -424,23 +427,23 @@ var be = [
|
|
|
424
427
|
]
|
|
425
428
|
})
|
|
426
429
|
})] }),
|
|
427
|
-
H.type === "RESPONSE" && /* @__PURE__ */ y(
|
|
430
|
+
H.type === "RESPONSE" && /* @__PURE__ */ y(o, { children: [/* @__PURE__ */ y(l, { children: [/* @__PURE__ */ y(u, {
|
|
428
431
|
className: "flex items-center gap-2",
|
|
429
432
|
children: [/* @__PURE__ */ v(w, { size: 18 }), "Model Usage Allowlist"]
|
|
430
|
-
}), /* @__PURE__ */ v(
|
|
433
|
+
}), /* @__PURE__ */ v(c, { children: "Agents in this workspace may only answer with models that match every active model policy. Leave both fields empty to allow all models." })] }), /* @__PURE__ */ y(s, {
|
|
431
434
|
className: "space-y-4",
|
|
432
|
-
children: [/* @__PURE__ */ v(
|
|
435
|
+
children: [/* @__PURE__ */ v(p, {
|
|
433
436
|
label: "Allowed Models",
|
|
434
437
|
description: "Comma-separated model IDs. End an entry with * to allow a prefix.",
|
|
435
|
-
children: /* @__PURE__ */ v(
|
|
438
|
+
children: /* @__PURE__ */ v(m, {
|
|
436
439
|
placeholder: "e.g., gpt-4o-mini, anthropic.claude-*",
|
|
437
440
|
value: K.response.allowedModels,
|
|
438
441
|
onChange: (e) => Y("response", { allowedModels: e.target.value })
|
|
439
442
|
})
|
|
440
|
-
}), /* @__PURE__ */ v(
|
|
443
|
+
}), /* @__PURE__ */ v(p, {
|
|
441
444
|
label: "Allowed Providers",
|
|
442
445
|
description: "Comma-separated provider types, e.g. OPENAI, ANTHROPIC, AWS_BEDROCK.",
|
|
443
|
-
children: /* @__PURE__ */ v(
|
|
446
|
+
children: /* @__PURE__ */ v(m, {
|
|
444
447
|
placeholder: "e.g., AWS_BEDROCK, ANTHROPIC",
|
|
445
448
|
value: K.response.allowedProviders,
|
|
446
449
|
onChange: (e) => Y("response", { allowedProviders: e.target.value })
|
|
@@ -452,7 +455,7 @@ var be = [
|
|
|
452
455
|
role: "alert",
|
|
453
456
|
children: q
|
|
454
457
|
}),
|
|
455
|
-
/* @__PURE__ */ v(
|
|
458
|
+
/* @__PURE__ */ v(o, { children: /* @__PURE__ */ v(s, {
|
|
456
459
|
className: "pt-6",
|
|
457
460
|
children: /* @__PURE__ */ y("div", {
|
|
458
461
|
className: "flex items-start gap-2",
|
|
@@ -460,7 +463,7 @@ var be = [
|
|
|
460
463
|
type: "checkbox",
|
|
461
464
|
id: "activate-on-create",
|
|
462
465
|
checked: X,
|
|
463
|
-
onChange: (e) =>
|
|
466
|
+
onChange: (e) => je(e.target.checked),
|
|
464
467
|
className: "mt-1 h-4 w-4"
|
|
465
468
|
}), /* @__PURE__ */ y("label", {
|
|
466
469
|
htmlFor: "activate-on-create",
|
|
@@ -478,32 +481,32 @@ var be = [
|
|
|
478
481
|
]
|
|
479
482
|
})
|
|
480
483
|
});
|
|
481
|
-
if (
|
|
484
|
+
if (we) return /* @__PURE__ */ v(i, {
|
|
482
485
|
title: "Loading...",
|
|
483
486
|
children: /* @__PURE__ */ v("div", { className: "h-96 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg" })
|
|
484
487
|
});
|
|
485
|
-
if (!F) return /* @__PURE__ */ v(
|
|
488
|
+
if (!F) return /* @__PURE__ */ v(i, {
|
|
486
489
|
title: "Policy Not Found",
|
|
487
490
|
children: /* @__PURE__ */ v(re, {
|
|
488
491
|
illustration: "empty-generic",
|
|
489
492
|
title: "Policy Not Found",
|
|
490
493
|
description: "This policy doesn't exist.",
|
|
491
|
-
action: /* @__PURE__ */ v(
|
|
494
|
+
action: /* @__PURE__ */ v(a, {
|
|
492
495
|
onClick: () => P("policies"),
|
|
493
496
|
children: "Back to Policies"
|
|
494
497
|
})
|
|
495
498
|
})
|
|
496
499
|
});
|
|
497
|
-
let Q =
|
|
498
|
-
return /* @__PURE__ */ v(
|
|
500
|
+
let Q = g(F.type, Se, "CONTENT"), $ = me(Q, F.config);
|
|
501
|
+
return /* @__PURE__ */ v(i, {
|
|
499
502
|
title: /* @__PURE__ */ y("div", {
|
|
500
503
|
className: "flex items-center gap-3",
|
|
501
504
|
children: [
|
|
502
|
-
/* @__PURE__ */ v(
|
|
505
|
+
/* @__PURE__ */ v(a, {
|
|
503
506
|
variant: "ghost",
|
|
504
507
|
size: "icon",
|
|
505
508
|
onClick: () => P("policies"),
|
|
506
|
-
children: /* @__PURE__ */ v(
|
|
509
|
+
children: /* @__PURE__ */ v(ve, { size: 20 })
|
|
507
510
|
}),
|
|
508
511
|
/* @__PURE__ */ v("div", {
|
|
509
512
|
className: "p-2 rounded-lg bg-action-primary-bg/10",
|
|
@@ -520,68 +523,77 @@ var be = [
|
|
|
520
523
|
}),
|
|
521
524
|
actions: /* @__PURE__ */ v("div", {
|
|
522
525
|
className: "flex gap-2",
|
|
523
|
-
children: z ? /* @__PURE__ */ y(
|
|
526
|
+
children: z ? /* @__PURE__ */ y(ge, { children: [/* @__PURE__ */ v(a, {
|
|
524
527
|
variant: "outline",
|
|
525
528
|
onClick: () => B(!1),
|
|
526
529
|
children: "Cancel"
|
|
527
|
-
}), /* @__PURE__ */ v(
|
|
530
|
+
}), /* @__PURE__ */ v(a, {
|
|
528
531
|
leftIcon: /* @__PURE__ */ v(T, { size: 16 }),
|
|
529
|
-
onClick:
|
|
532
|
+
onClick: Ne,
|
|
530
533
|
isLoading: R,
|
|
531
534
|
disabled: !W.name,
|
|
532
535
|
children: "Save Changes"
|
|
533
|
-
})] }) : /* @__PURE__ */ y(
|
|
534
|
-
/* @__PURE__ */ v(
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
536
|
+
})] }) : /* @__PURE__ */ y(ge, { children: [
|
|
537
|
+
/* @__PURE__ */ v(r, {
|
|
538
|
+
permission: n.POLICY_UPDATE,
|
|
539
|
+
children: /* @__PURE__ */ v(a, {
|
|
540
|
+
variant: Z ? "outline" : "default",
|
|
541
|
+
leftIcon: /* @__PURE__ */ v(be, { size: 16 }),
|
|
542
|
+
onClick: () => void Fe(),
|
|
543
|
+
isLoading: R,
|
|
544
|
+
children: Z ? "Deactivate" : "Activate"
|
|
545
|
+
})
|
|
540
546
|
}),
|
|
541
|
-
/* @__PURE__ */ v(
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
547
|
+
/* @__PURE__ */ v(r, {
|
|
548
|
+
permission: n.POLICY_UPDATE,
|
|
549
|
+
children: /* @__PURE__ */ v(a, {
|
|
550
|
+
variant: "outline",
|
|
551
|
+
leftIcon: /* @__PURE__ */ v(ye, { size: 16 }),
|
|
552
|
+
onClick: Ie,
|
|
553
|
+
children: "Edit"
|
|
554
|
+
})
|
|
546
555
|
}),
|
|
547
|
-
|
|
556
|
+
ke ? /* @__PURE__ */ y("div", {
|
|
548
557
|
className: "flex gap-2",
|
|
549
|
-
children: [/* @__PURE__ */ v(
|
|
558
|
+
children: [/* @__PURE__ */ v(a, {
|
|
550
559
|
variant: "outline",
|
|
551
560
|
size: "sm",
|
|
552
561
|
onClick: () => V(!1),
|
|
553
562
|
children: "Cancel"
|
|
554
|
-
}), /* @__PURE__ */ v(
|
|
563
|
+
}), /* @__PURE__ */ v(a, {
|
|
555
564
|
variant: "destructive",
|
|
556
565
|
size: "sm",
|
|
557
566
|
onClick: () => {
|
|
558
|
-
ne("medium"),
|
|
567
|
+
ne("medium"), Pe();
|
|
559
568
|
},
|
|
560
|
-
isLoading:
|
|
569
|
+
isLoading: Oe,
|
|
561
570
|
children: "Confirm Delete"
|
|
562
571
|
})]
|
|
563
|
-
}) : /* @__PURE__ */ v(
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
572
|
+
}) : /* @__PURE__ */ v(r, {
|
|
573
|
+
permission: n.POLICY_DELETE,
|
|
574
|
+
children: /* @__PURE__ */ v(a, {
|
|
575
|
+
variant: "destructive",
|
|
576
|
+
leftIcon: /* @__PURE__ */ v(D, { size: 16 }),
|
|
577
|
+
onClick: () => V(!0),
|
|
578
|
+
children: "Delete"
|
|
579
|
+
})
|
|
568
580
|
})
|
|
569
581
|
] })
|
|
570
582
|
}),
|
|
571
583
|
children: /* @__PURE__ */ y("div", {
|
|
572
584
|
className: "space-y-6",
|
|
573
585
|
children: [
|
|
574
|
-
/* @__PURE__ */ v(
|
|
586
|
+
/* @__PURE__ */ v(he, {
|
|
575
587
|
icon: /* @__PURE__ */ v(E, { size: 18 }),
|
|
576
588
|
children: "This is a single guardrail and its rules. Review and tune exactly what it enforces — what content to block, which tools are allowed, the spend or rate limits it applies — then attach it to the agents and bots that should obey it. Policies are how you keep agents safe, compliant and within budget."
|
|
577
589
|
}),
|
|
578
|
-
z && /* @__PURE__ */ y(
|
|
590
|
+
z && /* @__PURE__ */ y(o, { children: [/* @__PURE__ */ v(l, { children: /* @__PURE__ */ v(u, { children: "Edit Policy" }) }), /* @__PURE__ */ y(s, {
|
|
579
591
|
className: "space-y-4",
|
|
580
592
|
children: [
|
|
581
|
-
/* @__PURE__ */ v(
|
|
593
|
+
/* @__PURE__ */ v(p, {
|
|
582
594
|
label: "Policy Name",
|
|
583
595
|
required: !0,
|
|
584
|
-
children: /* @__PURE__ */ v(
|
|
596
|
+
children: /* @__PURE__ */ v(m, {
|
|
585
597
|
value: W.name,
|
|
586
598
|
onChange: (e) => G({
|
|
587
599
|
...W,
|
|
@@ -589,9 +601,9 @@ var be = [
|
|
|
589
601
|
})
|
|
590
602
|
})
|
|
591
603
|
}),
|
|
592
|
-
/* @__PURE__ */ v(
|
|
604
|
+
/* @__PURE__ */ v(p, {
|
|
593
605
|
label: "Description",
|
|
594
|
-
children: /* @__PURE__ */ v(
|
|
606
|
+
children: /* @__PURE__ */ v(h, {
|
|
595
607
|
value: W.description,
|
|
596
608
|
onChange: (e) => G({
|
|
597
609
|
...W,
|
|
@@ -600,7 +612,7 @@ var be = [
|
|
|
600
612
|
rows: 3
|
|
601
613
|
})
|
|
602
614
|
}),
|
|
603
|
-
/* @__PURE__ */ v(
|
|
615
|
+
/* @__PURE__ */ v(p, {
|
|
604
616
|
label: "Visibility",
|
|
605
617
|
children: /* @__PURE__ */ y("select", {
|
|
606
618
|
className: A,
|
|
@@ -634,10 +646,10 @@ var be = [
|
|
|
634
646
|
/* @__PURE__ */ y("div", {
|
|
635
647
|
className: "grid grid-cols-2 md:grid-cols-4 gap-4",
|
|
636
648
|
children: [
|
|
637
|
-
/* @__PURE__ */ v(
|
|
649
|
+
/* @__PURE__ */ v(o, {
|
|
638
650
|
treatment: "glass",
|
|
639
651
|
glow: !0,
|
|
640
|
-
children: /* @__PURE__ */ y(
|
|
652
|
+
children: /* @__PURE__ */ y(s, {
|
|
641
653
|
className: "pt-6 text-center",
|
|
642
654
|
children: [
|
|
643
655
|
/* @__PURE__ */ v("div", {
|
|
@@ -655,7 +667,7 @@ var be = [
|
|
|
655
667
|
]
|
|
656
668
|
})
|
|
657
669
|
}),
|
|
658
|
-
/* @__PURE__ */ v(
|
|
670
|
+
/* @__PURE__ */ v(o, { children: /* @__PURE__ */ y(s, {
|
|
659
671
|
className: "pt-6 text-center",
|
|
660
672
|
children: [/* @__PURE__ */ v("p", {
|
|
661
673
|
className: "text-3xl font-bold text-text-primary capitalize",
|
|
@@ -665,7 +677,7 @@ var be = [
|
|
|
665
677
|
children: "Visibility"
|
|
666
678
|
})]
|
|
667
679
|
}) }),
|
|
668
|
-
/* @__PURE__ */ v(
|
|
680
|
+
/* @__PURE__ */ v(o, { children: /* @__PURE__ */ y(s, {
|
|
669
681
|
className: "pt-6 text-center",
|
|
670
682
|
children: [/* @__PURE__ */ v("p", {
|
|
671
683
|
className: "text-3xl font-bold text-text-primary",
|
|
@@ -675,7 +687,7 @@ var be = [
|
|
|
675
687
|
children: "Revision"
|
|
676
688
|
})]
|
|
677
689
|
}) }),
|
|
678
|
-
/* @__PURE__ */ v(
|
|
690
|
+
/* @__PURE__ */ v(o, { children: /* @__PURE__ */ y(s, {
|
|
679
691
|
className: "pt-6 text-center",
|
|
680
692
|
children: [/* @__PURE__ */ v("p", {
|
|
681
693
|
className: "text-lg font-bold text-text-primary",
|
|
@@ -687,7 +699,7 @@ var be = [
|
|
|
687
699
|
}) })
|
|
688
700
|
]
|
|
689
701
|
}),
|
|
690
|
-
/* @__PURE__ */ y(
|
|
702
|
+
/* @__PURE__ */ y(o, { children: [/* @__PURE__ */ y(l, { children: [/* @__PURE__ */ v(u, { children: "Configuration" }), /* @__PURE__ */ v(c, { children: "Current policy configuration" })] }), /* @__PURE__ */ y(s, {
|
|
691
703
|
className: "space-y-4",
|
|
692
704
|
children: [$ === null ? /* @__PURE__ */ y("div", {
|
|
693
705
|
className: "flex items-start gap-2 p-3 bg-status-warning-bg-subtle rounded-lg text-sm",
|
|
@@ -716,10 +728,10 @@ var be = [
|
|
|
716
728
|
children: /* @__PURE__ */ v("pre", { children: JSON.stringify(F.config, null, 2) })
|
|
717
729
|
})]
|
|
718
730
|
})] }),
|
|
719
|
-
/* @__PURE__ */ y(
|
|
731
|
+
/* @__PURE__ */ y(o, { children: [/* @__PURE__ */ v(l, { children: /* @__PURE__ */ y(u, {
|
|
720
732
|
className: "flex items-center gap-2",
|
|
721
|
-
children: [/* @__PURE__ */ v(
|
|
722
|
-
}) }), /* @__PURE__ */ v(
|
|
733
|
+
children: [/* @__PURE__ */ v(xe, { size: 18 }), "Metadata"]
|
|
734
|
+
}) }), /* @__PURE__ */ v(s, { children: /* @__PURE__ */ y("div", {
|
|
723
735
|
className: "grid grid-cols-2 md:grid-cols-4 gap-6 text-sm",
|
|
724
736
|
children: [
|
|
725
737
|
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("p", {
|