Skip to content

Commit 3017c5f

Browse files
authored
fix: rename ai gateway (#127)
1 parent f5b655c commit 3017c5f

11 files changed

Lines changed: 111 additions & 156 deletions

src/commands/gateway-config/list.tsx

Lines changed: 20 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -210,13 +210,13 @@ const ListGatewayConfigsUI = ({
210210
},
211211
{
212212
key: "edit",
213-
label: "Edit AI Gateway Config",
213+
label: "Edit Agent Gateway Config",
214214
color: colors.warning,
215215
icon: figures.pointer,
216216
},
217217
{
218218
key: "delete",
219-
label: "Delete AI Gateway Config",
219+
label: "Delete Agent Gateway Config",
220220
color: colors.error,
221221
icon: figures.cross,
222222
},
@@ -320,7 +320,7 @@ const ListGatewayConfigsUI = ({
320320
case "delete":
321321
await client.gatewayConfigs.delete(config.id);
322322
setOperationResult(
323-
`AI gateway config "${config.name}" deleted successfully`,
323+
`Agent gateway config "${config.name}" deleted successfully`,
324324
);
325325
break;
326326
}
@@ -500,11 +500,11 @@ const ListGatewayConfigsUI = ({
500500
if (showDeleteConfirm && selectedConfig) {
501501
return (
502502
<ConfirmationPrompt
503-
title="Delete AI Gateway Config"
503+
title="Delete Agent Gateway Config"
504504
message={`Are you sure you want to delete "${selectedConfig.name}"?`}
505-
details="This action cannot be undone. Any devboxes using this AI gateway config will no longer have access to it."
505+
details="This action cannot be undone. Any devboxes using this Agent gateway config will no longer have access to it."
506506
breadcrumbItems={[
507-
{ label: "AI Gateway Configs" },
507+
{ label: "Agent Gateway Configs" },
508508
{ label: selectedConfig.name || selectedConfig.id },
509509
{ label: "Delete", active: true },
510510
]}
@@ -530,7 +530,7 @@ const ListGatewayConfigsUI = ({
530530
<>
531531
<Breadcrumb
532532
items={[
533-
{ label: "AI Gateway Configs" },
533+
{ label: "Agent Gateway Configs" },
534534
{
535535
label: selectedConfig?.name || selectedConfig?.id || "Config",
536536
},
@@ -553,13 +553,13 @@ const ListGatewayConfigsUI = ({
553553
operations.find((o) => o.key === executingOperation)?.label ||
554554
"Operation";
555555
const messages: Record<string, string> = {
556-
delete: "Deleting AI gateway config...",
556+
delete: "Deleting Agent gateway config...",
557557
};
558558
return (
559559
<>
560560
<Breadcrumb
561561
items={[
562-
{ label: "AI Gateway Configs" },
562+
{ label: "Agent Gateway Configs" },
563563
{ label: selectedConfig.name || selectedConfig.id },
564564
{ label: operationLabel, active: true },
565565
]}
@@ -608,8 +608,10 @@ const ListGatewayConfigsUI = ({
608608
if (loading && configs.length === 0) {
609609
return (
610610
<>
611-
<Breadcrumb items={[{ label: "AI Gateway Configs", active: true }]} />
612-
<SpinnerComponent message="Loading AI gateway configs..." />
611+
<Breadcrumb
612+
items={[{ label: "Agent Gateway Configs", active: true }]}
613+
/>
614+
<SpinnerComponent message="Loading Agent gateway configs..." />
613615
</>
614616
);
615617
}
@@ -618,9 +620,11 @@ const ListGatewayConfigsUI = ({
618620
if (error) {
619621
return (
620622
<>
621-
<Breadcrumb items={[{ label: "AI Gateway Configs", active: true }]} />
623+
<Breadcrumb
624+
items={[{ label: "Agent Gateway Configs", active: true }]}
625+
/>
622626
<ErrorMessage
623-
message="Failed to list AI gateway configs"
627+
message="Failed to list Agent gateway configs"
624628
error={error}
625629
/>
626630
</>
@@ -630,7 +634,7 @@ const ListGatewayConfigsUI = ({
630634
// Main list view
631635
return (
632636
<>
633-
<Breadcrumb items={[{ label: "AI Gateway Configs", active: true }]} />
637+
<Breadcrumb items={[{ label: "Agent Gateway Configs", active: true }]} />
634638

635639
{/* Search bar */}
636640
<SearchBar
@@ -640,7 +644,7 @@ const ListGatewayConfigsUI = ({
640644
resultCount={totalCount}
641645
onSearchChange={search.setSearchQuery}
642646
onSearchSubmit={search.submitSearch}
643-
placeholder="Search AI gateway configs..."
647+
placeholder="Search Agent gateway configs..."
644648
/>
645649

646650
{/* Table - hide when popup is shown */}
@@ -653,7 +657,7 @@ const ListGatewayConfigsUI = ({
653657
columns={columns}
654658
emptyState={
655659
<Text color={colors.textDim}>
656-
{figures.info} No AI gateway configs found. Press [c] to create
660+
{figures.info} No Agent gateway configs found. Press [c] to create
657661
one.
658662
</Text>
659663
}

src/commands/network-policy/create.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ interface CreateOptions {
1010
description?: string;
1111
allowAll?: boolean;
1212
allowDevboxToDevbox?: boolean;
13-
allowAiGateway?: boolean;
13+
allowAgentGateway?: boolean;
1414
allowMcpGateway?: boolean;
1515
allowedHostnames?: string[];
1616
output?: string;
@@ -25,7 +25,7 @@ export async function createNetworkPolicy(options: CreateOptions) {
2525
description: options.description,
2626
allow_all: options.allowAll ?? false,
2727
allow_devbox_to_devbox: options.allowDevboxToDevbox ?? false,
28-
allow_ai_gateway: options.allowAiGateway ?? false,
28+
allow_ai_gateway: options.allowAgentGateway ?? false,
2929
allow_mcp_gateway: options.allowMcpGateway ?? false,
3030
allowed_hostnames: options.allowedHostnames ?? [],
3131
});

src/components/DevboxCreatePage.tsx

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ export const DevboxCreatePage = ({
313313
},
314314
{
315315
key: "gateways",
316-
label: "AI Gateway Configs (optional)",
316+
label: "Agent Gateway Configs (optional)",
317317
type: "gateways",
318318
placeholder: "Configure API credential proxying...",
319319
},
@@ -1496,7 +1496,7 @@ export const DevboxCreatePage = ({
14961496
<ResourcePicker<GatewayConfig>
14971497
key="gateway-config-picker"
14981498
config={{
1499-
title: "Select AI Gateway Config",
1499+
title: "Select Agent Gateway Config",
15001500
fetchPage: async (params) => {
15011501
const result = await listGatewayConfigs({
15021502
limit: params.limit,
@@ -1513,19 +1513,19 @@ export const DevboxCreatePage = ({
15131513
getItemLabel: (config) => config.name || config.id,
15141514
columns: buildGatewayColumns,
15151515
mode: "single",
1516-
emptyMessage: "No AI gateway configs found",
1517-
searchPlaceholder: "Search AI gateway configs...",
1516+
emptyMessage: "No Agent gateway configs found",
1517+
searchPlaceholder: "Search Agent gateway configs...",
15181518
breadcrumbItems: [
15191519
{ label: "Devboxes" },
15201520
{ label: "Create" },
1521-
{ label: "Attach AI Gateway Config" },
1521+
{ label: "Attach Agent Gateway Config" },
15221522
{ label: "Select Config", active: true },
15231523
],
15241524
onCreateNew: () => {
15251525
setShowGatewayPicker(false);
15261526
setShowInlineGatewayConfigCreate(true);
15271527
},
1528-
createNewLabel: "Create AI gateway config",
1528+
createNewLabel: "Create Agent gateway config",
15291529
}}
15301530
onSelect={handleGatewaySelect}
15311531
onCancel={() => {
@@ -1635,7 +1635,7 @@ export const DevboxCreatePage = ({
16351635
breadcrumbItems: [
16361636
{ label: "Devboxes" },
16371637
{ label: "Create" },
1638-
{ label: "Attach AI Gateway Config" },
1638+
{ label: "Attach Agent Gateway Config" },
16391639
{ label: "Select Secret", active: true },
16401640
],
16411641
onCreateNew: () => {
@@ -2312,7 +2312,7 @@ export const DevboxCreatePage = ({
23122312
marginBottom={1}
23132313
>
23142314
<Text color={colors.primary} bold>
2315-
{figures.hamburger} Configure AI Gateway Configs for Devbox
2315+
{figures.hamburger} Configure Agent Gateway Configs for Devbox
23162316
</Text>
23172317

23182318
{/* Attach form - shown when configuring a new gateway */}
@@ -2325,7 +2325,7 @@ export const DevboxCreatePage = ({
23252325
paddingX={1}
23262326
>
23272327
<Text color={colors.success} bold>
2328-
Attach AI Gateway Config
2328+
Attach Agent Gateway Config
23292329
</Text>
23302330

23312331
{/* Attach button */}
@@ -2369,7 +2369,7 @@ export const DevboxCreatePage = ({
23692369
}
23702370
>
23712371
{gatewayFormField === "gateway" ? figures.pointer : " "}{" "}
2372-
AI Gateway Config:{" "}
2372+
Agent Gateway Config:{" "}
23732373
</Text>
23742374
{pendingGateway ? (
23752375
<Text color={colors.success}>
@@ -2492,7 +2492,7 @@ export const DevboxCreatePage = ({
24922492
}
24932493
bold={selectedGatewayIndex === 0}
24942494
>
2495-
+ Attach AI gateway config
2495+
+ Attach Agent gateway config
24962496
</Text>
24972497
</Box>
24982498

src/components/GatewayConfigCreatePage.tsx

Lines changed: 17 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -90,8 +90,8 @@ export const GatewayConfigCreatePage = ({
9090
{
9191
key: "create",
9292
label: isEditing
93-
? "Update AI Gateway Config"
94-
: "Create AI Gateway Config",
93+
? "Update Agent Gateway Config"
94+
: "Create Agent Gateway Config",
9595
type: "action",
9696
},
9797
{
@@ -298,18 +298,21 @@ export const GatewayConfigCreatePage = ({
298298
}
299299
};
300300

301+
const breadcrumbItems = isEditing
302+
? [
303+
{ label: "Agent Gateway Configs" },
304+
{ label: initialConfig?.name || initialConfig?.id || "Config" },
305+
{ label: "Update", active: true },
306+
]
307+
: [{ label: "Agent Gateway Configs" }, { label: "Create", active: true }];
308+
301309
// Result screen
302310
if (result) {
303311
return (
304312
<>
305-
<Breadcrumb
306-
items={[
307-
{ label: "AI Gateway Configs" },
308-
{ label: isEditing ? "Update" : "Create", active: true },
309-
]}
310-
/>
313+
<Breadcrumb items={breadcrumbItems} />
311314
<SuccessMessage
312-
message={`AI gateway config ${isEditing ? "updated" : "created"} successfully!`}
315+
message={`Agent gateway config ${isEditing ? "updated" : "created"} successfully!`}
313316
/>
314317
<Box marginLeft={2} flexDirection="column" marginTop={1}>
315318
<Box>
@@ -340,14 +343,9 @@ export const GatewayConfigCreatePage = ({
340343
if (error) {
341344
return (
342345
<>
343-
<Breadcrumb
344-
items={[
345-
{ label: "AI Gateway Configs" },
346-
{ label: isEditing ? "Update" : "Create", active: true },
347-
]}
348-
/>
346+
<Breadcrumb items={breadcrumbItems} />
349347
<ErrorMessage
350-
message={`Failed to ${isEditing ? "update" : "create"} AI gateway config`}
348+
message={`Failed to ${isEditing ? "update" : "create"} Agent gateway config`}
351349
error={error}
352350
/>
353351
<NavigationTips
@@ -364,14 +362,9 @@ export const GatewayConfigCreatePage = ({
364362
if (creating) {
365363
return (
366364
<>
367-
<Breadcrumb
368-
items={[
369-
{ label: "AI Gateway Configs" },
370-
{ label: isEditing ? "Update" : "Create", active: true },
371-
]}
372-
/>
365+
<Breadcrumb items={breadcrumbItems} />
373366
<SpinnerComponent
374-
message={`${isEditing ? "Updating" : "Creating"} AI gateway config...`}
367+
message={`${isEditing ? "Updating" : "Creating"} Agent gateway config...`}
375368
/>
376369
</>
377370
);
@@ -380,12 +373,7 @@ export const GatewayConfigCreatePage = ({
380373
// Form screen
381374
return (
382375
<>
383-
<Breadcrumb
384-
items={[
385-
{ label: "AI Gateway Configs" },
386-
{ label: isEditing ? "Update" : "Create", active: true },
387-
]}
388-
/>
376+
<Breadcrumb items={breadcrumbItems} />
389377

390378
<Box flexDirection="column" marginBottom={1}>
391379
{fields.map((field) => {

src/components/McpConfigCreatePage.tsx

Lines changed: 12 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -209,15 +209,18 @@ export const McpConfigCreatePage = ({
209209
}
210210
};
211211

212+
const breadcrumbItems = isEditing
213+
? [
214+
{ label: "MCP Configs" },
215+
{ label: initialConfig?.name || initialConfig?.id || "Config" },
216+
{ label: "Update", active: true },
217+
]
218+
: [{ label: "MCP Configs" }, { label: "Create", active: true }];
219+
212220
if (result) {
213221
return (
214222
<>
215-
<Breadcrumb
216-
items={[
217-
{ label: "MCP Configs" },
218-
{ label: isEditing ? "Update" : "Create", active: true },
219-
]}
220-
/>
223+
<Breadcrumb items={breadcrumbItems} />
221224
<SuccessMessage
222225
message={`MCP config ${isEditing ? "updated" : "created"} successfully!`}
223226
/>
@@ -254,12 +257,7 @@ export const McpConfigCreatePage = ({
254257
if (error) {
255258
return (
256259
<>
257-
<Breadcrumb
258-
items={[
259-
{ label: "MCP Configs" },
260-
{ label: isEditing ? "Update" : "Create", active: true },
261-
]}
262-
/>
260+
<Breadcrumb items={breadcrumbItems} />
263261
<ErrorMessage
264262
message={`Failed to ${isEditing ? "update" : "create"} MCP config`}
265263
error={error}
@@ -277,12 +275,7 @@ export const McpConfigCreatePage = ({
277275
if (creating) {
278276
return (
279277
<>
280-
<Breadcrumb
281-
items={[
282-
{ label: "MCP Configs" },
283-
{ label: isEditing ? "Update" : "Create", active: true },
284-
]}
285-
/>
278+
<Breadcrumb items={breadcrumbItems} />
286279
<SpinnerComponent
287280
message={`${isEditing ? "Updating" : "Creating"} MCP config...`}
288281
/>
@@ -292,12 +285,7 @@ export const McpConfigCreatePage = ({
292285

293286
return (
294287
<>
295-
<Breadcrumb
296-
items={[
297-
{ label: "MCP Configs" },
298-
{ label: isEditing ? "Update" : "Create", active: true },
299-
]}
300-
/>
288+
<Breadcrumb items={breadcrumbItems} />
301289

302290
<Box flexDirection="column" marginBottom={1}>
303291
{fields.map((field) => {

0 commit comments

Comments
 (0)