Skip to content

Commit d0dd12c

Browse files
fix(server): address runtime auth review feedback
1 parent 4b778e3 commit d0dd12c

15 files changed

Lines changed: 201 additions & 248 deletions

sdks/typescript/src/generated/models/index.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,6 @@ export * from "./init-agent-evaluator-removal.js";
6363
export * from "./init-agent-overwrite-changes.js";
6464
export * from "./init-agent-request.js";
6565
export * from "./init-agent-response.js";
66-
export * from "./json-value-input.js";
67-
export * from "./json-value-input1.js";
68-
export * from "./json-value-output.js";
69-
export * from "./json-value-output1.js";
7066
export * from "./list-agents-response.js";
7167
export * from "./list-control-bindings-response.js";
7268
export * from "./list-control-versions-response.js";

sdks/typescript/src/generated/models/json-value-input.ts

Lines changed: 0 additions & 40 deletions
This file was deleted.

sdks/typescript/src/generated/models/json-value-input1.ts

Lines changed: 0 additions & 47 deletions
This file was deleted.

sdks/typescript/src/generated/models/json-value-output.ts

Lines changed: 0 additions & 44 deletions
This file was deleted.

sdks/typescript/src/generated/models/json-value-output1.ts

Lines changed: 0 additions & 48 deletions
This file was deleted.

sdks/typescript/src/generated/models/step.ts

Lines changed: 12 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,6 @@
33
*/
44

55
import * as z from "zod/v4-mini";
6-
import {
7-
JSONValueInput,
8-
JSONValueInput$Outbound,
9-
JSONValueInput$outboundSchema,
10-
} from "./json-value-input.js";
116

