🧑‍💻 (folders) Add folder trpc endpoints (#1218)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **New Features**
- Introduced folder management capabilities including creation,
deletion, update, listing, and retrieval within workspaces.
- Added telemetry tracking for client events, Typebot publish events,
and analytics page views.
	- Enhanced settings to track client events under specific conditions.
- Implemented server-side logic for analytics tracking with PostHog
integration.
- Added API documentation for folder operations (create, delete, get,
list, update).
- **Refactor**
	- Updated `onConfirm` function's return type in `ConfirmModal`.
	- Simplified folder creation process in tests.
- Refactored logic for handling file upload blocks and parsing publish
events in Typebot publishing.
	- Migrated handler functions to TRPC endpoints for folder operations.
- **Documentation**
- Introduced documentation for new folder and telemetry functionalities.
- **Chores**
- Added new schemas for folders and telemetry events, including event
tracking and folder structure.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
Baptiste Arnaud
2024-02-05 12:14:03 +01:00
committed by GitHub
parent 9014c4ab09
commit 84b9aca40b
37 changed files with 1399 additions and 168 deletions

View File

@@ -6,6 +6,7 @@ import { internalWhatsAppRouter } from '@/features/whatsapp/router'
import { zemanticAiRouter } from '@/features/blocks/integrations/zemanticAi/api/router'
import { forgeRouter } from '@/features/forge/api/router'
import { googleSheetsRouter } from '@/features/blocks/integrations/googleSheets/api/router'
import { telemetryRouter } from '@/features/telemetry/api/router'
export const internalRouter = router({
getAppVersionProcedure,
@@ -15,6 +16,7 @@ export const internalRouter = router({
zemanticAI: zemanticAiRouter,
forge: forgeRouter,
sheets: googleSheetsRouter,
telemetry: telemetryRouter,
})
export type InternalRouter = typeof internalRouter

View File

@@ -11,6 +11,7 @@ import { analyticsRouter } from '@/features/analytics/api/router'
import { collaboratorsRouter } from '@/features/collaboration/api/router'
import { customDomainsRouter } from '@/features/customDomains/api/router'
import { publicWhatsAppRouter } from '@/features/whatsapp/router'
import { folderRouter } from '@/features/folders/api/router'
export const publicRouter = router({
getLinkedTypebots,
@@ -25,6 +26,7 @@ export const publicRouter = router({
collaborators: collaboratorsRouter,
customDomains: customDomainsRouter,
whatsApp: publicWhatsAppRouter,
folders: folderRouter,
})
export type PublicRouter = typeof publicRouter