MCPcopy Index your code
hub / github.com/simstudioai/sim / fetchKnowledgeBases

Function fetchKnowledgeBases

apps/sim/hooks/queries/kb/knowledge.ts:88–99  ·  view source on GitHub ↗
(
  workspaceId?: string,
  scope: KnowledgeQueryScope = 'active',
  signal?: AbortSignal
)

Source from the content-addressed store, hash-verified

86}
87
88export async function fetchKnowledgeBases(
89 workspaceId?: string,
90 scope: KnowledgeQueryScope = 'active',
91 signal?: AbortSignal
92): Promise<KnowledgeBaseData[]> {
93 const result = await requestJson(listKnowledgeBasesContract, {
94 query: { workspaceId, scope },
95 signal,
96 })
97
98 return result.data
99}
100
101export async function fetchKnowledgeBase(
102 knowledgeBaseId: string,

Calls 1

requestJsonFunction · 0.90

Tested by

no test coverage detected