127
/**
138
* Runtime payload for an agent step invocation.
@@ -16,16 +11,19 @@ export type Step = {
1611
/**
1712
* Optional context (conversation history, metadata, etc.)
1813
*/
19-
context?: { [k: string]: JSONValueInput | null } | null | undefined;
20-
input: JSONValueInput | null;
14+
context?: { [k: string]: any } | null | undefined;
15+
/**
16+
* Any JSON value
17+
*/
18+
input: any;
2119
/**
2220
* Step name (tool name or model/chain id)
2321
*/
2422
name: string;
2523
/**
2624
* Output content for this step (None for pre-checks)
2725
*/
28-
output?: JSONValueInput | null | undefined;
26+
output?: any | null | undefined;
2927
/**
3028
* Step type (e.g., 'tool', 'llm')
3129
*/
@@ -34,24 +32,20 @@ export type Step = {
3432

3533
/** @internal */
3634
export type Step$Outbound = {
37-
context?: { [k: string]: JSONValueInput$Outbound | null } | null | undefined;
38-
input: JSONValueInput$Outbound | null;
35+
context?: { [k: string]: any } | null | undefined;
36+
input: any;
3937
name: string;
40-
output?: JSONValueInput$Outbound | null | undefined;
38+
output?: any | null | undefined;
4139
type: string;
4240
};
4341

4442
/** @internal */
4543
export const Step$outboundSchema: z.ZodMiniType<Step$Outbound, Step> = z.object(
4644
{
47-
context: z.optional(
48-
z.nullable(
49-
z.record(z.string(), z.nullable(JSONValueInput$outboundSchema)),
50-
),
51-
),
52-
input: z.nullable(JSONValueInput$outboundSchema),
45+
context: z.optional(z.nullable(z.record(z.string(), z.any()))),
46+
input: z.any(),
5347
name: z.string(),
54-
output: z.optional(z.nullable(JSONValueInput$outboundSchema)),
48+
output: z.optional(z.nullable(z.any())),
5549
type: z.string(),
5650
},
5751
);

sdks/typescript/src/generated/models/template-definition-input.ts

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,6 @@
44

55
import * as z from "zod/v4-mini";
66
import { remap as remap$ } from "../lib/primitives.js";
7-
import {
8-
JsonValueInput1,
9-
JsonValueInput1$Outbound,
10-
JsonValueInput1$outboundSchema,
11-
} from "./json-value-input1.js";
127
import {
138
TemplateParameterDefinition,
149
TemplateParameterDefinition$Outbound,
@@ -19,7 +14,10 @@ import {
1914
* Reusable template with typed parameters and a JSON definition template.
2015
*/
2116
export type TemplateDefinitionInput = {
22-
definitionTemplate: JsonValueInput1 | null;
17+
/**
18+
* Any JSON value
19+
*/
20+
definitionTemplate: any;
2321
/**
2422
* Metadata describing the template itself
2523
*/
@@ -32,7 +30,7 @@ export type TemplateDefinitionInput = {
3230

3331
/** @internal */
3432
export type TemplateDefinitionInput$Outbound = {
35-
definition_template: JsonValueInput1$Outbound | null;
33+
definition_template: any;
3634
description?: string | null | undefined;
3735
parameters?:
3836
| { [k: string]: TemplateParameterDefinition$Outbound }
@@ -45,7 +43,7 @@ export const TemplateDefinitionInput$outboundSchema: z.ZodMiniType<
4543
TemplateDefinitionInput
4644
> = z.pipe(
4745
z.object({
48-
definitionTemplate: z.nullable(JsonValueInput1$outboundSchema),
46+
definitionTemplate: z.any(),
4947
description: z.optional(z.nullable(z.string())),
5048
parameters: z.optional(
5149
z.record(z.string(), TemplateParameterDefinition$outboundSchema),

sdks/typescript/src/generated/models/template-definition-output.ts

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,6 @@ import { safeParse } from "../lib/schemas.js";
88
import { Result as SafeParseResult } from "../types/fp.js";
99
import * as types from "../types/primitives.js";
1010
import { SDKValidationError } from "./errors/sdk-validation-error.js";
11-
import {
12-
JsonValueOutput1,
13-
JsonValueOutput1$inboundSchema,
14-
} from "./json-value-output1.js";
1511
import {
1612
TemplateParameterDefinition,
1713
TemplateParameterDefinition$inboundSchema,
@@ -21,7 +17,10 @@ import {
2117
* Reusable template with typed parameters and a JSON definition template.
2218
*/
2319
export type TemplateDefinitionOutput = {
24-
definitionTemplate: JsonValueOutput1 | null;
20+
/**
21+
* Any JSON value
22+
*/
23+
definitionTemplate: any;
2524
/**
2625
* Metadata describing the template itself
2726
*/
@@ -38,7 +37,7 @@ export const TemplateDefinitionOutput$inboundSchema: z.ZodMiniType<
3837
unknown
3938
> = z.pipe(
4039
z.object({
41-
definition_template: types.nullable(JsonValueOutput1$inboundSchema),
40+
definition_template: z.any(),
4241
description: z.optional(z.nullable(types.string())),
4342
parameters: types.optional(
4443
z.record(z.string(), TemplateParameterDefinition$inboundSchema),

server/src/agent_control_server/auth_framework/config.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,8 @@ def _build_default_provider() -> RequestAuthorizer:
218218
)
219219
)
220220
raise RuntimeError(
221-
f"Unknown {_MODE_ENV}={mode!r}; expected 'none', 'api_key', or 'http_upstream'."
221+
f"Unknown {_MODE_ENV}={mode!r}; expected 'none', 'api_key', 'header', "
222+
"or 'http_upstream'."
222223
)
223224

224225

@@ -259,7 +260,8 @@ def _resolve_runtime_mode() -> str:
259260
if mode == "jwt":
260261
return mode
261262
raise RuntimeError(
262-
f"Unknown {_RUNTIME_MODE_ENV}={mode!r}; expected 'none', 'api_key', or 'jwt'."
263+
f"Unknown {_RUNTIME_MODE_ENV}={mode!r}; expected 'none', 'api_key', "
264+
"'header', or 'jwt'."
263265
)
264266

265267

0 commit comments

Comments
 (0)