patchwork-os 0.2.0-alpha.9 → 0.2.0-beta.0
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/README.bridge.md +6 -0
- package/README.md +315 -35
- package/deploy/bootstrap-new-vps.sh +12 -12
- package/deploy/bootstrap-vps.sh +187 -0
- package/deploy/deploy-dashboard.sh +174 -0
- package/deploy/deploy-landing.sh +136 -0
- package/dist/activationMetrics.d.ts +67 -0
- package/dist/activationMetrics.js +255 -0
- package/dist/activationMetrics.js.map +1 -0
- package/dist/activityLog.d.ts +49 -0
- package/dist/activityLog.js +78 -0
- package/dist/activityLog.js.map +1 -1
- package/dist/approvalHttp.d.ts +49 -2
- package/dist/approvalHttp.js +217 -21
- package/dist/approvalHttp.js.map +1 -1
- package/dist/approvalInsights.d.ts +49 -0
- package/dist/approvalInsights.js +97 -0
- package/dist/approvalInsights.js.map +1 -0
- package/dist/approvalQueue.d.ts +27 -1
- package/dist/approvalQueue.js +123 -3
- package/dist/approvalQueue.js.map +1 -1
- package/dist/approvalSignals.d.ts +124 -0
- package/dist/approvalSignals.js +512 -0
- package/dist/approvalSignals.js.map +1 -0
- package/dist/automation.d.ts +57 -0
- package/dist/automation.js +156 -59
- package/dist/automation.js.map +1 -1
- package/dist/automationSuggestions.d.ts +79 -0
- package/dist/automationSuggestions.js +150 -0
- package/dist/automationSuggestions.js.map +1 -0
- package/dist/bridge.d.ts +3 -0
- package/dist/bridge.js +174 -143
- package/dist/bridge.js.map +1 -1
- package/dist/bridgeToken.js +57 -19
- package/dist/bridgeToken.js.map +1 -1
- package/dist/ccPermissions.d.ts +15 -0
- package/dist/ccPermissions.js +21 -4
- package/dist/ccPermissions.js.map +1 -1
- package/dist/claudeDriver.js +74 -16
- package/dist/claudeDriver.js.map +1 -1
- package/dist/claudeOrchestrator.d.ts +1 -1
- package/dist/claudeOrchestrator.js +14 -8
- package/dist/claudeOrchestrator.js.map +1 -1
- package/dist/commands/dashboard.js +1 -1
- package/dist/commands/dashboard.js.map +1 -1
- package/dist/commands/launchd.d.ts +2 -0
- package/dist/commands/launchd.js +94 -0
- package/dist/commands/launchd.js.map +1 -0
- package/dist/commands/patchworkInit.d.ts +8 -0
- package/dist/commands/patchworkInit.js +77 -11
- package/dist/commands/patchworkInit.js.map +1 -1
- package/dist/commands/recipe.d.ts +289 -0
- package/dist/commands/recipe.js +1359 -0
- package/dist/commands/recipe.js.map +1 -0
- package/dist/commands/recipeInstall.d.ts +150 -0
- package/dist/commands/recipeInstall.js +647 -0
- package/dist/commands/recipeInstall.js.map +1 -0
- package/dist/commands/tracesExport.d.ts +83 -0
- package/dist/commands/tracesExport.js +269 -0
- package/dist/commands/tracesExport.js.map +1 -0
- package/dist/commands/tracesImport.d.ts +56 -0
- package/dist/commands/tracesImport.js +161 -0
- package/dist/commands/tracesImport.js.map +1 -0
- package/dist/config.d.ts +22 -1
- package/dist/config.js +108 -9
- package/dist/config.js.map +1 -1
- package/dist/connectorRoutes.d.ts +43 -0
- package/dist/connectorRoutes.js +1609 -0
- package/dist/connectorRoutes.js.map +1 -0
- package/dist/connectors/asana.d.ts +198 -0
- package/dist/connectors/asana.js +679 -0
- package/dist/connectors/asana.js.map +1 -0
- package/dist/connectors/baseConnector.d.ts +153 -0
- package/dist/connectors/baseConnector.js +336 -0
- package/dist/connectors/baseConnector.js.map +1 -0
- package/dist/connectors/confluence.d.ts +111 -0
- package/dist/connectors/confluence.js +406 -0
- package/dist/connectors/confluence.js.map +1 -0
- package/dist/connectors/datadog.d.ts +116 -0
- package/dist/connectors/datadog.js +385 -0
- package/dist/connectors/datadog.js.map +1 -0
- package/dist/connectors/discord.d.ts +150 -0
- package/dist/connectors/discord.js +543 -0
- package/dist/connectors/discord.js.map +1 -0
- package/dist/connectors/fixtureLibrary.d.ts +21 -0
- package/dist/connectors/fixtureLibrary.js +70 -0
- package/dist/connectors/fixtureLibrary.js.map +1 -0
- package/dist/connectors/fixtureRecorder.d.ts +1 -0
- package/dist/connectors/fixtureRecorder.js +35 -0
- package/dist/connectors/fixtureRecorder.js.map +1 -0
- package/dist/connectors/github.js +17 -18
- package/dist/connectors/github.js.map +1 -1
- package/dist/connectors/gitlab.d.ts +180 -0
- package/dist/connectors/gitlab.js +582 -0
- package/dist/connectors/gitlab.js.map +1 -0
- package/dist/connectors/gmail.d.ts +4 -1
- package/dist/connectors/gmail.js +149 -27
- package/dist/connectors/gmail.js.map +1 -1
- package/dist/connectors/googleCalendar.d.ts +4 -1
- package/dist/connectors/googleCalendar.js +88 -25
- package/dist/connectors/googleCalendar.js.map +1 -1
- package/dist/connectors/googleDrive.d.ts +34 -0
- package/dist/connectors/googleDrive.js +321 -0
- package/dist/connectors/googleDrive.js.map +1 -0
- package/dist/connectors/htmlEscape.d.ts +5 -0
- package/dist/connectors/htmlEscape.js +13 -0
- package/dist/connectors/htmlEscape.js.map +1 -0
- package/dist/connectors/hubspot.d.ts +112 -0
- package/dist/connectors/hubspot.js +408 -0
- package/dist/connectors/hubspot.js.map +1 -0
- package/dist/connectors/intercom.d.ts +102 -0
- package/dist/connectors/intercom.js +402 -0
- package/dist/connectors/intercom.js.map +1 -0
- package/dist/connectors/jira.d.ts +98 -0
- package/dist/connectors/jira.js +379 -0
- package/dist/connectors/jira.js.map +1 -0
- package/dist/connectors/linear.js +30 -19
- package/dist/connectors/linear.js.map +1 -1
- package/dist/connectors/mcpOAuth.d.ts +3 -0
- package/dist/connectors/mcpOAuth.js +64 -10
- package/dist/connectors/mcpOAuth.js.map +1 -1
- package/dist/connectors/mockConnector.d.ts +28 -0
- package/dist/connectors/mockConnector.js +81 -0
- package/dist/connectors/mockConnector.js.map +1 -0
- package/dist/connectors/notion.d.ts +143 -0
- package/dist/connectors/notion.js +424 -0
- package/dist/connectors/notion.js.map +1 -0
- package/dist/connectors/oauthStateStore.d.ts +31 -0
- package/dist/connectors/oauthStateStore.js +52 -0
- package/dist/connectors/oauthStateStore.js.map +1 -0
- package/dist/connectors/pagerduty.d.ts +160 -0
- package/dist/connectors/pagerduty.js +464 -0
- package/dist/connectors/pagerduty.js.map +1 -0
- package/dist/connectors/sentry.js +5 -13
- package/dist/connectors/sentry.js.map +1 -1
- package/dist/connectors/slack.d.ts +16 -1
- package/dist/connectors/slack.js +155 -32
- package/dist/connectors/slack.js.map +1 -1
- package/dist/connectors/stripe.d.ts +116 -0
- package/dist/connectors/stripe.js +379 -0
- package/dist/connectors/stripe.js.map +1 -0
- package/dist/connectors/tokenStorage.d.ts +35 -0
- package/dist/connectors/tokenStorage.js +484 -0
- package/dist/connectors/tokenStorage.js.map +1 -0
- package/dist/connectors/zendesk.d.ts +104 -0
- package/dist/connectors/zendesk.js +442 -0
- package/dist/connectors/zendesk.js.map +1 -0
- package/dist/cors.d.ts +10 -0
- package/dist/cors.js +29 -0
- package/dist/cors.js.map +1 -0
- package/dist/decisionReplay.d.ts +72 -0
- package/dist/decisionReplay.js +92 -0
- package/dist/decisionReplay.js.map +1 -0
- package/dist/decisionTraceLog.d.ts +6 -0
- package/dist/decisionTraceLog.js +54 -2
- package/dist/decisionTraceLog.js.map +1 -1
- package/dist/drivers/gemini/index.d.ts +5 -1
- package/dist/drivers/gemini/index.js +39 -5
- package/dist/drivers/gemini/index.js.map +1 -1
- package/dist/drivers/index.d.ts +5 -0
- package/dist/drivers/index.js +1 -1
- package/dist/drivers/index.js.map +1 -1
- package/dist/featureFlags.d.ts +79 -0
- package/dist/featureFlags.js +208 -0
- package/dist/featureFlags.js.map +1 -0
- package/dist/fp/automationInterpreter.js +26 -21
- package/dist/fp/automationInterpreter.js.map +1 -1
- package/dist/fp/automationProgram.d.ts +1 -1
- package/dist/fp/automationProgram.js.map +1 -1
- package/dist/fp/automationState.js +4 -1
- package/dist/fp/automationState.js.map +1 -1
- package/dist/fp/policyParser.js +21 -1
- package/dist/fp/policyParser.js.map +1 -1
- package/dist/inboxRoutes.d.ts +22 -0
- package/dist/inboxRoutes.js +114 -0
- package/dist/inboxRoutes.js.map +1 -0
- package/dist/index.js +1400 -201
- package/dist/index.js.map +1 -1
- package/dist/installGuard.d.ts +25 -0
- package/dist/installGuard.js +48 -0
- package/dist/installGuard.js.map +1 -0
- package/dist/mcpRoutes.d.ts +37 -0
- package/dist/mcpRoutes.js +76 -0
- package/dist/mcpRoutes.js.map +1 -0
- package/dist/oauth.d.ts +7 -1
- package/dist/oauth.js +201 -39
- package/dist/oauth.js.map +1 -1
- package/dist/oauthRoutes.d.ts +32 -0
- package/dist/oauthRoutes.js +124 -0
- package/dist/oauthRoutes.js.map +1 -0
- package/dist/orchestrator/orchestratorBridge.js +2 -2
- package/dist/orchestrator/orchestratorBridge.js.map +1 -1
- package/dist/patchworkConfig.d.ts +16 -0
- package/dist/patchworkConfig.js +1 -1
- package/dist/patchworkConfig.js.map +1 -1
- package/dist/pluginLoader.d.ts +28 -0
- package/dist/pluginLoader.js +77 -11
- package/dist/pluginLoader.js.map +1 -1
- package/dist/pluginWatcher.js +8 -3
- package/dist/pluginWatcher.js.map +1 -1
- package/dist/preToolUseHook.d.ts +12 -0
- package/dist/preToolUseHook.js +23 -0
- package/dist/preToolUseHook.js.map +1 -1
- package/dist/recipeOrchestration.d.ts +121 -0
- package/dist/recipeOrchestration.js +955 -0
- package/dist/recipeOrchestration.js.map +1 -0
- package/dist/recipeRoutes.d.ts +180 -0
- package/dist/recipeRoutes.js +1345 -0
- package/dist/recipeRoutes.js.map +1 -0
- package/dist/recipes/RecipeOrchestrator.d.ts +40 -0
- package/dist/recipes/RecipeOrchestrator.js +51 -0
- package/dist/recipes/RecipeOrchestrator.js.map +1 -0
- package/dist/recipes/agentExecutor.d.ts +29 -0
- package/dist/recipes/agentExecutor.js +49 -0
- package/dist/recipes/agentExecutor.js.map +1 -0
- package/dist/recipes/chainedRunner.d.ts +191 -0
- package/dist/recipes/chainedRunner.js +759 -0
- package/dist/recipes/chainedRunner.js.map +1 -0
- package/dist/recipes/compiler.js +3 -3
- package/dist/recipes/compiler.js.map +1 -1
- package/dist/recipes/dependencyGraph.d.ts +39 -0
- package/dist/recipes/dependencyGraph.js +199 -0
- package/dist/recipes/dependencyGraph.js.map +1 -0
- package/dist/recipes/disabledMarkers.d.ts +48 -0
- package/dist/recipes/disabledMarkers.js +52 -0
- package/dist/recipes/disabledMarkers.js.map +1 -0
- package/dist/recipes/installer.js +3 -3
- package/dist/recipes/installer.js.map +1 -1
- package/dist/recipes/legacyRecipeCompat.d.ts +10 -0
- package/dist/recipes/legacyRecipeCompat.js +131 -0
- package/dist/recipes/legacyRecipeCompat.js.map +1 -0
- package/dist/recipes/manifest.d.ts +47 -0
- package/dist/recipes/manifest.js +156 -0
- package/dist/recipes/manifest.js.map +1 -0
- package/dist/recipes/migrationWarnings.d.ts +12 -0
- package/dist/recipes/migrationWarnings.js +44 -0
- package/dist/recipes/migrationWarnings.js.map +1 -0
- package/dist/recipes/migrations/index.d.ts +24 -0
- package/dist/recipes/migrations/index.js +55 -0
- package/dist/recipes/migrations/index.js.map +1 -0
- package/dist/recipes/migrations/types.d.ts +28 -0
- package/dist/recipes/migrations/types.js +2 -0
- package/dist/recipes/migrations/types.js.map +1 -0
- package/dist/recipes/migrations/v1.d.ts +11 -0
- package/dist/recipes/migrations/v1.js +18 -0
- package/dist/recipes/migrations/v1.js.map +1 -0
- package/dist/recipes/names.d.ts +40 -0
- package/dist/recipes/names.js +66 -0
- package/dist/recipes/names.js.map +1 -0
- package/dist/recipes/nestedRecipeStep.d.ts +58 -0
- package/dist/recipes/nestedRecipeStep.js +95 -0
- package/dist/recipes/nestedRecipeStep.js.map +1 -0
- package/dist/recipes/outputRegistry.d.ts +28 -0
- package/dist/recipes/outputRegistry.js +52 -0
- package/dist/recipes/outputRegistry.js.map +1 -0
- package/dist/recipes/parser.js +4 -1
- package/dist/recipes/parser.js.map +1 -1
- package/dist/recipes/replayRun.d.ts +62 -0
- package/dist/recipes/replayRun.js +97 -0
- package/dist/recipes/replayRun.js.map +1 -0
- package/dist/recipes/resolveRecipePath.d.ts +69 -0
- package/dist/recipes/resolveRecipePath.js +202 -0
- package/dist/recipes/resolveRecipePath.js.map +1 -0
- package/dist/recipes/scheduler.d.ts +23 -7
- package/dist/recipes/scheduler.js +225 -45
- package/dist/recipes/scheduler.js.map +1 -1
- package/dist/recipes/schema.d.ts +17 -2
- package/dist/recipes/schemaGenerator.d.ts +28 -0
- package/dist/recipes/schemaGenerator.js +565 -0
- package/dist/recipes/schemaGenerator.js.map +1 -0
- package/dist/recipes/stepObservation.d.ts +44 -0
- package/dist/recipes/stepObservation.js +232 -0
- package/dist/recipes/stepObservation.js.map +1 -0
- package/dist/recipes/templateEngine.d.ts +62 -0
- package/dist/recipes/templateEngine.js +201 -0
- package/dist/recipes/templateEngine.js.map +1 -0
- package/dist/recipes/toolRegistry.d.ts +186 -0
- package/dist/recipes/toolRegistry.js +309 -0
- package/dist/recipes/toolRegistry.js.map +1 -0
- package/dist/recipes/tools/asana.d.ts +16 -0
- package/dist/recipes/tools/asana.js +524 -0
- package/dist/recipes/tools/asana.js.map +1 -0
- package/dist/recipes/tools/calendar.d.ts +6 -0
- package/dist/recipes/tools/calendar.js +61 -0
- package/dist/recipes/tools/calendar.js.map +1 -0
- package/dist/recipes/tools/confluence.d.ts +6 -0
- package/dist/recipes/tools/confluence.js +254 -0
- package/dist/recipes/tools/confluence.js.map +1 -0
- package/dist/recipes/tools/datadog.d.ts +6 -0
- package/dist/recipes/tools/datadog.js +239 -0
- package/dist/recipes/tools/datadog.js.map +1 -0
- package/dist/recipes/tools/diagnostics.d.ts +6 -0
- package/dist/recipes/tools/diagnostics.js +36 -0
- package/dist/recipes/tools/diagnostics.js.map +1 -0
- package/dist/recipes/tools/discord.d.ts +18 -0
- package/dist/recipes/tools/discord.js +254 -0
- package/dist/recipes/tools/discord.js.map +1 -0
- package/dist/recipes/tools/file.d.ts +12 -0
- package/dist/recipes/tools/file.js +174 -0
- package/dist/recipes/tools/file.js.map +1 -0
- package/dist/recipes/tools/git.d.ts +6 -0
- package/dist/recipes/tools/git.js +63 -0
- package/dist/recipes/tools/git.js.map +1 -0
- package/dist/recipes/tools/github.d.ts +6 -0
- package/dist/recipes/tools/github.js +116 -0
- package/dist/recipes/tools/github.js.map +1 -0
- package/dist/recipes/tools/gitlab.d.ts +11 -0
- package/dist/recipes/tools/gitlab.js +285 -0
- package/dist/recipes/tools/gitlab.js.map +1 -0
- package/dist/recipes/tools/gmail.d.ts +6 -0
- package/dist/recipes/tools/gmail.js +434 -0
- package/dist/recipes/tools/gmail.js.map +1 -0
- package/dist/recipes/tools/googleDrive.d.ts +1 -0
- package/dist/recipes/tools/googleDrive.js +55 -0
- package/dist/recipes/tools/googleDrive.js.map +1 -0
- package/dist/recipes/tools/hubspot.d.ts +6 -0
- package/dist/recipes/tools/hubspot.js +232 -0
- package/dist/recipes/tools/hubspot.js.map +1 -0
- package/dist/recipes/tools/index.d.ts +30 -0
- package/dist/recipes/tools/index.js +33 -0
- package/dist/recipes/tools/index.js.map +1 -0
- package/dist/recipes/tools/intercom.d.ts +6 -0
- package/dist/recipes/tools/intercom.js +226 -0
- package/dist/recipes/tools/intercom.js.map +1 -0
- package/dist/recipes/tools/jira.d.ts +14 -0
- package/dist/recipes/tools/jira.js +369 -0
- package/dist/recipes/tools/jira.js.map +1 -0
- package/dist/recipes/tools/linear.d.ts +7 -0
- package/dist/recipes/tools/linear.js +307 -0
- package/dist/recipes/tools/linear.js.map +1 -0
- package/dist/recipes/tools/meetingNotes.d.ts +21 -0
- package/dist/recipes/tools/meetingNotes.js +701 -0
- package/dist/recipes/tools/meetingNotes.js.map +1 -0
- package/dist/recipes/tools/notion.d.ts +6 -0
- package/dist/recipes/tools/notion.js +278 -0
- package/dist/recipes/tools/notion.js.map +1 -0
- package/dist/recipes/tools/pagerduty.d.ts +15 -0
- package/dist/recipes/tools/pagerduty.js +451 -0
- package/dist/recipes/tools/pagerduty.js.map +1 -0
- package/dist/recipes/tools/sentry.d.ts +12 -0
- package/dist/recipes/tools/sentry.js +73 -0
- package/dist/recipes/tools/sentry.js.map +1 -0
- package/dist/recipes/tools/slack.d.ts +6 -0
- package/dist/recipes/tools/slack.js +82 -0
- package/dist/recipes/tools/slack.js.map +1 -0
- package/dist/recipes/tools/stripe.d.ts +6 -0
- package/dist/recipes/tools/stripe.js +265 -0
- package/dist/recipes/tools/stripe.js.map +1 -0
- package/dist/recipes/tools/zendesk.d.ts +6 -0
- package/dist/recipes/tools/zendesk.js +245 -0
- package/dist/recipes/tools/zendesk.js.map +1 -0
- package/dist/recipes/validation.d.ts +13 -0
- package/dist/recipes/validation.js +617 -0
- package/dist/recipes/validation.js.map +1 -0
- package/dist/recipes/yamlRunner.d.ts +116 -1
- package/dist/recipes/yamlRunner.js +1000 -401
- package/dist/recipes/yamlRunner.js.map +1 -1
- package/dist/recipesHttp.d.ts +137 -6
- package/dist/recipesHttp.js +941 -29
- package/dist/recipesHttp.js.map +1 -1
- package/dist/riskTier.js +7 -1
- package/dist/riskTier.js.map +1 -1
- package/dist/runLog.d.ts +100 -1
- package/dist/runLog.js +258 -5
- package/dist/runLog.js.map +1 -1
- package/dist/schemas/dry-run-plan.v1.json +139 -0
- package/dist/schemas/recipe.v1.json +684 -0
- package/dist/server.d.ts +121 -8
- package/dist/server.js +538 -735
- package/dist/server.js.map +1 -1
- package/dist/ssrfGuard.d.ts +54 -0
- package/dist/ssrfGuard.js +122 -0
- package/dist/ssrfGuard.js.map +1 -0
- package/dist/streamableHttp.d.ts +39 -1
- package/dist/streamableHttp.js +128 -17
- package/dist/streamableHttp.js.map +1 -1
- package/dist/tokenUsageTracker.d.ts +33 -0
- package/dist/tokenUsageTracker.js +146 -0
- package/dist/tokenUsageTracker.js.map +1 -0
- package/dist/tools/activityLog.d.ts +2 -0
- package/dist/tools/addLinearComment.d.ts +1 -0
- package/dist/tools/addLinearComment.js +4 -2
- package/dist/tools/addLinearComment.js.map +1 -1
- package/dist/tools/batchLsp.d.ts +3 -0
- package/dist/tools/bridgeDoctor.d.ts +1 -0
- package/dist/tools/bridgeDoctor.js +2 -2
- package/dist/tools/bridgeDoctor.js.map +1 -1
- package/dist/tools/bridgeStatus.d.ts +1 -0
- package/dist/tools/cancelClaudeTask.d.ts +2 -0
- package/dist/tools/cancelClaudeTask.js +1 -0
- package/dist/tools/cancelClaudeTask.js.map +1 -1
- package/dist/tools/checkDocumentDirty.d.ts +1 -0
- package/dist/tools/clipboard.d.ts +2 -0
- package/dist/tools/closeTabs.d.ts +2 -0
- package/dist/tools/codeLens.d.ts +1 -0
- package/dist/tools/contextBundle.d.ts +1 -0
- package/dist/tools/createIssueFromAIComment.d.ts +1 -0
- package/dist/tools/createLinearIssue.d.ts +1 -0
- package/dist/tools/ctxGetTaskContext.d.ts +1 -0
- package/dist/tools/ctxQueryTraces.d.ts +1 -0
- package/dist/tools/ctxSaveTrace.d.ts +1 -0
- package/dist/tools/debug.d.ts +4 -0
- package/dist/tools/decorations.d.ts +2 -0
- package/dist/tools/documentLinks.d.ts +1 -0
- package/dist/tools/editText.d.ts +1 -0
- package/dist/tools/enrichCommit.d.ts +1 -0
- package/dist/tools/enrichStackTrace.d.ts +1 -0
- package/dist/tools/explainDiagnostic.d.ts +1 -0
- package/dist/tools/explainSymbol.d.ts +1 -0
- package/dist/tools/fetchCalendarEvents.d.ts +1 -0
- package/dist/tools/fetchGithubIssue.d.ts +1 -0
- package/dist/tools/fetchGithubPR.d.ts +1 -0
- package/dist/tools/fetchLinearIssue.d.ts +1 -0
- package/dist/tools/fetchSentryIssue.d.ts +1 -0
- package/dist/tools/fetchSlackProfile.d.ts +1 -0
- package/dist/tools/fetchSlackProfile.js +4 -1
- package/dist/tools/fetchSlackProfile.js.map +1 -1
- package/dist/tools/fileOperations.d.ts +3 -0
- package/dist/tools/fileWatcher.d.ts +2 -0
- package/dist/tools/findFiles.d.ts +1 -0
- package/dist/tools/findRelatedTests.d.ts +1 -0
- package/dist/tools/fixAllLintErrors.d.ts +1 -0
- package/dist/tools/foldingRanges.d.ts +1 -0
- package/dist/tools/formatDocument.d.ts +1 -0
- package/dist/tools/generateTests.d.ts +1 -0
- package/dist/tools/getAIComments.d.ts +1 -0
- package/dist/tools/getAnalyticsReport.d.ts +1 -0
- package/dist/tools/getArchitectureContext.d.ts +1 -0
- package/dist/tools/getBufferContent.d.ts +1 -0
- package/dist/tools/getChangeImpact.d.ts +1 -0
- package/dist/tools/getClaudeTaskStatus.d.ts +2 -0
- package/dist/tools/getClaudeTaskStatus.js +1 -0
- package/dist/tools/getClaudeTaskStatus.js.map +1 -1
- package/dist/tools/getCodeCoverage.d.ts +1 -0
- package/dist/tools/getCommitsForIssue.d.ts +1 -0
- package/dist/tools/getConnectorStatus.d.ts +1 -0
- package/dist/tools/getCurrentSelection.d.ts +2 -0
- package/dist/tools/getDebugState.d.ts +1 -0
- package/dist/tools/getDependencyTree.d.ts +1 -0
- package/dist/tools/getDiagnostics.d.ts +1 -0
- package/dist/tools/getDiffFromHandoff.d.ts +1 -0
- package/dist/tools/getDocumentSymbols.d.ts +25 -0
- package/dist/tools/getDocumentSymbols.js +74 -8
- package/dist/tools/getDocumentSymbols.js.map +1 -1
- package/dist/tools/getFileTree.d.ts +1 -0
- package/dist/tools/getGitDiff.d.ts +1 -0
- package/dist/tools/getGitHotspots.d.ts +1 -0
- package/dist/tools/getGitLog.d.ts +1 -0
- package/dist/tools/getGitStatus.d.ts +1 -0
- package/dist/tools/getImportTree.d.ts +1 -0
- package/dist/tools/getImportedSignatures.d.ts +1 -0
- package/dist/tools/getOpenEditors.d.ts +1 -0
- package/dist/tools/getPRTemplate.d.ts +1 -0
- package/dist/tools/getProjectContext.d.ts +1 -0
- package/dist/tools/getProjectInfo.d.ts +1 -0
- package/dist/tools/getSecurityAdvisories.d.ts +1 -0
- package/dist/tools/getSecurityAdvisories.js +10 -1
- package/dist/tools/getSecurityAdvisories.js.map +1 -1
- package/dist/tools/getSessionUsage.d.ts +4 -0
- package/dist/tools/getSessionUsage.js +3 -0
- package/dist/tools/getSessionUsage.js.map +1 -1
- package/dist/tools/getSymbolHistory.d.ts +1 -0
- package/dist/tools/getToolCapabilities.d.ts +1 -0
- package/dist/tools/getTypeSignature.d.ts +1 -0
- package/dist/tools/getWorkspaceFolders.d.ts +1 -0
- package/dist/tools/getWorkspaceSettings.d.ts +1 -0
- package/dist/tools/gitHistory.d.ts +2 -0
- package/dist/tools/gitWrite.d.ts +11 -0
- package/dist/tools/github/actions.d.ts +2 -0
- package/dist/tools/github/actions.js +4 -2
- package/dist/tools/github/actions.js.map +1 -1
- package/dist/tools/github/composite.d.ts +342 -0
- package/dist/tools/github/composite.js +343 -0
- package/dist/tools/github/composite.js.map +1 -0
- package/dist/tools/github/index.d.ts +1 -0
- package/dist/tools/github/index.js +1 -0
- package/dist/tools/github/index.js.map +1 -1
- package/dist/tools/github/issues.d.ts +4 -0
- package/dist/tools/github/issues.js +8 -4
- package/dist/tools/github/issues.js.map +1 -1
- package/dist/tools/github/pr.d.ts +7 -0
- package/dist/tools/github/pr.js +50 -12
- package/dist/tools/github/pr.js.map +1 -1
- package/dist/tools/handoffNote.d.ts +4 -0
- package/dist/tools/handoffNote.js +2 -0
- package/dist/tools/handoffNote.js.map +1 -1
- package/dist/tools/hoverAtCursor.d.ts +1 -0
- package/dist/tools/httpClient.d.ts +2 -0
- package/dist/tools/index.d.ts +8 -0
- package/dist/tools/index.js +47 -8
- package/dist/tools/index.js.map +1 -1
- package/dist/tools/inlayHints.d.ts +1 -0
- package/dist/tools/launchQuickTask.d.ts +2 -0
- package/dist/tools/launchQuickTask.js +1 -0
- package/dist/tools/launchQuickTask.js.map +1 -1
- package/dist/tools/listClaudeTasks.d.ts +2 -0
- package/dist/tools/listClaudeTasks.js +1 -0
- package/dist/tools/listClaudeTasks.js.map +1 -1
- package/dist/tools/listTerminals.d.ts +1 -0
- package/dist/tools/lsp.d.ts +14 -0
- package/dist/tools/navigateToSymbolByName.d.ts +1 -0
- package/dist/tools/openDiff.d.ts +1 -0
- package/dist/tools/openFile.d.ts +1 -0
- package/dist/tools/openInBrowser.d.ts +1 -0
- package/dist/tools/organizeImports.d.ts +1 -0
- package/dist/tools/performanceReport.d.ts +1 -0
- package/dist/tools/planPersistence.d.ts +5 -0
- package/dist/tools/previewEdit.d.ts +1 -0
- package/dist/tools/refactorAnalyze.d.ts +1 -0
- package/dist/tools/refactorPreview.d.ts +2 -0
- package/dist/tools/refactorPreview.js +1 -0
- package/dist/tools/refactorPreview.js.map +1 -1
- package/dist/tools/replaceBlock.d.ts +1 -0
- package/dist/tools/resumeClaudeTask.d.ts +2 -0
- package/dist/tools/resumeClaudeTask.js +1 -0
- package/dist/tools/resumeClaudeTask.js.map +1 -1
- package/dist/tools/runClaudeTask.d.ts +2 -0
- package/dist/tools/runClaudeTask.js +1 -0
- package/dist/tools/runClaudeTask.js.map +1 -1
- package/dist/tools/runCommand.d.ts +1 -0
- package/dist/tools/runTests.d.ts +1 -0
- package/dist/tools/saveDocument.d.ts +1 -0
- package/dist/tools/screenshotAndAnnotate.d.ts +1 -0
- package/dist/tools/searchAndReplace.d.ts +1 -0
- package/dist/tools/searchTools.d.ts +1 -0
- package/dist/tools/searchTools.js +1 -1
- package/dist/tools/searchTools.js.map +1 -1
- package/dist/tools/searchWorkspace.d.ts +1 -0
- package/dist/tools/selectionRanges.d.ts +1 -0
- package/dist/tools/semanticTokens.d.ts +1 -0
- package/dist/tools/setActiveWorkspaceFolder.d.ts +1 -0
- package/dist/tools/signatureHelp.d.ts +1 -0
- package/dist/tools/slackListChannels.d.ts +1 -0
- package/dist/tools/slackListChannels.js.map +1 -1
- package/dist/tools/slackPostMessage.d.ts +1 -0
- package/dist/tools/slackPostMessage.js +11 -6
- package/dist/tools/slackPostMessage.js.map +1 -1
- package/dist/tools/terminal.d.ts +6 -0
- package/dist/tools/testTraceToSource.d.ts +1 -0
- package/dist/tools/testTraceToSource.js +2 -2
- package/dist/tools/testTraceToSource.js.map +1 -1
- package/dist/tools/transaction.d.ts +23 -0
- package/dist/tools/transaction.js +29 -0
- package/dist/tools/transaction.js.map +1 -1
- package/dist/tools/typeHierarchy.d.ts +1 -0
- package/dist/tools/updateLinearIssue.d.ts +1 -0
- package/dist/tools/updateLinearIssue.js +20 -6
- package/dist/tools/updateLinearIssue.js.map +1 -1
- package/dist/tools/utils.d.ts +2 -0
- package/dist/tools/utils.js.map +1 -1
- package/dist/tools/vscodeCommands.d.ts +2 -0
- package/dist/tools/vscodeTasks.d.ts +2 -0
- package/dist/tools/workspaceSettings.d.ts +1 -0
- package/dist/traceEncryption.d.ts +46 -0
- package/dist/traceEncryption.js +124 -0
- package/dist/traceEncryption.js.map +1 -0
- package/dist/transport.d.ts +46 -1
- package/dist/transport.js +173 -19
- package/dist/transport.js.map +1 -1
- package/package.json +30 -8
- package/scripts/mcp-stdio-shim.cjs +19 -3
- package/scripts/start-all.sh +30 -1
- package/templates/automation-policies/recipe-authoring.json +25 -0
- package/templates/automation-policy.example.json +6 -0
- package/templates/co.patchwork-os.bridge.plist +34 -0
- package/templates/policies/README.md +72 -0
- package/templates/policies/conservative.json +14 -0
- package/templates/policies/developer.json +14 -0
- package/templates/policies/headless-ci.json +24 -0
- package/templates/policies/personal-assistant.json +15 -0
- package/templates/policies/regulated-industry.json +18 -0
- package/templates/recipes/lint-on-save.yaml +1 -2
- package/templates/recipes/morning-brief-slack.yaml +57 -0
- package/templates/recipes/morning-brief.yaml +2 -2
- package/templates/recipes/project-health-check.yaml +50 -0
- package/templates/recipes/webhook/README.md +70 -0
- package/templates/recipes/webhook/capture-thought.yaml +26 -0
- package/templates/recipes/webhook/customer-escalation.yaml +49 -0
- package/templates/recipes/webhook/incident-intake.yaml +46 -0
- package/templates/recipes/webhook/meeting-prep.yaml +48 -0
- package/templates/recipes/webhook/morning-brief.yaml +57 -0
|
@@ -0,0 +1,232 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* HubSpot tools — list/get contacts and deals, create notes, search contacts.
|
|
3
|
+
*
|
|
4
|
+
* Self-registering tool module for the recipe tool registry.
|
|
5
|
+
*/
|
|
6
|
+
import { assertWriteAllowed } from "../../featureFlags.js";
|
|
7
|
+
import { CommonSchemas, registerTool } from "../toolRegistry.js";
|
|
8
|
+
// ============================================================================
|
|
9
|
+
// hubspot.listContacts
|
|
10
|
+
// ============================================================================
|
|
11
|
+
registerTool({
|
|
12
|
+
id: "hubspot.listContacts",
|
|
13
|
+
namespace: "hubspot",
|
|
14
|
+
description: "List HubSpot CRM contacts with basic properties.",
|
|
15
|
+
paramsSchema: {
|
|
16
|
+
type: "object",
|
|
17
|
+
properties: {
|
|
18
|
+
limit: {
|
|
19
|
+
type: "number",
|
|
20
|
+
description: "Max contacts to return (default 25)",
|
|
21
|
+
default: 25,
|
|
22
|
+
},
|
|
23
|
+
after: {
|
|
24
|
+
type: "string",
|
|
25
|
+
description: "Pagination cursor (after value from previous response)",
|
|
26
|
+
},
|
|
27
|
+
into: CommonSchemas.into,
|
|
28
|
+
},
|
|
29
|
+
required: [],
|
|
30
|
+
},
|
|
31
|
+
outputSchema: {
|
|
32
|
+
type: "object",
|
|
33
|
+
properties: {
|
|
34
|
+
results: { type: "array", items: { type: "object" } },
|
|
35
|
+
paging: { type: "object" },
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
riskDefault: "low",
|
|
39
|
+
isWrite: false,
|
|
40
|
+
isConnector: true,
|
|
41
|
+
execute: async ({ params }) => {
|
|
42
|
+
const { getHubSpotConnector } = await import("../../connectors/hubspot.js");
|
|
43
|
+
const connector = getHubSpotConnector();
|
|
44
|
+
const result = await connector.listContacts({
|
|
45
|
+
limit: typeof params.limit === "number" ? params.limit : undefined,
|
|
46
|
+
after: typeof params.after === "string" ? params.after : undefined,
|
|
47
|
+
});
|
|
48
|
+
return JSON.stringify(result);
|
|
49
|
+
},
|
|
50
|
+
});
|
|
51
|
+
// ============================================================================
|
|
52
|
+
// hubspot.getContact
|
|
53
|
+
// ============================================================================
|
|
54
|
+
registerTool({
|
|
55
|
+
id: "hubspot.getContact",
|
|
56
|
+
namespace: "hubspot",
|
|
57
|
+
description: "Fetch a single HubSpot contact by ID.",
|
|
58
|
+
paramsSchema: {
|
|
59
|
+
type: "object",
|
|
60
|
+
properties: {
|
|
61
|
+
contactId: { type: "string", description: "HubSpot contact ID" },
|
|
62
|
+
into: CommonSchemas.into,
|
|
63
|
+
},
|
|
64
|
+
required: ["contactId"],
|
|
65
|
+
},
|
|
66
|
+
outputSchema: {
|
|
67
|
+
type: "object",
|
|
68
|
+
properties: {
|
|
69
|
+
contact: { type: ["object", "null"] },
|
|
70
|
+
},
|
|
71
|
+
},
|
|
72
|
+
riskDefault: "low",
|
|
73
|
+
isWrite: false,
|
|
74
|
+
isConnector: true,
|
|
75
|
+
execute: async ({ params }) => {
|
|
76
|
+
const { getHubSpotConnector } = await import("../../connectors/hubspot.js");
|
|
77
|
+
const connector = getHubSpotConnector();
|
|
78
|
+
const contact = await connector.getContact(params.contactId);
|
|
79
|
+
return JSON.stringify({ contact });
|
|
80
|
+
},
|
|
81
|
+
});
|
|
82
|
+
// ============================================================================
|
|
83
|
+
// hubspot.listDeals
|
|
84
|
+
// ============================================================================
|
|
85
|
+
registerTool({
|
|
86
|
+
id: "hubspot.listDeals",
|
|
87
|
+
namespace: "hubspot",
|
|
88
|
+
description: "List HubSpot CRM deals, optionally filtered by stage.",
|
|
89
|
+
paramsSchema: {
|
|
90
|
+
type: "object",
|
|
91
|
+
properties: {
|
|
92
|
+
limit: {
|
|
93
|
+
type: "number",
|
|
94
|
+
description: "Max deals to return (default 25)",
|
|
95
|
+
default: 25,
|
|
96
|
+
},
|
|
97
|
+
stage: {
|
|
98
|
+
type: "string",
|
|
99
|
+
description: "Filter by deal stage ID",
|
|
100
|
+
},
|
|
101
|
+
into: CommonSchemas.into,
|
|
102
|
+
},
|
|
103
|
+
required: [],
|
|
104
|
+
},
|
|
105
|
+
outputSchema: {
|
|
106
|
+
type: "object",
|
|
107
|
+
properties: {
|
|
108
|
+
results: { type: "array", items: { type: "object" } },
|
|
109
|
+
paging: { type: "object" },
|
|
110
|
+
},
|
|
111
|
+
},
|
|
112
|
+
riskDefault: "low",
|
|
113
|
+
isWrite: false,
|
|
114
|
+
isConnector: true,
|
|
115
|
+
execute: async ({ params }) => {
|
|
116
|
+
const { getHubSpotConnector } = await import("../../connectors/hubspot.js");
|
|
117
|
+
const connector = getHubSpotConnector();
|
|
118
|
+
const result = await connector.listDeals({
|
|
119
|
+
limit: typeof params.limit === "number" ? params.limit : undefined,
|
|
120
|
+
stage: typeof params.stage === "string" ? params.stage : undefined,
|
|
121
|
+
});
|
|
122
|
+
return JSON.stringify(result);
|
|
123
|
+
},
|
|
124
|
+
});
|
|
125
|
+
// ============================================================================
|
|
126
|
+
// hubspot.getDeal
|
|
127
|
+
// ============================================================================
|
|
128
|
+
registerTool({
|
|
129
|
+
id: "hubspot.getDeal",
|
|
130
|
+
namespace: "hubspot",
|
|
131
|
+
description: "Fetch a single HubSpot deal by ID.",
|
|
132
|
+
paramsSchema: {
|
|
133
|
+
type: "object",
|
|
134
|
+
properties: {
|
|
135
|
+
dealId: { type: "string", description: "HubSpot deal ID" },
|
|
136
|
+
into: CommonSchemas.into,
|
|
137
|
+
},
|
|
138
|
+
required: ["dealId"],
|
|
139
|
+
},
|
|
140
|
+
outputSchema: {
|
|
141
|
+
type: "object",
|
|
142
|
+
properties: {
|
|
143
|
+
deal: { type: ["object", "null"] },
|
|
144
|
+
},
|
|
145
|
+
},
|
|
146
|
+
riskDefault: "low",
|
|
147
|
+
isWrite: false,
|
|
148
|
+
isConnector: true,
|
|
149
|
+
execute: async ({ params }) => {
|
|
150
|
+
const { getHubSpotConnector } = await import("../../connectors/hubspot.js");
|
|
151
|
+
const connector = getHubSpotConnector();
|
|
152
|
+
const deal = await connector.getDeal(params.dealId);
|
|
153
|
+
return JSON.stringify({ deal });
|
|
154
|
+
},
|
|
155
|
+
});
|
|
156
|
+
// ============================================================================
|
|
157
|
+
// hubspot.createNote
|
|
158
|
+
// ============================================================================
|
|
159
|
+
registerTool({
|
|
160
|
+
id: "hubspot.createNote",
|
|
161
|
+
namespace: "hubspot",
|
|
162
|
+
description: "Create a note in HubSpot, optionally associated with a contact or deal.",
|
|
163
|
+
paramsSchema: {
|
|
164
|
+
type: "object",
|
|
165
|
+
properties: {
|
|
166
|
+
body: { type: "string", description: "Note text content" },
|
|
167
|
+
contactId: {
|
|
168
|
+
type: "string",
|
|
169
|
+
description: "Associate note with this contact ID",
|
|
170
|
+
},
|
|
171
|
+
dealId: {
|
|
172
|
+
type: "string",
|
|
173
|
+
description: "Associate note with this deal ID",
|
|
174
|
+
},
|
|
175
|
+
into: CommonSchemas.into,
|
|
176
|
+
},
|
|
177
|
+
required: ["body"],
|
|
178
|
+
},
|
|
179
|
+
outputSchema: {
|
|
180
|
+
type: "object",
|
|
181
|
+
properties: {
|
|
182
|
+
id: { type: "string" },
|
|
183
|
+
createdAt: { type: "string" },
|
|
184
|
+
},
|
|
185
|
+
},
|
|
186
|
+
riskDefault: "medium",
|
|
187
|
+
isWrite: true,
|
|
188
|
+
isConnector: true,
|
|
189
|
+
execute: async ({ params }) => {
|
|
190
|
+
assertWriteAllowed("hubspot.createNote");
|
|
191
|
+
const { getHubSpotConnector } = await import("../../connectors/hubspot.js");
|
|
192
|
+
const connector = getHubSpotConnector();
|
|
193
|
+
const note = await connector.createNote(params.body, typeof params.contactId === "string" ? params.contactId : undefined, typeof params.dealId === "string" ? params.dealId : undefined);
|
|
194
|
+
return JSON.stringify({ id: note.id, createdAt: note.createdAt });
|
|
195
|
+
},
|
|
196
|
+
});
|
|
197
|
+
// ============================================================================
|
|
198
|
+
// hubspot.searchContacts
|
|
199
|
+
// ============================================================================
|
|
200
|
+
registerTool({
|
|
201
|
+
id: "hubspot.searchContacts",
|
|
202
|
+
namespace: "hubspot",
|
|
203
|
+
description: "Search HubSpot contacts by name, email, or company.",
|
|
204
|
+
paramsSchema: {
|
|
205
|
+
type: "object",
|
|
206
|
+
properties: {
|
|
207
|
+
query: {
|
|
208
|
+
type: "string",
|
|
209
|
+
description: "Search query string",
|
|
210
|
+
},
|
|
211
|
+
into: CommonSchemas.into,
|
|
212
|
+
},
|
|
213
|
+
required: ["query"],
|
|
214
|
+
},
|
|
215
|
+
outputSchema: {
|
|
216
|
+
type: "object",
|
|
217
|
+
properties: {
|
|
218
|
+
results: { type: "array", items: { type: "object" } },
|
|
219
|
+
count: { type: "number" },
|
|
220
|
+
},
|
|
221
|
+
},
|
|
222
|
+
riskDefault: "low",
|
|
223
|
+
isWrite: false,
|
|
224
|
+
isConnector: true,
|
|
225
|
+
execute: async ({ params }) => {
|
|
226
|
+
const { getHubSpotConnector } = await import("../../connectors/hubspot.js");
|
|
227
|
+
const connector = getHubSpotConnector();
|
|
228
|
+
const results = await connector.searchContacts(params.query);
|
|
229
|
+
return JSON.stringify({ results, count: results.length });
|
|
230
|
+
},
|
|
231
|
+
});
|
|
232
|
+
//# sourceMappingURL=hubspot.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hubspot.js","sourceRoot":"","sources":["../../../src/recipes/tools/hubspot.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAEjE,+EAA+E;AAC/E,uBAAuB;AACvB,+EAA+E;AAE/E,YAAY,CAAC;IACX,EAAE,EAAE,sBAAsB;IAC1B,SAAS,EAAE,SAAS;IACpB,WAAW,EAAE,kDAAkD;IAC/D,YAAY,EAAE;QACZ,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,KAAK,EAAE;gBACL,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,qCAAqC;gBAClD,OAAO,EAAE,EAAE;aACZ;YACD,KAAK,EAAE;gBACL,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,wDAAwD;aACtE;YACD,IAAI,EAAE,aAAa,CAAC,IAAI;SACzB;QACD,QAAQ,EAAE,EAAE;KACb;IACD,YAA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EAAE,mBAAmB,EAAE,GAAG,MAAM,MAAM,CAAC,6BAA6B,CAAC,CAAC;QAC5E,MAAM,SAAS,GAAG,mBAAmB,EAAE,CAAC;QACxC,MAAM,OAAO,GAAG,MAAM,SAAS,CAAC,cAAc,CAAC,MAAM,CAAC,KAAe,CAAC,CAAC;QACvE,OAAO,IAAI,CAAC,SAAS,CAAC,EAAE,OAAO,EAAE,KAAK,EAAE,OAAO,CAAC,MAAM,EAAE,CAAC,CAAC;IAC5D,CAAC;CACF,CAAC,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tool registry loader — imports all tool modules to trigger self-registration.
|
|
3
|
+
*
|
|
4
|
+
* Import this file before using the registry to ensure all tools are registered.
|
|
5
|
+
*/
|
|
6
|
+
import "./file.js";
|
|
7
|
+
import "./git.js";
|
|
8
|
+
import "./diagnostics.js";
|
|
9
|
+
import "./asana.js";
|
|
10
|
+
import "./gmail.js";
|
|
11
|
+
import "./googleDrive.js";
|
|
12
|
+
import "./github.js";
|
|
13
|
+
import "./gitlab.js";
|
|
14
|
+
import "./linear.js";
|
|
15
|
+
import "./calendar.js";
|
|
16
|
+
import "./slack.js";
|
|
17
|
+
import "./notion.js";
|
|
18
|
+
import "./confluence.js";
|
|
19
|
+
import "./zendesk.js";
|
|
20
|
+
import "./intercom.js";
|
|
21
|
+
import "./hubspot.js";
|
|
22
|
+
import "./datadog.js";
|
|
23
|
+
import "./discord.js";
|
|
24
|
+
import "./jira.js";
|
|
25
|
+
import "./pagerduty.js";
|
|
26
|
+
import "./sentry.js";
|
|
27
|
+
import "./stripe.js";
|
|
28
|
+
import "./meetingNotes.js";
|
|
29
|
+
export type { RegisteredTool, ToolContext, ToolExecute, ToolMetadata, } from "../toolRegistry.js";
|
|
30
|
+
export { CommonOutputSchemas, CommonSchemas, clearRegistry, executeTool, getNamespaces, getTool, hasTool, listTools, registerTool, } from "../toolRegistry.js";
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tool registry loader — imports all tool modules to trigger self-registration.
|
|
3
|
+
*
|
|
4
|
+
* Import this file before using the registry to ensure all tools are registered.
|
|
5
|
+
*/
|
|
6
|
+
// Core tools
|
|
7
|
+
import "./file.js";
|
|
8
|
+
import "./git.js";
|
|
9
|
+
import "./diagnostics.js";
|
|
10
|
+
// Connector-based tools
|
|
11
|
+
import "./asana.js";
|
|
12
|
+
import "./gmail.js";
|
|
13
|
+
import "./googleDrive.js";
|
|
14
|
+
import "./github.js";
|
|
15
|
+
import "./gitlab.js";
|
|
16
|
+
import "./linear.js";
|
|
17
|
+
import "./calendar.js";
|
|
18
|
+
import "./slack.js";
|
|
19
|
+
import "./notion.js";
|
|
20
|
+
import "./confluence.js";
|
|
21
|
+
import "./zendesk.js";
|
|
22
|
+
import "./intercom.js";
|
|
23
|
+
import "./hubspot.js";
|
|
24
|
+
import "./datadog.js";
|
|
25
|
+
import "./discord.js";
|
|
26
|
+
import "./jira.js";
|
|
27
|
+
import "./pagerduty.js";
|
|
28
|
+
import "./sentry.js";
|
|
29
|
+
import "./stripe.js";
|
|
30
|
+
import "./meetingNotes.js";
|
|
31
|
+
// Re-export registry for convenience
|
|
32
|
+
export { CommonOutputSchemas, CommonSchemas, clearRegistry, executeTool, getNamespaces, getTool, hasTool, listTools, registerTool, } from "../toolRegistry.js";
|
|
33
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/recipes/tools/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,aAAa;AACb,OAAO,WAAW,CAAC;AACnB,OAAO,UAAU,CAAC;AAClB,OAAO,kBAAkB,CAAC;AAE1B,wBAAwB;AACxB,OAAO,YAAY,CAAC;AACpB,OAAO,YAAY,CAAC;AACpB,OAAO,kBAAkB,CAAC;AAC1B,OAAO,aAAa,CAAC;AACrB,OAAO,aAAa,CAAC;AACrB,OAAO,aAAa,CAAC;AACrB,OAAO,eAAe,CAAC;AACvB,OAAO,YAAY,CAAC;AACpB,OAAO,aAAa,CAAC;AACrB,OAAO,iBAAiB,CAAC;AACzB,OAAO,cAAc,CAAC;AACtB,OAAO,eAAe,CAAC;AACvB,OAAO,cAAc,CAAC;AACtB,OAAO,cAAc,CAAC;AACtB,OAAO,cAAc,CAAC;AACtB,OAAO,WAAW,CAAC;AACnB,OAAO,gBAAgB,CAAC;AACxB,OAAO,aAAa,CAAC;AACrB,OAAO,aAAa,CAAC;AACrB,OAAO,mBAAmB,CAAC;AAQ3B,qCAAqC;AACrC,OAAO,EACL,mBAAmB,EACnB,aAAa,EACb,aAAa,EACb,WAAW,EACX,aAAa,EACb,OAAO,EACP,OAAO,EACP,SAAS,EACT,YAAY,GACb,MAAM,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,226 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Intercom tools — list/get conversations, reply, close, list contacts.
|
|
3
|
+
*
|
|
4
|
+
* Self-registering tool module for the recipe tool registry.
|
|
5
|
+
*/
|
|
6
|
+
import { assertWriteAllowed } from "../../featureFlags.js";
|
|
7
|
+
import { CommonSchemas, registerTool } from "../toolRegistry.js";
|
|
8
|
+
// ============================================================================
|
|
9
|
+
// intercom.listConversations
|
|
10
|
+
// ============================================================================
|
|
11
|
+
registerTool({
|
|
12
|
+
id: "intercom.listConversations",
|
|
13
|
+
namespace: "intercom",
|
|
14
|
+
description: "List Intercom conversations, optionally filtered by status or assignee.",
|
|
15
|
+
paramsSchema: {
|
|
16
|
+
type: "object",
|
|
17
|
+
properties: {
|
|
18
|
+
status: {
|
|
19
|
+
type: "string",
|
|
20
|
+
enum: ["open", "closed", "snoozed", "pending"],
|
|
21
|
+
description: "Filter by conversation status",
|
|
22
|
+
},
|
|
23
|
+
assigneeId: {
|
|
24
|
+
type: "string",
|
|
25
|
+
description: "Filter by assignee ID",
|
|
26
|
+
},
|
|
27
|
+
perPage: {
|
|
28
|
+
type: "number",
|
|
29
|
+
description: "Results per page (default 20)",
|
|
30
|
+
default: 20,
|
|
31
|
+
},
|
|
32
|
+
into: CommonSchemas.into,
|
|
33
|
+
},
|
|
34
|
+
required: [],
|
|
35
|
+
},
|
|
36
|
+
outputSchema: {
|
|
37
|
+
type: "object",
|
|
38
|
+
properties: {
|
|
39
|
+
conversations: { type: "array", items: { type: "object" } },
|
|
40
|
+
total_count: { type: "number" },
|
|
41
|
+
pages: { type: "object" },
|
|
42
|
+
},
|
|
43
|
+
},
|
|
44
|
+
riskDefault: "low",
|
|
45
|
+
isWrite: false,
|
|
46
|
+
isConnector: true,
|
|
47
|
+
execute: async ({ params }) => {
|
|
48
|
+
const { getIntercomConnector } = await import("../../connectors/intercom.js");
|
|
49
|
+
const connector = getIntercomConnector();
|
|
50
|
+
const result = await connector.listConversations({
|
|
51
|
+
status: params.status,
|
|
52
|
+
assigneeId: typeof params.assigneeId === "string" ? params.assigneeId : undefined,
|
|
53
|
+
perPage: typeof params.perPage === "number" ? params.perPage : 20,
|
|
54
|
+
});
|
|
55
|
+
return JSON.stringify(result);
|
|
56
|
+
},
|
|
57
|
+
});
|
|
58
|
+
// ============================================================================
|
|
59
|
+
// intercom.getConversation
|
|
60
|
+
// ============================================================================
|
|
61
|
+
registerTool({
|
|
62
|
+
id: "intercom.getConversation",
|
|
63
|
+
namespace: "intercom",
|
|
64
|
+
description: "Fetch a single Intercom conversation by ID, including parts.",
|
|
65
|
+
paramsSchema: {
|
|
66
|
+
type: "object",
|
|
67
|
+
properties: {
|
|
68
|
+
conversationId: {
|
|
69
|
+
type: "string",
|
|
70
|
+
description: "Intercom conversation ID",
|
|
71
|
+
},
|
|
72
|
+
into: CommonSchemas.into,
|
|
73
|
+
},
|
|
74
|
+
required: ["conversationId"],
|
|
75
|
+
},
|
|
76
|
+
outputSchema: {
|
|
77
|
+
type: "object",
|
|
78
|
+
properties: {
|
|
79
|
+
id: { type: "string" },
|
|
80
|
+
state: { type: "string" },
|
|
81
|
+
title: { type: ["string", "null"] },
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
riskDefault: "low",
|
|
85
|
+
isWrite: false,
|
|
86
|
+
isConnector: true,
|
|
87
|
+
execute: async ({ params }) => {
|
|
88
|
+
const { getIntercomConnector } = await import("../../connectors/intercom.js");
|
|
89
|
+
const connector = getIntercomConnector();
|
|
90
|
+
const conversation = await connector.getConversation(params.conversationId);
|
|
91
|
+
return JSON.stringify(conversation);
|
|
92
|
+
},
|
|
93
|
+
});
|
|
94
|
+
// ============================================================================
|
|
95
|
+
// intercom.replyToConversation
|
|
96
|
+
// ============================================================================
|
|
97
|
+
registerTool({
|
|
98
|
+
id: "intercom.replyToConversation",
|
|
99
|
+
namespace: "intercom",
|
|
100
|
+
description: "Reply to an Intercom conversation as a comment or internal note.",
|
|
101
|
+
paramsSchema: {
|
|
102
|
+
type: "object",
|
|
103
|
+
properties: {
|
|
104
|
+
conversationId: {
|
|
105
|
+
type: "string",
|
|
106
|
+
description: "Intercom conversation ID",
|
|
107
|
+
},
|
|
108
|
+
body: { type: "string", description: "Reply body text" },
|
|
109
|
+
type: {
|
|
110
|
+
type: "string",
|
|
111
|
+
enum: ["comment", "note"],
|
|
112
|
+
description: "Reply type: comment (visible to user) or note (internal)",
|
|
113
|
+
default: "comment",
|
|
114
|
+
},
|
|
115
|
+
into: CommonSchemas.into,
|
|
116
|
+
},
|
|
117
|
+
required: ["conversationId", "body"],
|
|
118
|
+
},
|
|
119
|
+
outputSchema: {
|
|
120
|
+
type: "object",
|
|
121
|
+
properties: {
|
|
122
|
+
id: { type: "string" },
|
|
123
|
+
state: { type: "string" },
|
|
124
|
+
},
|
|
125
|
+
},
|
|
126
|
+
riskDefault: "medium",
|
|
127
|
+
isWrite: true,
|
|
128
|
+
isConnector: true,
|
|
129
|
+
execute: async ({ params }) => {
|
|
130
|
+
assertWriteAllowed("intercom.replyToConversation");
|
|
131
|
+
const { getIntercomConnector } = await import("../../connectors/intercom.js");
|
|
132
|
+
const connector = getIntercomConnector();
|
|
133
|
+
const conversation = await connector.replyToConversation(params.conversationId, params.body, params.type ?? "comment");
|
|
134
|
+
return JSON.stringify({ id: conversation.id, state: conversation.state });
|
|
135
|
+
},
|
|
136
|
+
});
|
|
137
|
+
// ============================================================================
|
|
138
|
+
// intercom.closeConversation
|
|
139
|
+
// ============================================================================
|
|
140
|
+
registerTool({
|
|
141
|
+
id: "intercom.closeConversation",
|
|
142
|
+
namespace: "intercom",
|
|
143
|
+
description: "Close an open Intercom conversation.",
|
|
144
|
+
paramsSchema: {
|
|
145
|
+
type: "object",
|
|
146
|
+
properties: {
|
|
147
|
+
conversationId: {
|
|
148
|
+
type: "string",
|
|
149
|
+
description: "Intercom conversation ID",
|
|
150
|
+
},
|
|
151
|
+
into: CommonSchemas.into,
|
|
152
|
+
},
|
|
153
|
+
required: ["conversationId"],
|
|
154
|
+
},
|
|
155
|
+
outputSchema: {
|
|
156
|
+
type: "object",
|
|
157
|
+
properties: {
|
|
158
|
+
id: { type: "string" },
|
|
159
|
+
state: { type: "string" },
|
|
160
|
+
},
|
|
161
|
+
},
|
|
162
|
+
riskDefault: "medium",
|
|
163
|
+
isWrite: true,
|
|
164
|
+
isConnector: true,
|
|
165
|
+
execute: async ({ params }) => {
|
|
166
|
+
assertWriteAllowed("intercom.closeConversation");
|
|
167
|
+
const { getIntercomConnector } = await import("../../connectors/intercom.js");
|
|
168
|
+
const connector = getIntercomConnector();
|
|
169
|
+
const conversation = await connector.closeConversation(params.conversationId);
|
|
170
|
+
return JSON.stringify({ id: conversation.id, state: conversation.state });
|
|
171
|
+
},
|
|
172
|
+
});
|
|
173
|
+
// ============================================================================
|
|
174
|
+
// intercom.listContacts
|
|
175
|
+
// ============================================================================
|
|
176
|
+
registerTool({
|
|
177
|
+
id: "intercom.listContacts",
|
|
178
|
+
namespace: "intercom",
|
|
179
|
+
description: "List Intercom contacts, optionally filtered by name query.",
|
|
180
|
+
paramsSchema: {
|
|
181
|
+
type: "object",
|
|
182
|
+
properties: {
|
|
183
|
+
query: {
|
|
184
|
+
type: "string",
|
|
185
|
+
description: "Filter contacts by name (partial match)",
|
|
186
|
+
},
|
|
187
|
+
perPage: {
|
|
188
|
+
type: "number",
|
|
189
|
+
description: "Results per page (default 20)",
|
|
190
|
+
default: 20,
|
|
191
|
+
},
|
|
192
|
+
into: CommonSchemas.into,
|
|
193
|
+
},
|
|
194
|
+
required: [],
|
|
195
|
+
},
|
|
196
|
+
outputSchema: {
|
|
197
|
+
type: "object",
|
|
198
|
+
properties: {
|
|
199
|
+
contacts: {
|
|
200
|
+
type: "array",
|
|
201
|
+
items: {
|
|
202
|
+
type: "object",
|
|
203
|
+
properties: {
|
|
204
|
+
id: { type: "string" },
|
|
205
|
+
name: { type: ["string", "null"] },
|
|
206
|
+
email: { type: ["string", "null"] },
|
|
207
|
+
},
|
|
208
|
+
},
|
|
209
|
+
},
|
|
210
|
+
total_count: { type: "number" },
|
|
211
|
+
},
|
|
212
|
+
},
|
|
213
|
+
riskDefault: "low",
|
|
214
|
+
isWrite: false,
|
|
215
|
+
isConnector: true,
|
|
216
|
+
execute: async ({ params }) => {
|
|
217
|
+
const { getIntercomConnector } = await import("../../connectors/intercom.js");
|
|
218
|
+
const connector = getIntercomConnector();
|
|
219
|
+
const result = await connector.listContacts({
|
|
220
|
+
query: params.query,
|
|
221
|
+
perPage: typeof params.perPage === "number" ? params.perPage : 20,
|
|
222
|
+
});
|
|
223
|
+
return JSON.stringify(result);
|
|
224
|
+
},
|
|
225
|
+
});
|
|
226
|
+
//# sourceMappingURL=intercom.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"intercom.js","sourceRoot":"","sources":["../../../src/recipes/tools/intercom.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAEjE,+EAA+E;A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SAAS,CAAC,YAAY,CAAC;YAC1C,KAAK,EAAE,MAAM,CAAC,KAA2B;YACzC,OAAO,EAAE,OAAO,MAAM,CAAC,OAAO,KAAK,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE;SAClE,CAAC,CAAC;QACH,OAAO,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;IAChC,CAAC;CACF,CAAC,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Jira tools — read wrappers (search/fetch/list_projects) plus writes
|
|
3
|
+
* (create_issue, update_status, add_comment).
|
|
4
|
+
*
|
|
5
|
+
* Self-registering tool module for the recipe tool registry. Read tools wrap
|
|
6
|
+
* connector throws into the `{count, items, error}` shape so the runner's
|
|
7
|
+
* silent-fail detector catches connector failures as a step error rather than
|
|
8
|
+
* a silent empty list. Write tools use a single-object response shape and
|
|
9
|
+
* surface failures via an `error` field.
|
|
10
|
+
*
|
|
11
|
+
* Mirrors the asana.ts / linear.ts pattern so recipe authors get a uniform
|
|
12
|
+
* surface across issue trackers.
|
|
13
|
+
*/
|
|
14
|
+
export {};
|