(kind: string, data: Record<string, unknown>)
| 352 | pluginId === "graphql-greenfield" ? "graphql" : pluginId || kind; |
| 353 | |
| 354 | const buildConfig = (kind: string, data: Record<string, unknown>): MigratedSourceConfig => { |
| 355 | const cfg = (data.config as Record<string, unknown> | undefined) ?? data; |
| 356 | if (kind === "mcp") return migrateMcpSourceConfig(cfg as never); |
| 357 | if (kind === "graphql") return migrateGraphqlSourceConfig(cfg as never); |
| 358 | return migrateOpenApiSourceConfig(cfg as never); |
| 359 | }; |
| 360 | |
| 361 | const isObjectRecord = (value: unknown): value is Record<string, unknown> => |
| 362 | typeof value === "object" && value !== null && !Array.isArray(value); |
no test coverage detected