Unified · Split
| @@ -1172,6 +1172,7 @@ export function AddSourcePage() { · 1171 unmodified lines | |||
| 1172 | <> | 1172 | <> |
| 1173 | <Field label="OAuth client ID" className="sm:col-span-2"> | 1173 | <Field label="OAuth client ID" className="sm:col-span-2"> |
| 1174 | <TextInput | 1174 | <TextInput |
| 1175 | type="password" | ||
| 1175 | value={connectForm.oauthClientId} | 1176 | value={connectForm.oauthClientId} |
| 1176 | onChange={(v) => setFormField("oauthClientId", v)} | 1177 | onChange={(v) => setFormField("oauthClientId", v)} |
| 1177 | placeholder="1234567890-abcdef.apps.googleusercontent.com" | 1178 | placeholder="1234567890-abcdef.apps.googleusercontent.com" |
| @@ -1179,6 +1180,7 @@ export function AddSourcePage() { · 1 unmodified line | |||
| 1179 | </Field> | 1180 | </Field> |
| 1180 | <Field label="OAuth client secret" className="sm:col-span-2"> | 1181 | <Field label="OAuth client secret" className="sm:col-span-2"> |
| 1181 | <TextInput | 1182 | <TextInput |
| 1183 | type="password" | ||
| 1182 | value={connectForm.oauthClientSecret} | 1184 | value={connectForm.oauthClientSecret} |
| 1183 | onChange={(v) => setFormField("oauthClientSecret", v)} | 1185 | onChange={(v) => setFormField("oauthClientSecret", v)} |
| 1184 | placeholder="GOCSPX-..." | 1186 | placeholder="GOCSPX-..." |
| @@ -1324,6 +1326,7 @@ function Field(props: { · 139 unmodified lines | |||
| 1324 | } | 1326 | } |
| 1325 | 1327 | ||
| 1326 | function TextInput(props: { | 1328 | function TextInput(props: { |
| 1329 | type?: "text" | "password"; | ||
| 1327 | value: string; | 1330 | value: string; |
| 1328 | onChange: (value: string) => void; | 1331 | onChange: (value: string) => void; |
| 1329 | placeholder?: string; | 1332 | placeholder?: string; |
| @@ -1331,6 +1334,7 @@ function TextInput(props: { · 1 unmodified line | |||
| 1331 | }) { | 1334 | }) { |
| 1332 | return ( | 1335 | return ( |
| 1333 | <input | 1336 | <input |
| 1337 | type={props.type || "text"} | ||
| 1334 | value={props.value} | 1338 | value={props.value} |
| 1335 | onChange={(event) => props.onChange(event.target.value)} | 1339 | onChange={(event) => props.onChange(event.target.value)} |
| 1336 | placeholder={props.placeholder} | 1340 | placeholder={props.placeholder} |
| @@ -6,7 +6,7 @@ · 5 unmodified lines | |||
| 6 | "workspaces": [ | 6 | "workspaces": [ |
| 7 | "packages/*", | 7 | "packages/*", |
| 8 | "apps/*", | 8 | "apps/*", |
| 9 | "docs" | 9 | "apps/docs" |
| 10 | ], | 10 | ], |
| 11 | "catalog": { | 11 | "catalog": { |
| 12 | "@effect/cli": "^0.73.2", | 12 | "@effect/cli": "^0.73.2", |
| @@ -9,11 +9,11 @@ import { · 8 unmodified lines | |||
| 9 | const asToolPath = (value: string): ToolPath => value as ToolPath; | 9 | const asToolPath = (value: string): ToolPath => value as ToolPath; |
| 10 | 10 | ||
| 11 | const catalog: ToolCatalog = { | 11 | const catalog: ToolCatalog = { |
| 12 | listNamespaces() { | 12 | listNamespaces({ limit }) { |
| 13 | return Effect.succeed([ | 13 | return Effect.succeed([ |
| 14 | { namespace: "src_api", displayName: "API Sources", toolCount: 6800 }, | 14 | { namespace: "src_api", displayName: "API Sources", toolCount: 6800 }, |
| 15 | { namespace: "src_mcp", displayName: "MCP Sources", toolCount: 3200 }, | 15 | { namespace: "src_mcp", displayName: "MCP Sources", toolCount: 3200 }, |
| 16 | ]); | 16 | ].slice(0, limit)); |
| 17 | }, | 17 | }, |
| 18 | listTools({ namespace }) { | 18 | listTools({ namespace }) { |
| 19 | return Effect.succeed([ | 19 | return Effect.succeed([ |
| @@ -35,6 +35,9 @@ const catalog: ToolCatalog = { · 15 unmodified lines | |||
| 35 | outputType: "object", | 35 | outputType: "object", |
| 36 | }); | 36 | }); |
| 37 | }, | 37 | }, |
| 38 | getSchemaBundle() { | ||
| 39 | return Effect.succeed(null); | ||
| 40 | }, | ||
| 38 | searchTools({ limit }) { | 41 | searchTools({ limit }) { |
| 39 | return Effect.succeed( | 42 | return Effect.succeed( |
| 40 | [ | 43 | [ |
| @@ -287,6 +287,10 @@ const resolveSourceCallContext = (input: { · 286 unmodified lines | |||
| 287 | return { auth: { kind: "none" } }; | 287 | return { auth: { kind: "none" } }; |
| 288 | } | 288 | } |
| 289 | 289 | ||
| 290 | if (source.auth.kind === "oauth2_authorized_user") { | ||
| 291 | throw new Error("oauth2_authorized_user auth requires persistence-backed runtime resolution"); | ||
| 292 | } | ||
| 293 | |||
| 290 | const tokenRef = source.auth.kind === "bearer" | 294 | const tokenRef = source.auth.kind === "bearer" |
| 291 | ? source.auth.token | 295 | ? source.auth.token |
| 292 | : source.auth.accessToken; | 296 | : source.auth.accessToken; |
| @@ -494,11 +498,11 @@ const openApiSource = (input: { · 201 unmodified lines | |||
| 494 | status: "connected", | 498 | status: "connected", |
| 495 | enabled: true, | 499 | enabled: true, |
| 496 | namespace: input.namespace ?? null, | 500 | namespace: input.namespace ?? null, |
| 497 | transport: null, | 501 | bindingVersion: 1, |
| 498 | queryParams: null, | 502 | binding: { |
| 499 | headers: null, | 503 | specUrl: input.specUrl ?? null, |
| 500 | specUrl: input.specUrl ?? null, | 504 | defaultHeaders: null, |
| 501 | defaultHeaders: null, | 505 | }, |
| 502 | importAuthPolicy: "reuse_runtime", | 506 | importAuthPolicy: "reuse_runtime", |
| 503 | importAuth: { kind: "none" }, | 507 | importAuth: { kind: "none" }, |
| 504 | auth: input.auth, | 508 | auth: input.auth, |