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

Function mapFolder

apps/sim/hooks/queries/folders.ts:36–51  ·  view source on GitHub ↗
(folder: FolderApi)

Source from the content-addressed store, hash-verified

34 * sync with a client fetch.
35 */
36export function mapFolder(folder: FolderApi): WorkflowFolder {
37 return {
38 id: folder.id,
39 name: folder.name,
40 userId: folder.userId,
41 workspaceId: folder.workspaceId,
42 parentId: folder.parentId,
43 color: folder.color ?? '#6B7280',
44 isExpanded: folder.isExpanded,
45 locked: folder.locked,
46 sortOrder: folder.sortOrder,
47 createdAt: new Date(folder.createdAt),
48 updatedAt: new Date(folder.updatedAt),
49 archivedAt: folder.archivedAt ? new Date(folder.archivedAt) : null,
50 }
51}
52
53async function fetchFolders(
54 workspaceId: string,

Callers 3

useCreateFolderFunction · 0.70
useUpdateFolderFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected