MCPcopy Create free account
hub / github.com/simstudioai/sim / addChatResource

Function addChatResource

apps/sim/hooks/queries/mothership-chats.ts:350–358  ·  view source on GitHub ↗
(params: {
  chatId: string
  resource: MothershipResource
})

Source from the content-addressed store, hash-verified

348}
349
350async function addChatResource(params: {
351 chatId: string
352 resource: MothershipResource
353}): Promise<{ resources: MothershipResource[] }> {
354 const data = await requestJson(addMothershipChatResourceContract, {
355 body: { chatId: params.chatId, resource: params.resource },
356 })
357 return parseChatResourcesResponse(data)
358}
359
360export function useAddChatResource(chatId?: string) {
361 const queryClient = useQueryClient()

Callers

nothing calls this directly

Calls 2

requestJsonFunction · 0.90

Tested by

no test coverage detected