@axiom-lattice/gateway 2.1.36 → 2.1.37

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/index.mjs CHANGED
@@ -3383,12 +3383,14 @@ async function getDataSources(request, reply) {
3383
3383
  }
3384
3384
  const semanticConfig = config.config;
3385
3385
  const client = new SemanticMetricsClient(semanticConfig);
3386
- const datasources = await client.getDataSources();
3386
+ const allDatasources = await client.getDataSources();
3387
+ const selectedIds = semanticConfig.selectedDataSources || [];
3388
+ const filteredDatasources = selectedIds.length > 0 ? allDatasources.filter((ds) => selectedIds.includes(String(ds.id))) : allDatasources;
3387
3389
  return {
3388
3390
  success: true,
3389
3391
  message: "Data sources retrieved successfully",
3390
3392
  data: {
3391
- datasources
3393
+ datasources: filteredDatasources
3392
3394
  }
3393
3395
  };
3394
3396
  } catch (error) {