@credal/actions 0.2.189 → 0.2.191

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.
Files changed (32) hide show
  1. package/dist/actions/actionMapper.js +8 -1
  2. package/dist/actions/autogen/templates.d.ts +1 -0
  3. package/dist/actions/autogen/templates.js +57 -2
  4. package/dist/actions/autogen/types.d.ts +38 -5
  5. package/dist/actions/autogen/types.js +19 -3
  6. package/dist/actions/parse.js +1 -0
  7. package/dist/actions/providers/github/searchRepository.js +7 -7
  8. package/dist/actions/providers/google-oauth/addTextToTopOfDoc.d.ts +3 -0
  9. package/dist/actions/providers/google-oauth/addTextToTopOfDoc.js +54 -0
  10. package/dist/actions/providers/jira/updateServiceDeskRequest.d.ts +3 -0
  11. package/dist/actions/providers/jira/updateServiceDeskRequest.js +72 -0
  12. package/dist/actions/providers/microsoft/sendOutlookEmail.d.ts +3 -0
  13. package/dist/actions/providers/microsoft/sendOutlookEmail.js +48 -0
  14. package/dist/actions/providers/slackUser/searchSlack.js +1 -6
  15. package/dist/actions/providers/slackUser/searchSlackRTS.js +15 -2
  16. package/dist/actions/providers/slackUser/utils.d.ts +1 -0
  17. package/dist/actions/providers/slackUser/utils.js +15 -0
  18. package/package.json +1 -1
  19. package/dist/actions/groups.d.ts +0 -6
  20. package/dist/actions/groups.js +0 -248
  21. package/dist/actions/providers/credal/callCopilot.d.ts +0 -3
  22. package/dist/actions/providers/credal/callCopilot.js +0 -36
  23. package/dist/actions/providers/math/index.d.ts +0 -1
  24. package/dist/actions/providers/math/index.js +0 -37
  25. package/dist/actions/providers/salesforce/getSalesforceRecordByQuery.d.ts +0 -3
  26. package/dist/actions/providers/salesforce/getSalesforceRecordByQuery.js +0 -43
  27. package/dist/actions/providers/slack/archiveChannel.d.ts +0 -3
  28. package/dist/actions/providers/slack/archiveChannel.js +0 -35
  29. package/dist/actions/providers/slack/index.d.ts +0 -1
  30. package/dist/actions/providers/slack/index.js +0 -37
  31. package/dist/actions/providers/slack/listConversations.d.ts +0 -3
  32. package/dist/actions/providers/slack/listConversations.js +0 -41
@@ -1,4 +1,4 @@
1
- import { genericFillTemplateParamsSchema, genericFillTemplateOutputSchema, confluenceOverwritePageParamsSchema, confluenceOverwritePageOutputSchema, googlemapsValidateAddressOutputSchema, googlemapsValidateAddressParamsSchema, googleOauthCreateNewGoogleDocParamsSchema, googleOauthCreateNewGoogleDocOutputSchema, mathAddOutputSchema, mathAddParamsSchema, mongoInsertMongoDocOutputSchema, mongoInsertMongoDocParamsSchema, slackSendMessageOutputSchema, slackSendMessageParamsSchema, slackGetChannelMessagesOutputSchema, slackGetChannelMessagesParamsSchema, slackCreateChannelParamsSchema, slackCreateChannelOutputSchema, snowflakeGetRowByFieldValueOutputSchema, snowflakeGetRowByFieldValueParamsSchema, zendeskCreateZendeskTicketOutputSchema, zendeskCreateZendeskTicketParamsSchema, zendeskGetTicketDetailsOutputSchema, zendeskGetTicketDetailsParamsSchema, zendeskUpdateTicketStatusOutputSchema, zendeskUpdateTicketStatusParamsSchema, zendeskAddCommentToTicketOutputSchema, zendeskAddCommentToTicketParamsSchema, zendeskAssignTicketOutputSchema, zendeskAssignTicketParamsSchema, zendeskListZendeskTicketsOutputSchema, zendeskListZendeskTicketsParamsSchema, zendeskSearchZendeskByQueryOutputSchema, zendeskSearchZendeskByQueryParamsSchema, jiraAssignJiraTicketParamsSchema, jiraAssignJiraTicketOutputSchema, jiraCommentJiraTicketParamsSchema, jiraCommentJiraTicketOutputSchema, jiraCreateJiraTicketParamsSchema, jiraCreateJiraTicketOutputSchema, jiraGetJiraTicketDetailsParamsSchema, jiraGetJiraTicketDetailsOutputSchema, jiraGetJiraTicketHistoryParamsSchema, jiraGetJiraTicketHistoryOutputSchema, jiraUpdateJiraTicketDetailsParamsSchema, jiraUpdateJiraTicketDetailsOutputSchema, jiraUpdateJiraTicketStatusParamsSchema, jiraUpdateJiraTicketStatusOutputSchema, jiraCreateServiceDeskRequestParamsSchema, jiraCreateServiceDeskRequestOutputSchema, openstreetmapGetLatitudeLongitudeFromLocationParamsSchema, openstreetmapGetLatitudeLongitudeFromLocationOutputSchema, nwsGetForecastForLocationParamsSchema, nwsGetForecastForLocationOutputSchema, googlemapsNearbysearchRestaurantsOutputSchema, googlemapsNearbysearchRestaurantsParamsSchema, firecrawlScrapeUrlOutputSchema, firecrawlScrapeUrlParamsSchema, resendSendEmailOutputSchema, resendSendEmailHtmlParamsSchema, resendSendEmailHtmlOutputSchema, firecrawlScrapeTweetDataWithNitterParamsSchema, firecrawlScrapeTweetDataWithNitterOutputSchema, resendSendEmailParamsSchema, linkedinCreateShareLinkedinPostUrlParamsSchema, linkedinCreateShareLinkedinPostUrlOutputSchema, xCreateShareXPostUrlParamsSchema, xCreateShareXPostUrlOutputSchema, finnhubSymbolLookupParamsSchema, finnhubSymbolLookupOutputSchema, finnhubGetBasicFinancialsParamsSchema, finnhubGetBasicFinancialsOutputSchema, confluenceFetchPageContentParamsSchema, confluenceFetchPageContentOutputSchema, snowflakeRunSnowflakeQueryParamsSchema, snowflakeRunSnowflakeQueryOutputSchema, lookerEnableUserByEmailParamsSchema, lookerEnableUserByEmailOutputSchema, googleOauthUpdateDocParamsSchema, googleOauthUpdateDocOutputSchema, googleOauthCreateSpreadsheetParamsSchema, googleOauthCreateSpreadsheetOutputSchema, googleOauthUpdateSpreadsheetParamsSchema, googleOauthUpdateSpreadsheetOutputSchema, googleOauthAppendRowsToSpreadsheetParamsSchema, googleOauthAppendRowsToSpreadsheetOutputSchema, googleOauthDeleteRowFromSpreadsheetParamsSchema, googleOauthDeleteRowFromSpreadsheetOutputSchema, googleOauthScheduleCalendarMeetingParamsSchema, googleOauthScheduleCalendarMeetingOutputSchema, googleOauthListCalendarsParamsSchema, googleOauthListCalendarsOutputSchema, googleOauthListCalendarEventsParamsSchema, googleOauthListCalendarEventsOutputSchema, googleOauthUpdateCalendarEventParamsSchema, googleOauthUpdateCalendarEventOutputSchema, googleOauthDeleteCalendarEventParamsSchema, googleOauthDeleteCalendarEventOutputSchema, googleOauthEditAGoogleCalendarEventParamsSchema, googleOauthEditAGoogleCalendarEventOutputSchema, googleOauthCreatePresentationParamsSchema, googleOauthCreatePresentationOutputSchema, googleOauthUpdatePresentationParamsSchema, googleOauthUpdatePresentationOutputSchema, googleOauthGetPresentationParamsSchema, googleOauthGetPresentationOutputSchema, googleOauthSearchDriveByKeywordsParamsSchema, googleOauthSearchDriveByKeywordsOutputSchema, googleOauthListGroupsOutputSchema, googleOauthListGroupsParamsSchema, googleOauthGetGroupOutputSchema, googleOauthGetGroupParamsSchema, googleOauthListGroupMembersOutputSchema, googleOauthListGroupMembersParamsSchema, googleOauthHasGroupMemberOutputSchema, googleOauthHasGroupMemberParamsSchema, googleOauthAddGroupMemberOutputSchema, googleOauthAddGroupMemberParamsSchema, googleOauthDeleteGroupMemberOutputSchema, googleOauthDeleteGroupMemberParamsSchema, salesforceUpdateRecordParamsSchema, salesforceUpdateRecordOutputSchema, salesforceCreateCaseParamsSchema, salesforceCreateCaseOutputSchema, salesforceGenerateSalesReportParamsSchema, salesforceGenerateSalesReportOutputSchema, salesforceGetRecordParamsSchema, salesforceGetRecordOutputSchema, microsoftMessageTeamsChatParamsSchema, microsoftMessageTeamsChatOutputSchema, microsoftMessageTeamsChannelParamsSchema, microsoftMessageTeamsChannelOutputSchema, salesforceGetSalesforceRecordsByQueryParamsSchema, salesforceGetSalesforceRecordsByQueryOutputSchema, asanaCommentTaskParamsSchema, asanaCommentTaskOutputSchema, asanaCreateTaskParamsSchema, asanaCreateTaskOutputSchema, asanaUpdateTaskParamsSchema, asanaUpdateTaskOutputSchema, githubCreateOrUpdateFileParamsSchema, githubCreateOrUpdateFileOutputSchema, githubCreateBranchParamsSchema, githubCreateBranchOutputSchema, githubCreatePullRequestParamsSchema, githubCreatePullRequestOutputSchema, microsoftUpdateSpreadsheetParamsSchema, microsoftUpdateSpreadsheetOutputSchema, microsoftUpdateDocumentParamsSchema, microsoftUpdateDocumentOutputSchema, microsoftGetDocumentParamsSchema, microsoftGetDocumentOutputSchema, githubListPullRequestsParamsSchema, githubListPullRequestsOutputSchema, jiraGetJiraIssuesByQueryOutputSchema, jiraGetJiraIssuesByQueryParamsSchema, salesforceCreateRecordParamsSchema, salesforceCreateRecordOutputSchema, firecrawlDeepResearchParamsSchema, firecrawlDeepResearchOutputSchema, bingGetTopNSearchResultUrlsParamsSchema, bingGetTopNSearchResultUrlsOutputSchema, microsoftCreateDocumentParamsSchema, microsoftCreateDocumentOutputSchema, asanaListAsanaTasksByProjectParamsSchema, asanaListAsanaTasksByProjectOutputSchema, asanaSearchTasksParamsSchema, asanaSearchTasksOutputSchema, asanaGetTasksDetailsParamsSchema, asanaGetTasksDetailsOutputSchema, notionSearchByTitleParamsSchema, notionSearchByTitleOutputSchema, googlemailSearchGmailMessagesOutputSchema, googlemailSearchGmailMessagesParamsSchema, googlemailListGmailThreadsOutputSchema, googlemailListGmailThreadsParamsSchema, gitlabSearchGroupOutputSchema, gitlabSearchGroupParamsSchema, githubSearchOrganizationOutputSchema, githubSearchOrganizationParamsSchema, salesforceSearchSalesforceRecordsParamsSchema, salesforceSearchSalesforceRecordsOutputSchema, googleOauthGetDriveFileContentByIdOutputSchema, googleOauthGetDriveFileContentByIdParamsSchema, googleOauthSearchDriveByQueryOutputSchema, googleOauthSearchDriveByQueryParamsSchema, googleOauthSearchDriveByQueryAndGetFileContentParamsSchema, googleOauthSearchDriveByQueryAndGetFileContentOutputSchema, googleOauthQueryGoogleBigQueryParamsSchema, googleOauthQueryGoogleBigQueryOutputSchema, githubGetFileContentParamsSchema, githubGetFileContentOutputSchema, githubListDirectoryOutputSchema, githubListDirectoryParamsSchema, githubGetBranchParamsSchema, githubGetBranchOutputSchema, githubListCommitsParamsSchema, githubListCommitsOutputSchema, githubGetPullRequestDetailsParamsSchema, githubGetPullRequestDetailsOutputSchema, linearGetIssuesParamsSchema, linearGetIssuesOutputSchema, linearGetIssueDetailsParamsSchema, linearGetIssueDetailsOutputSchema, linearGetProjectDetailsParamsSchema, linearGetProjectDetailsOutputSchema, linearGetTeamDetailsParamsSchema, linearGetTeamDetailsOutputSchema, linearGetProjectsParamsSchema, linearGetProjectsOutputSchema, linearGetTeamsParamsSchema, linearGetTeamsOutputSchema, hubspotGetContactsParamsSchema, hubspotGetContactsOutputSchema, hubspotGetContactDetailsParamsSchema, hubspotGetContactDetailsOutputSchema, hubspotGetCompaniesParamsSchema, hubspotGetCompaniesOutputSchema, hubspotGetCompanyDetailsParamsSchema, hubspotGetCompanyDetailsOutputSchema, hubspotGetDealsParamsSchema, hubspotGetDealsOutputSchema, hubspotGetDealDetailsParamsSchema, hubspotGetDealDetailsOutputSchema, hubspotGetTicketsParamsSchema, hubspotGetTicketsOutputSchema, hubspotGetTicketDetailsParamsSchema, hubspotGetTicketDetailsOutputSchema, gitlabGetFileContentParamsSchema, gitlabGetFileContentOutputSchema, gitlabGetMergeRequestParamsSchema, gitlabGetMergeRequestOutputSchema, jiraPublicCommentOnServiceDeskRequestParamsSchema, jiraPublicCommentOnServiceDeskRequestOutputSchema, googlemailSendGmailParamsSchema, googlemailSendGmailOutputSchema, gitlabListDirectoryParamsSchema, gitlabListDirectoryOutputSchema, firecrawlSearchAndScrapeOutputSchema, firecrawlSearchAndScrapeParamsSchema, firecrawlGetTopNSearchResultUrlsParamsSchema, firecrawlGetTopNSearchResultUrlsOutputSchema, googleOauthSearchDriveByKeywordsAndGetFileContentParamsSchema, googleOauthSearchDriveByKeywordsAndGetFileContentOutputSchema, perplexityPerplexityDeepResearchParamsSchema, perplexityPerplexityDeepResearchOutputSchema, slackUserSearchSlackParamsSchema, slackUserSearchSlackOutputSchema, slackUserSearchSlackRTSParamsSchema, slackUserSearchSlackRTSOutputSchema, oktaOrgGetOktaUserByNameParamsSchema, oktaOrgGetOktaUserByNameOutputSchema, googleSearchCustomSearchParamsSchema, googleSearchCustomSearchOutputSchema, salesforceSearchAllSalesforceRecordsParamsSchema, salesforceSearchAllSalesforceRecordsOutputSchema, salesforceListReportsParamsSchema, salesforceListReportsOutputSchema, salesforceExecuteReportParamsSchema, salesforceExecuteReportOutputSchema, slackSendDmFromBotParamsSchema, slackSendDmFromBotOutputSchema, slackGetChannelMembersParamsSchema, slackGetChannelMembersOutputSchema, salesforceGetReportMetadataParamsSchema, salesforceGetReportMetadataOutputSchema, googleOauthUpdateRowsInSpreadsheetParamsSchema, googleOauthUpdateRowsInSpreadsheetOutputSchema, } from "./autogen/types.js";
1
+ import { genericFillTemplateParamsSchema, genericFillTemplateOutputSchema, confluenceOverwritePageParamsSchema, confluenceOverwritePageOutputSchema, googlemapsValidateAddressOutputSchema, googlemapsValidateAddressParamsSchema, googleOauthCreateNewGoogleDocParamsSchema, googleOauthCreateNewGoogleDocOutputSchema, mathAddOutputSchema, mathAddParamsSchema, mongoInsertMongoDocOutputSchema, mongoInsertMongoDocParamsSchema, slackSendMessageOutputSchema, slackSendMessageParamsSchema, slackGetChannelMessagesOutputSchema, slackGetChannelMessagesParamsSchema, slackCreateChannelParamsSchema, slackCreateChannelOutputSchema, snowflakeGetRowByFieldValueOutputSchema, snowflakeGetRowByFieldValueParamsSchema, zendeskCreateZendeskTicketOutputSchema, zendeskCreateZendeskTicketParamsSchema, zendeskGetTicketDetailsOutputSchema, zendeskGetTicketDetailsParamsSchema, zendeskUpdateTicketStatusOutputSchema, zendeskUpdateTicketStatusParamsSchema, zendeskAddCommentToTicketOutputSchema, zendeskAddCommentToTicketParamsSchema, zendeskAssignTicketOutputSchema, zendeskAssignTicketParamsSchema, zendeskListZendeskTicketsOutputSchema, zendeskListZendeskTicketsParamsSchema, zendeskSearchZendeskByQueryOutputSchema, zendeskSearchZendeskByQueryParamsSchema, jiraAssignJiraTicketParamsSchema, jiraAssignJiraTicketOutputSchema, jiraCommentJiraTicketParamsSchema, jiraCommentJiraTicketOutputSchema, jiraCreateJiraTicketParamsSchema, jiraCreateJiraTicketOutputSchema, jiraGetJiraTicketDetailsParamsSchema, jiraGetJiraTicketDetailsOutputSchema, jiraGetJiraTicketHistoryParamsSchema, jiraGetJiraTicketHistoryOutputSchema, jiraUpdateJiraTicketDetailsParamsSchema, jiraUpdateJiraTicketDetailsOutputSchema, jiraUpdateJiraTicketStatusParamsSchema, jiraUpdateJiraTicketStatusOutputSchema, jiraCreateServiceDeskRequestParamsSchema, jiraCreateServiceDeskRequestOutputSchema, openstreetmapGetLatitudeLongitudeFromLocationParamsSchema, openstreetmapGetLatitudeLongitudeFromLocationOutputSchema, nwsGetForecastForLocationParamsSchema, nwsGetForecastForLocationOutputSchema, googlemapsNearbysearchRestaurantsOutputSchema, googlemapsNearbysearchRestaurantsParamsSchema, firecrawlScrapeUrlOutputSchema, firecrawlScrapeUrlParamsSchema, resendSendEmailOutputSchema, resendSendEmailHtmlParamsSchema, resendSendEmailHtmlOutputSchema, firecrawlScrapeTweetDataWithNitterParamsSchema, firecrawlScrapeTweetDataWithNitterOutputSchema, resendSendEmailParamsSchema, linkedinCreateShareLinkedinPostUrlParamsSchema, linkedinCreateShareLinkedinPostUrlOutputSchema, xCreateShareXPostUrlParamsSchema, xCreateShareXPostUrlOutputSchema, finnhubSymbolLookupParamsSchema, finnhubSymbolLookupOutputSchema, finnhubGetBasicFinancialsParamsSchema, finnhubGetBasicFinancialsOutputSchema, confluenceFetchPageContentParamsSchema, confluenceFetchPageContentOutputSchema, snowflakeRunSnowflakeQueryParamsSchema, snowflakeRunSnowflakeQueryOutputSchema, lookerEnableUserByEmailParamsSchema, lookerEnableUserByEmailOutputSchema, googleOauthUpdateDocParamsSchema, googleOauthUpdateDocOutputSchema, googleOauthAddTextToTopOfDocParamsSchema, googleOauthAddTextToTopOfDocOutputSchema, googleOauthCreateSpreadsheetParamsSchema, googleOauthCreateSpreadsheetOutputSchema, googleOauthUpdateSpreadsheetParamsSchema, googleOauthUpdateSpreadsheetOutputSchema, googleOauthAppendRowsToSpreadsheetParamsSchema, googleOauthAppendRowsToSpreadsheetOutputSchema, googleOauthDeleteRowFromSpreadsheetParamsSchema, googleOauthDeleteRowFromSpreadsheetOutputSchema, googleOauthScheduleCalendarMeetingParamsSchema, googleOauthScheduleCalendarMeetingOutputSchema, googleOauthListCalendarsParamsSchema, googleOauthListCalendarsOutputSchema, googleOauthListCalendarEventsParamsSchema, googleOauthListCalendarEventsOutputSchema, googleOauthUpdateCalendarEventParamsSchema, googleOauthUpdateCalendarEventOutputSchema, googleOauthDeleteCalendarEventParamsSchema, googleOauthDeleteCalendarEventOutputSchema, googleOauthEditAGoogleCalendarEventParamsSchema, googleOauthEditAGoogleCalendarEventOutputSchema, googleOauthCreatePresentationParamsSchema, googleOauthCreatePresentationOutputSchema, googleOauthUpdatePresentationParamsSchema, googleOauthUpdatePresentationOutputSchema, googleOauthGetPresentationParamsSchema, googleOauthGetPresentationOutputSchema, googleOauthSearchDriveByKeywordsParamsSchema, googleOauthSearchDriveByKeywordsOutputSchema, googleOauthListGroupsOutputSchema, googleOauthListGroupsParamsSchema, googleOauthGetGroupOutputSchema, googleOauthGetGroupParamsSchema, googleOauthListGroupMembersOutputSchema, googleOauthListGroupMembersParamsSchema, googleOauthHasGroupMemberOutputSchema, googleOauthHasGroupMemberParamsSchema, googleOauthAddGroupMemberOutputSchema, googleOauthAddGroupMemberParamsSchema, googleOauthDeleteGroupMemberOutputSchema, googleOauthDeleteGroupMemberParamsSchema, salesforceUpdateRecordParamsSchema, salesforceUpdateRecordOutputSchema, salesforceCreateCaseParamsSchema, salesforceCreateCaseOutputSchema, salesforceGenerateSalesReportParamsSchema, salesforceGenerateSalesReportOutputSchema, salesforceGetRecordParamsSchema, salesforceGetRecordOutputSchema, microsoftMessageTeamsChatParamsSchema, microsoftMessageTeamsChatOutputSchema, microsoftMessageTeamsChannelParamsSchema, microsoftMessageTeamsChannelOutputSchema, salesforceGetSalesforceRecordsByQueryParamsSchema, salesforceGetSalesforceRecordsByQueryOutputSchema, asanaCommentTaskParamsSchema, asanaCommentTaskOutputSchema, asanaCreateTaskParamsSchema, asanaCreateTaskOutputSchema, asanaUpdateTaskParamsSchema, asanaUpdateTaskOutputSchema, githubCreateOrUpdateFileParamsSchema, githubCreateOrUpdateFileOutputSchema, githubCreateBranchParamsSchema, githubCreateBranchOutputSchema, githubCreatePullRequestParamsSchema, githubCreatePullRequestOutputSchema, microsoftUpdateSpreadsheetParamsSchema, microsoftUpdateSpreadsheetOutputSchema, microsoftUpdateDocumentParamsSchema, microsoftUpdateDocumentOutputSchema, microsoftGetDocumentParamsSchema, microsoftGetDocumentOutputSchema, githubListPullRequestsParamsSchema, githubListPullRequestsOutputSchema, jiraGetJiraIssuesByQueryOutputSchema, jiraGetJiraIssuesByQueryParamsSchema, salesforceCreateRecordParamsSchema, salesforceCreateRecordOutputSchema, firecrawlDeepResearchParamsSchema, firecrawlDeepResearchOutputSchema, bingGetTopNSearchResultUrlsParamsSchema, bingGetTopNSearchResultUrlsOutputSchema, microsoftCreateDocumentParamsSchema, microsoftCreateDocumentOutputSchema, asanaListAsanaTasksByProjectParamsSchema, asanaListAsanaTasksByProjectOutputSchema, asanaSearchTasksParamsSchema, asanaSearchTasksOutputSchema, asanaGetTasksDetailsParamsSchema, asanaGetTasksDetailsOutputSchema, notionSearchByTitleParamsSchema, notionSearchByTitleOutputSchema, googlemailSearchGmailMessagesOutputSchema, googlemailSearchGmailMessagesParamsSchema, googlemailListGmailThreadsOutputSchema, googlemailListGmailThreadsParamsSchema, gitlabSearchGroupOutputSchema, gitlabSearchGroupParamsSchema, githubSearchOrganizationOutputSchema, githubSearchOrganizationParamsSchema, salesforceSearchSalesforceRecordsParamsSchema, salesforceSearchSalesforceRecordsOutputSchema, googleOauthGetDriveFileContentByIdOutputSchema, googleOauthGetDriveFileContentByIdParamsSchema, googleOauthSearchDriveByQueryOutputSchema, googleOauthSearchDriveByQueryParamsSchema, googleOauthSearchDriveByQueryAndGetFileContentParamsSchema, googleOauthSearchDriveByQueryAndGetFileContentOutputSchema, googleOauthQueryGoogleBigQueryParamsSchema, googleOauthQueryGoogleBigQueryOutputSchema, githubGetFileContentParamsSchema, githubGetFileContentOutputSchema, githubListDirectoryOutputSchema, githubListDirectoryParamsSchema, githubGetBranchParamsSchema, githubGetBranchOutputSchema, githubListCommitsParamsSchema, githubListCommitsOutputSchema, githubGetPullRequestDetailsParamsSchema, githubGetPullRequestDetailsOutputSchema, linearGetIssuesParamsSchema, linearGetIssuesOutputSchema, linearGetIssueDetailsParamsSchema, linearGetIssueDetailsOutputSchema, linearGetProjectDetailsParamsSchema, linearGetProjectDetailsOutputSchema, linearGetTeamDetailsParamsSchema, linearGetTeamDetailsOutputSchema, linearGetProjectsParamsSchema, linearGetProjectsOutputSchema, linearGetTeamsParamsSchema, linearGetTeamsOutputSchema, hubspotGetContactsParamsSchema, hubspotGetContactsOutputSchema, hubspotGetContactDetailsParamsSchema, hubspotGetContactDetailsOutputSchema, hubspotGetCompaniesParamsSchema, hubspotGetCompaniesOutputSchema, hubspotGetCompanyDetailsParamsSchema, hubspotGetCompanyDetailsOutputSchema, hubspotGetDealsParamsSchema, hubspotGetDealsOutputSchema, hubspotGetDealDetailsParamsSchema, hubspotGetDealDetailsOutputSchema, hubspotGetTicketsParamsSchema, hubspotGetTicketsOutputSchema, hubspotGetTicketDetailsParamsSchema, hubspotGetTicketDetailsOutputSchema, gitlabGetFileContentParamsSchema, gitlabGetFileContentOutputSchema, gitlabGetMergeRequestParamsSchema, gitlabGetMergeRequestOutputSchema, jiraPublicCommentOnServiceDeskRequestParamsSchema, jiraPublicCommentOnServiceDeskRequestOutputSchema, googlemailSendGmailParamsSchema, googlemailSendGmailOutputSchema, gitlabListDirectoryParamsSchema, gitlabListDirectoryOutputSchema, firecrawlSearchAndScrapeOutputSchema, firecrawlSearchAndScrapeParamsSchema, firecrawlGetTopNSearchResultUrlsParamsSchema, firecrawlGetTopNSearchResultUrlsOutputSchema, googleOauthSearchDriveByKeywordsAndGetFileContentParamsSchema, googleOauthSearchDriveByKeywordsAndGetFileContentOutputSchema, perplexityPerplexityDeepResearchParamsSchema, perplexityPerplexityDeepResearchOutputSchema, slackUserSearchSlackParamsSchema, slackUserSearchSlackOutputSchema, slackUserSearchSlackRTSParamsSchema, slackUserSearchSlackRTSOutputSchema, oktaOrgGetOktaUserByNameParamsSchema, oktaOrgGetOktaUserByNameOutputSchema, googleSearchCustomSearchParamsSchema, googleSearchCustomSearchOutputSchema, salesforceSearchAllSalesforceRecordsParamsSchema, salesforceSearchAllSalesforceRecordsOutputSchema, salesforceListReportsParamsSchema, salesforceListReportsOutputSchema, salesforceExecuteReportParamsSchema, salesforceExecuteReportOutputSchema, slackSendDmFromBotParamsSchema, slackSendDmFromBotOutputSchema, slackGetChannelMembersParamsSchema, slackGetChannelMembersOutputSchema, salesforceGetReportMetadataParamsSchema, salesforceGetReportMetadataOutputSchema, googleOauthUpdateRowsInSpreadsheetParamsSchema, googleOauthUpdateRowsInSpreadsheetOutputSchema, } from "./autogen/types.js";
2
2
  import validateAddress from "./providers/googlemaps/validateAddress.js";
3
3
  import add from "./providers/math/add.js";
4
4
  import fillTemplate from "./providers/generic/fillTemplate.js";
@@ -43,6 +43,7 @@ import confluenceFetchPageContent from "./providers/confluence/fetchPageContent.
43
43
  import runSnowflakeQuery from "./providers/snowflake/runSnowflakeQuery.js";
44
44
  import enableUserByEmail from "./providers/looker/enableUserByEmail.js";
45
45
  import updateDoc from "./providers/google-oauth/updateDoc.js";
46
+ import addTextToTopOfDoc from "./providers/google-oauth/addTextToTopOfDoc.js";
46
47
  import scheduleCalendarMeeting from "./providers/google-oauth/scheduleCalendarMeeting.js";
47
48
  import listCalendars from "./providers/google-oauth/listCalendars.js";
48
49
  import listCalendarEvents from "./providers/google-oauth/listCalendarEvents.js";
@@ -523,6 +524,12 @@ export const ActionMapper = {
523
524
  outputSchema: googleOauthCreateNewGoogleDocOutputSchema,
524
525
  actionType: "write",
525
526
  },
527
+ addTextToTopOfDoc: {
528
+ fn: addTextToTopOfDoc,
529
+ paramsSchema: googleOauthAddTextToTopOfDocParamsSchema,
530
+ outputSchema: googleOauthAddTextToTopOfDocOutputSchema,
531
+ actionType: "write",
532
+ },
526
533
  updateDoc: {
527
534
  fn: updateDoc,
528
535
  paramsSchema: googleOauthUpdateDocParamsSchema,
@@ -72,6 +72,7 @@ export declare const firecrawlScrapeTweetDataWithNitterDefinition: ActionTemplat
72
72
  export declare const resendSendEmailDefinition: ActionTemplate;
73
73
  export declare const resendSendEmailHtmlDefinition: ActionTemplate;
74
74
  export declare const googleOauthCreateNewGoogleDocDefinition: ActionTemplate;
75
+ export declare const googleOauthAddTextToTopOfDocDefinition: ActionTemplate;
75
76
  export declare const googleOauthUpdateDocDefinition: ActionTemplate;
76
77
  export declare const googleOauthScheduleCalendarMeetingDefinition: ActionTemplate;
77
78
  export declare const googleOauthListCalendarsDefinition: ActionTemplate;
@@ -708,6 +708,7 @@ export const slackSendMessageDefinition = {
708
708
  channelName: {
709
709
  type: "string",
710
710
  description: "The name of the Slack channel to send the message to (e.g. general, alerts)",
711
+ tags: ["recommend-enum"],
711
712
  },
712
713
  message: {
713
714
  type: "string",
@@ -752,6 +753,7 @@ export const slackGetChannelMessagesDefinition = {
752
753
  channelName: {
753
754
  type: "string",
754
755
  description: "Name of the channel to summarize. Either the channelId or channelName must be provided.",
756
+ tags: ["recommend-enum"],
755
757
  },
756
758
  oldest: {
757
759
  type: "string",
@@ -830,6 +832,7 @@ export const slackGetChannelMembersDefinition = {
830
832
  channelName: {
831
833
  type: "string",
832
834
  description: "The name of the channel to get members from",
835
+ tags: ["recommend-enum"],
833
836
  },
834
837
  },
835
838
  },
@@ -897,6 +900,7 @@ export const slackUserSearchSlackDefinition = {
897
900
  channel: {
898
901
  type: "string",
899
902
  description: 'Channel name or ID. Examples - "#eng-updates", "eng-updates", "C01234567".',
903
+ tags: ["recommend-enum"],
900
904
  },
901
905
  topic: {
902
906
  type: "string",
@@ -1068,11 +1072,10 @@ export const slackUserSearchSlackRTSDefinition = {
1068
1072
  tags: [],
1069
1073
  parameters: {
1070
1074
  type: "object",
1071
- required: ["query"],
1072
1075
  properties: {
1073
1076
  query: {
1074
1077
  type: "string",
1075
- description: 'The search query string (e.g., "What is project gizmo?", "mobile UX revamp"). You can use any Slack filters directly in the query string.',
1078
+ description: 'The search query string (e.g., "What is project gizmo?", "mobile UX revamp"). Leave empty if you only want to filter by user or channel.',
1076
1079
  },
1077
1080
  userEmails: {
1078
1081
  type: "array",
@@ -1081,6 +1084,13 @@ export const slackUserSearchSlackRTSDefinition = {
1081
1084
  type: "string",
1082
1085
  },
1083
1086
  },
1087
+ channelIds: {
1088
+ type: "array",
1089
+ description: 'Optional. Channels to restrict results to. Each value can be a Slack channel ID like "C12345678" (or "<#C123...>") OR a channel name like "general" / "#general". Values are formatted into the query as in:<#C...> (ID) or in:#channel-name (name).',
1090
+ items: {
1091
+ type: "string",
1092
+ },
1093
+ },
1084
1094
  channelTypes: {
1085
1095
  type: "array",
1086
1096
  description: "Filter by channel types to search. If not specified, searches all channel types the user has access to.",
@@ -4603,6 +4613,51 @@ export const googleOauthCreateNewGoogleDocDefinition = {
4603
4613
  name: "createNewGoogleDoc",
4604
4614
  provider: "googleOauth",
4605
4615
  };
4616
+ export const googleOauthAddTextToTopOfDocDefinition = {
4617
+ displayName: "Append text to the top of a Google Doc",
4618
+ description: "Insert the provided text at the very top of an existing Google Doc using OAuth authentication",
4619
+ scopes: [],
4620
+ tags: [],
4621
+ parameters: {
4622
+ type: "object",
4623
+ required: ["documentId", "text"],
4624
+ properties: {
4625
+ documentId: {
4626
+ type: "string",
4627
+ description: "The ID of the Google Doc to update",
4628
+ tags: ["recommend-predefined"],
4629
+ },
4630
+ text: {
4631
+ type: "string",
4632
+ description: "The text to insert at the beginning of the document",
4633
+ },
4634
+ },
4635
+ },
4636
+ output: {
4637
+ type: "object",
4638
+ required: ["success"],
4639
+ properties: {
4640
+ success: {
4641
+ type: "boolean",
4642
+ description: "Whether the document was updated successfully",
4643
+ },
4644
+ documentId: {
4645
+ type: "string",
4646
+ description: "The ID of the updated Google Doc",
4647
+ },
4648
+ documentUrl: {
4649
+ type: "string",
4650
+ description: "The URL to access the updated Google Doc",
4651
+ },
4652
+ error: {
4653
+ type: "string",
4654
+ description: "The error message if the update failed",
4655
+ },
4656
+ },
4657
+ },
4658
+ name: "addTextToTopOfDoc",
4659
+ provider: "googleOauth",
4660
+ };
4606
4661
  export const googleOauthUpdateDocDefinition = {
4607
4662
  displayName: "Update a Google Doc",
4608
4663
  description: "Update an existing Google Docs document using OAuth authentication with batch requests",
@@ -89,6 +89,7 @@ export declare enum ActionName {
89
89
  SENDEMAIL = "sendEmail",
90
90
  SENDEMAILHTML = "sendEmailHtml",
91
91
  CREATENEWGOOGLEDOC = "createNewGoogleDoc",
92
+ ADDTEXTTOTOPOFDOC = "addTextToTopOfDoc",
92
93
  UPDATEDOC = "updateDoc",
93
94
  SCHEDULECALENDARMEETING = "scheduleCalendarMeeting",
94
95
  LISTCALENDARS = "listCalendars",
@@ -236,9 +237,9 @@ export type AuthParamsType = z.infer<typeof AuthParamsSchema>;
236
237
  export declare const ActionTagSchema: z.ZodEnum<["read", "write"]>;
237
238
  export type ActionTag = z.infer<typeof ActionTagSchema>;
238
239
  export declare const ACTION_TAGS: readonly ["read", "write"];
239
- export declare const ParameterTagSchema: z.ZodEnum<["recommend-predefined"]>;
240
+ export declare const ParameterTagSchema: z.ZodEnum<["recommend-predefined", "recommend-enum"]>;
240
241
  export type ParameterTag = z.infer<typeof ParameterTagSchema>;
241
- export declare const PARAMETER_TAGS: readonly ["recommend-predefined"];
242
+ export declare const PARAMETER_TAGS: readonly ["recommend-predefined", "recommend-enum"];
242
243
  export declare const genericFillTemplateParamsSchema: z.ZodObject<{
243
244
  template: z.ZodString;
244
245
  }, "strip", z.ZodTypeAny, {
@@ -1316,8 +1317,9 @@ export declare const slackUserSearchSlackOutputSchema: z.ZodObject<{
1316
1317
  export type slackUserSearchSlackOutputType = z.infer<typeof slackUserSearchSlackOutputSchema>;
1317
1318
  export type slackUserSearchSlackFunction = ActionFunction<slackUserSearchSlackParamsType, AuthParamsType, slackUserSearchSlackOutputType>;
1318
1319
  export declare const slackUserSearchSlackRTSParamsSchema: z.ZodObject<{
1319
- query: z.ZodString;
1320
+ query: z.ZodOptional<z.ZodString>;
1320
1321
  userEmails: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1322
+ channelIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1321
1323
  channelTypes: z.ZodOptional<z.ZodArray<z.ZodEnum<["public_channel", "private_channel", "mpim", "im"]>, "many">>;
1322
1324
  contentTypes: z.ZodDefault<z.ZodArray<z.ZodEnum<["messages", "files", "channels"]>, "many">>;
1323
1325
  includeBots: z.ZodDefault<z.ZodBoolean>;
@@ -1326,19 +1328,21 @@ export declare const slackUserSearchSlackRTSParamsSchema: z.ZodObject<{
1326
1328
  before: z.ZodOptional<z.ZodString>;
1327
1329
  after: z.ZodOptional<z.ZodString>;
1328
1330
  }, "strip", z.ZodTypeAny, {
1329
- query: string;
1330
1331
  limit: number;
1331
1332
  contentTypes: ("messages" | "files" | "channels")[];
1332
1333
  includeBots: boolean;
1333
1334
  includeContextMessages: boolean;
1335
+ query?: string | undefined;
1334
1336
  userEmails?: string[] | undefined;
1337
+ channelIds?: string[] | undefined;
1335
1338
  channelTypes?: ("im" | "public_channel" | "private_channel" | "mpim")[] | undefined;
1336
1339
  before?: string | undefined;
1337
1340
  after?: string | undefined;
1338
1341
  }, {
1339
- query: string;
1342
+ query?: string | undefined;
1340
1343
  limit?: number | undefined;
1341
1344
  userEmails?: string[] | undefined;
1345
+ channelIds?: string[] | undefined;
1342
1346
  channelTypes?: ("im" | "public_channel" | "private_channel" | "mpim")[] | undefined;
1343
1347
  contentTypes?: ("messages" | "files" | "channels")[] | undefined;
1344
1348
  includeBots?: boolean | undefined;
@@ -4616,6 +4620,35 @@ export declare const googleOauthCreateNewGoogleDocOutputSchema: z.ZodObject<{
4616
4620
  }>;
4617
4621
  export type googleOauthCreateNewGoogleDocOutputType = z.infer<typeof googleOauthCreateNewGoogleDocOutputSchema>;
4618
4622
  export type googleOauthCreateNewGoogleDocFunction = ActionFunction<googleOauthCreateNewGoogleDocParamsType, AuthParamsType, googleOauthCreateNewGoogleDocOutputType>;
4623
+ export declare const googleOauthAddTextToTopOfDocParamsSchema: z.ZodObject<{
4624
+ documentId: z.ZodString;
4625
+ text: z.ZodString;
4626
+ }, "strip", z.ZodTypeAny, {
4627
+ text: string;
4628
+ documentId: string;
4629
+ }, {
4630
+ text: string;
4631
+ documentId: string;
4632
+ }>;
4633
+ export type googleOauthAddTextToTopOfDocParamsType = z.infer<typeof googleOauthAddTextToTopOfDocParamsSchema>;
4634
+ export declare const googleOauthAddTextToTopOfDocOutputSchema: z.ZodObject<{
4635
+ success: z.ZodBoolean;
4636
+ documentId: z.ZodOptional<z.ZodString>;
4637
+ documentUrl: z.ZodOptional<z.ZodString>;
4638
+ error: z.ZodOptional<z.ZodString>;
4639
+ }, "strip", z.ZodTypeAny, {
4640
+ success: boolean;
4641
+ error?: string | undefined;
4642
+ documentId?: string | undefined;
4643
+ documentUrl?: string | undefined;
4644
+ }, {
4645
+ success: boolean;
4646
+ error?: string | undefined;
4647
+ documentId?: string | undefined;
4648
+ documentUrl?: string | undefined;
4649
+ }>;
4650
+ export type googleOauthAddTextToTopOfDocOutputType = z.infer<typeof googleOauthAddTextToTopOfDocOutputSchema>;
4651
+ export type googleOauthAddTextToTopOfDocFunction = ActionFunction<googleOauthAddTextToTopOfDocParamsType, AuthParamsType, googleOauthAddTextToTopOfDocOutputType>;
4619
4652
  export declare const googleOauthUpdateDocParamsSchema: z.ZodObject<{
4620
4653
  documentId: z.ZodString;
4621
4654
  requests: z.ZodOptional<z.ZodArray<z.ZodIntersection<z.ZodObject<{}, "strip", z.ZodAny, z.objectOutputType<{}, z.ZodAny, "strip">, z.objectInputType<{}, z.ZodAny, "strip">>, z.ZodEffects<z.ZodAny, any, any>>, "many">>;
@@ -91,6 +91,7 @@ export var ActionName;
91
91
  ActionName["SENDEMAIL"] = "sendEmail";
92
92
  ActionName["SENDEMAILHTML"] = "sendEmailHtml";
93
93
  ActionName["CREATENEWGOOGLEDOC"] = "createNewGoogleDoc";
94
+ ActionName["ADDTEXTTOTOPOFDOC"] = "addTextToTopOfDoc";
94
95
  ActionName["UPDATEDOC"] = "updateDoc";
95
96
  ActionName["SCHEDULECALENDARMEETING"] = "scheduleCalendarMeeting";
96
97
  ActionName["LISTCALENDARS"] = "listCalendars";
@@ -192,8 +193,8 @@ export const AuthParamsSchema = z.object({
192
193
  });
193
194
  export const ActionTagSchema = z.enum(["read", "write"]);
194
195
  export const ACTION_TAGS = ["read", "write"];
195
- export const ParameterTagSchema = z.enum(["recommend-predefined"]);
196
- export const PARAMETER_TAGS = ["recommend-predefined"];
196
+ export const ParameterTagSchema = z.enum(["recommend-predefined", "recommend-enum"]);
197
+ export const PARAMETER_TAGS = ["recommend-predefined", "recommend-enum"];
197
198
  export const genericFillTemplateParamsSchema = z.object({
198
199
  template: z.string().describe("The template string to be processed and returned"),
199
200
  });
@@ -528,11 +529,16 @@ export const slackUserSearchSlackOutputSchema = z.object({
528
529
  export const slackUserSearchSlackRTSParamsSchema = z.object({
529
530
  query: z
530
531
  .string()
531
- .describe('The search query string (e.g., "What is project gizmo?", "mobile UX revamp"). You can use any Slack filters directly in the query string.'),
532
+ .describe('The search query string (e.g., "What is project gizmo?", "mobile UX revamp"). Leave empty if you only want to filter by user or channel.')
533
+ .optional(),
532
534
  userEmails: z
533
535
  .array(z.string())
534
536
  .describe('Optional. Users to filter messages from. Each value should be a plain-text email (e.g. "user@company.com"). Will be resolved to a Slack user ID and formatted into the query as from:<@U...>.')
535
537
  .optional(),
538
+ channelIds: z
539
+ .array(z.string())
540
+ .describe('Optional. Channels to restrict results to. Each value can be a Slack channel ID like "C12345678" (or "<#C123...>") OR a channel name like "general" / "#general". Values are formatted into the query as in:<#C...> (ID) or in:#channel-name (name).')
541
+ .optional(),
536
542
  channelTypes: z
537
543
  .array(z.enum(["public_channel", "private_channel", "mpim", "im"]))
538
544
  .describe("Filter by channel types to search. If not specified, searches all channel types the user has access to.")
@@ -1524,6 +1530,16 @@ export const googleOauthCreateNewGoogleDocOutputSchema = z.object({
1524
1530
  documentId: z.string().describe("The ID of the created Google Doc"),
1525
1531
  documentUrl: z.string().describe("The URL to access the created Google Doc").optional(),
1526
1532
  });
1533
+ export const googleOauthAddTextToTopOfDocParamsSchema = z.object({
1534
+ documentId: z.string().describe("The ID of the Google Doc to update"),
1535
+ text: z.string().describe("The text to insert at the beginning of the document"),
1536
+ });
1537
+ export const googleOauthAddTextToTopOfDocOutputSchema = z.object({
1538
+ success: z.boolean().describe("Whether the document was updated successfully"),
1539
+ documentId: z.string().describe("The ID of the updated Google Doc").optional(),
1540
+ documentUrl: z.string().describe("The URL to access the updated Google Doc").optional(),
1541
+ error: z.string().describe("The error message if the update failed").optional(),
1542
+ });
1527
1543
  export const googleOauthUpdateDocParamsSchema = z.object({
1528
1544
  documentId: z.string().describe("The ID of the Google Doc to update"),
1529
1545
  requests: z
@@ -22,6 +22,7 @@ const actionTagValues = [
22
22
  ];
23
23
  const parameterTagValues = [
24
24
  "recommend-predefined", // we recommend that this parameter is predefined by the user versus AI generated at runtime
25
+ "recommend-enum", // we recommend that this parameter is an enum
25
26
  ];
26
27
  const jsonObjectSchema = z.object({
27
28
  type: z.string(),
@@ -47,7 +47,7 @@ const searchRepository = (_a) => __awaiter(void 0, [_a], void 0, function* ({ pa
47
47
  name: item.name,
48
48
  path: item.path,
49
49
  sha: item.sha.slice(0, 7),
50
- url: item.html_url,
50
+ url: item.url,
51
51
  score: item.score,
52
52
  textMatches: item.text_matches
53
53
  ? item.text_matches.map(match => {
@@ -68,7 +68,7 @@ const searchRepository = (_a) => __awaiter(void 0, [_a], void 0, function* ({ pa
68
68
  const full = commitDetails.find(c => c.data.sha === item.sha);
69
69
  return {
70
70
  sha: item.sha,
71
- url: item.html_url,
71
+ url: item.url,
72
72
  commit: {
73
73
  message: item.commit.message,
74
74
  author: item.commit.author,
@@ -76,11 +76,11 @@ const searchRepository = (_a) => __awaiter(void 0, [_a], void 0, function* ({ pa
76
76
  score: item.score,
77
77
  author: (_a = item.author) !== null && _a !== void 0 ? _a : undefined,
78
78
  files: ((_b = full === null || full === void 0 ? void 0 : full.data.files) === null || _b === void 0 ? void 0 : _b.slice(0, MAX_FILES_PER_COMMIT).map(f => {
79
- var _a, _b, _c;
79
+ var _a;
80
80
  return ({
81
81
  filename: f.filename,
82
82
  status: f.status,
83
- patch: (_c = (_b = (_a = f.patch) === null || _a === void 0 ? void 0 : _a.split("\n")) === null || _b === void 0 ? void 0 : _b.slice(0, MAX_PATCH_LINES)) === null || _c === void 0 ? void 0 : _c.join("\n"),
83
+ patch: (_a = f.patch) === null || _a === void 0 ? void 0 : _a.split("\n").slice(0, MAX_PATCH_LINES).join("\n"),
84
84
  });
85
85
  })) || [],
86
86
  };
@@ -104,18 +104,18 @@ const searchRepository = (_a) => __awaiter(void 0, [_a], void 0, function* ({ pa
104
104
  const prIndex = prNumbers.indexOf(item.number);
105
105
  const files = isPR && prIndex !== -1
106
106
  ? prFiles[prIndex].data.slice(0, MAX_FILES_PER_PR).map(f => {
107
- var _a, _b, _c;
107
+ var _a;
108
108
  return ({
109
109
  filename: f.filename,
110
110
  status: f.status,
111
- patch: (_c = (_b = (_a = f.patch) === null || _a === void 0 ? void 0 : _a.split("\n")) === null || _b === void 0 ? void 0 : _b.slice(0, MAX_PATCH_LINES)) === null || _c === void 0 ? void 0 : _c.join("\n"),
111
+ patch: (_a = f.patch) === null || _a === void 0 ? void 0 : _a.split("\n").slice(0, MAX_PATCH_LINES).join("\n"),
112
112
  });
113
113
  })
114
114
  : undefined;
115
115
  return {
116
116
  number: item.number,
117
117
  title: item.title,
118
- url: item.html_url,
118
+ html_url: item.html_url,
119
119
  state: item.state,
120
120
  isPullRequest: isPR,
121
121
  body: item.body,
@@ -0,0 +1,3 @@
1
+ import type { googleOauthAddTextToTopOfDocFunction } from "../../autogen/types.js";
2
+ declare const addTextToTopOfDoc: googleOauthAddTextToTopOfDocFunction;
3
+ export default addTextToTopOfDoc;
@@ -0,0 +1,54 @@
1
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
+ return new (P || (P = Promise))(function (resolve, reject) {
4
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
8
+ });
9
+ };
10
+ import { axiosClient } from "../../util/axiosClient.js";
11
+ import { MISSING_AUTH_TOKEN } from "../../util/missingAuthConstants.js";
12
+ const addTextToTopOfDoc = (_a) => __awaiter(void 0, [_a], void 0, function* ({ params, authParams, }) {
13
+ if (!authParams.authToken) {
14
+ return {
15
+ success: false,
16
+ documentId: params.documentId,
17
+ error: MISSING_AUTH_TOKEN,
18
+ };
19
+ }
20
+ const { documentId, text } = params;
21
+ const baseApiUrl = "https://docs.googleapis.com/v1/documents";
22
+ try {
23
+ yield axiosClient.post(`${baseApiUrl}/${documentId}:batchUpdate`, {
24
+ requests: [
25
+ {
26
+ insertText: {
27
+ location: {
28
+ index: 1,
29
+ },
30
+ text: text + "\n",
31
+ },
32
+ },
33
+ ],
34
+ }, {
35
+ headers: {
36
+ Authorization: `Bearer ${authParams.authToken}`,
37
+ },
38
+ });
39
+ const documentUrl = `https://docs.google.com/document/d/${documentId}/edit`;
40
+ return {
41
+ success: true,
42
+ documentId,
43
+ documentUrl,
44
+ };
45
+ }
46
+ catch (error) {
47
+ return {
48
+ success: false,
49
+ documentId,
50
+ error: error instanceof Error ? error.message : "Unknown error",
51
+ };
52
+ }
53
+ });
54
+ export default addTextToTopOfDoc;
@@ -0,0 +1,3 @@
1
+ import type { jiraUpdateServiceDeskRequestFunction } from "../../autogen/types.js";
2
+ declare const updateServiceDeskRequest: jiraUpdateServiceDeskRequestFunction;
3
+ export default updateServiceDeskRequest;
@@ -0,0 +1,72 @@
1
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
+ return new (P || (P = Promise))(function (resolve, reject) {
4
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
8
+ });
9
+ };
10
+ import { axiosClient } from "../../util/axiosClient.js";
11
+ const updateServiceDeskRequest = (_a) => __awaiter(void 0, [_a], void 0, function* ({ params, authParams, }) {
12
+ const { issueId, requestTypeId, summary, description, priority, customFields } = params;
13
+ const { authToken, cloudId, baseUrl } = authParams;
14
+ if (!cloudId || !authToken) {
15
+ throw new Error("Valid Cloud ID and auth token are required to update service desk request");
16
+ }
17
+ // Use the regular Jira API for updating service desk requests as they are still Jira issues
18
+ const apiUrl = `https://api.atlassian.com/ex/jira/${cloudId}/rest/api/3/issue/${issueId}`;
19
+ const formattedDescription = description
20
+ ? {
21
+ type: "doc",
22
+ version: 1,
23
+ content: [
24
+ {
25
+ type: "paragraph",
26
+ content: [
27
+ {
28
+ type: "text",
29
+ text: description,
30
+ },
31
+ ],
32
+ },
33
+ ],
34
+ }
35
+ : undefined;
36
+ const payload = {
37
+ fields: Object.assign(Object.assign(Object.assign(Object.assign({}, (summary && { summary })), (formattedDescription && { description: formattedDescription })), (priority && { priority: { name: priority } })), (customFields && Object.assign({}, customFields))),
38
+ };
39
+ try {
40
+ yield axiosClient.put(apiUrl, payload, {
41
+ headers: {
42
+ Authorization: `Bearer ${authToken}`,
43
+ Accept: "application/json",
44
+ "Content-Type": "application/json",
45
+ },
46
+ });
47
+ // Get the updated issue details to return current status and web link
48
+ const getResponse = yield axiosClient.get(apiUrl, {
49
+ headers: {
50
+ Authorization: `Bearer ${authToken}`,
51
+ Accept: "application/json",
52
+ },
53
+ });
54
+ const issueKey = getResponse.data.key;
55
+ const currentStatus = getResponse.data.fields.status.name;
56
+ const webLink = `${baseUrl}/browse/${issueKey}`;
57
+ return {
58
+ success: true,
59
+ issueKey,
60
+ webLink,
61
+ currentStatus,
62
+ };
63
+ }
64
+ catch (error) {
65
+ console.error("Error updating service desk request:", error);
66
+ return {
67
+ success: false,
68
+ error: error instanceof Error ? error.message : "Unknown error",
69
+ };
70
+ }
71
+ });
72
+ export default updateServiceDeskRequest;
@@ -0,0 +1,3 @@
1
+ import type { microsoftSendOutlookEmailFunction } from "../../autogen/types.js";
2
+ declare const sendEmail: microsoftSendOutlookEmailFunction;
3
+ export default sendEmail;
@@ -0,0 +1,48 @@
1
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
+ return new (P || (P = Promise))(function (resolve, reject) {
4
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
8
+ });
9
+ };
10
+ import { getGraphClient } from "./utils.js";
11
+ const sendEmail = (_a) => __awaiter(void 0, [_a], void 0, function* ({ params, authParams, }) {
12
+ const { toRecipients, subject, body, ccRecipients, bccRecipients } = params;
13
+ let client = undefined;
14
+ try {
15
+ client = yield getGraphClient(authParams);
16
+ }
17
+ catch (error) {
18
+ return {
19
+ success: false,
20
+ error: "Error while authorizing: " + (error instanceof Error ? error.message : "Unknown error"),
21
+ };
22
+ }
23
+ try {
24
+ const message = {
25
+ message: Object.assign(Object.assign({ subject, body: {
26
+ contentType: "HTML",
27
+ content: body,
28
+ }, toRecipients: toRecipients.map(email => ({ emailAddress: { address: email } })) }, (ccRecipients && ccRecipients.length > 0
29
+ ? { ccRecipients: ccRecipients.map(email => ({ emailAddress: { address: email } })) }
30
+ : {})), (bccRecipients && bccRecipients.length > 0
31
+ ? { bccRecipients: bccRecipients.map(email => ({ emailAddress: { address: email } })) }
32
+ : {})),
33
+ saveToSentItems: true,
34
+ };
35
+ yield client.api("/me/sendMail").post(message);
36
+ return {
37
+ success: true,
38
+ };
39
+ }
40
+ catch (error) {
41
+ console.error(error);
42
+ return {
43
+ success: false,
44
+ error: "Error sending email: " + (error instanceof Error ? error.message : "Unknown error"),
45
+ };
46
+ }
47
+ });
48
+ export default sendEmail;
@@ -11,6 +11,7 @@ import { WebClient } from "@slack/web-api";
11
11
  import { MISSING_AUTH_TOKEN } from "../../util/missingAuthConstants.js";
12
12
  import pLimit from "p-limit";
13
13
  import { extractMessageText, transformToSlackMessage, simplifyFile, } from "../slack/messageTransformers.js";
14
+ import { normalizeChannelOperand } from "./utils.js";
14
15
  /* ===================== Constants ===================== */
15
16
  const HIT_ENRICH_POOL = 2; // keep concurrency conservative to avoid 429s
16
17
  const limitHit = pLimit(HIT_ENRICH_POOL);
@@ -65,12 +66,6 @@ class SlackUserCache {
65
66
  }
66
67
  }
67
68
  /* ===================== Helpers ===================== */
68
- function normalizeChannelOperand(ch) {
69
- const s = ch.trim();
70
- if (/^[CGD][A-Z0-9]/i.test(s))
71
- return s;
72
- return s.replace(/^#/, "");
73
- }
74
69
  function getMessageTypeFilter(messageType) {
75
70
  // This converts the LLM readable message type to the Slack search API message type (e.g. "channel" -> "message")
76
71
  if (messageType === "channel")
@@ -9,6 +9,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
9
9
  };
10
10
  import { WebClient } from "@slack/web-api";
11
11
  import { MISSING_AUTH_TOKEN } from "../../util/missingAuthConstants.js";
12
+ import { normalizeChannelOperand } from "./utils.js";
12
13
  /* ===================== Types ===================== */
13
14
  function resolveSlackUserId(client, raw) {
14
15
  return __awaiter(this, void 0, void 0, function* () {
@@ -42,8 +43,13 @@ const searchSlackRTS = (_a) => __awaiter(void 0, [_a], void 0, function* ({ para
42
43
  if (!authParams.authToken)
43
44
  throw new Error(MISSING_AUTH_TOKEN);
44
45
  const client = new WebClient(authParams.authToken);
45
- const { query, userEmails, channelTypes, contentTypes = ["messages", "files", "channels"], includeBots = false, limit = 20, includeContextMessages = true, before, after, } = params;
46
- let finalQuery = query;
46
+ const { query, userEmails, channelIds, channelTypes, contentTypes = ["messages", "files", "channels"], includeBots = false, limit = 20, includeContextMessages = true, before, after, } = params;
47
+ if ((!query || query === "") &&
48
+ (!userEmails || userEmails.length === 0) &&
49
+ (!channelIds || channelIds.length === 0)) {
50
+ throw new Error("If query is left blank, you must provide at least one userEmail or channelId to filter by.");
51
+ }
52
+ let finalQuery = query !== null && query !== void 0 ? query : "";
47
53
  if (userEmails != undefined && userEmails.length > 0) {
48
54
  const settled = yield Promise.allSettled(userEmails.map((u) => resolveSlackUserId(client, u)));
49
55
  const fulfilled = settled.filter((r) => r.status === "fulfilled");
@@ -54,6 +60,13 @@ const searchSlackRTS = (_a) => __awaiter(void 0, [_a], void 0, function* ({ para
54
60
  finalQuery = appendToQuery(finalQuery, filter);
55
61
  }
56
62
  }
63
+ if (channelIds != undefined && channelIds.length > 0) {
64
+ const operands = channelIds.map(normalizeChannelOperand).filter((operand) => Boolean(operand));
65
+ if (operands.length > 0) {
66
+ const filter = operands.map(op => `in:${op}`).join(" ");
67
+ finalQuery = appendToQuery(finalQuery, filter);
68
+ }
69
+ }
57
70
  // Build the request parameters for assistant.search.context
58
71
  const requestParams = {
59
72
  query: finalQuery,
@@ -0,0 +1 @@
1
+ export declare function normalizeChannelOperand(raw: string): string | undefined;
@@ -0,0 +1,15 @@
1
+ export function normalizeChannelOperand(raw) {
2
+ const s = raw.trim();
3
+ if (!s)
4
+ return;
5
+ // Accept inputs like "C123", "#C123", "<#C123>", "<#C123|name>", "general", or "#general"
6
+ const m = s.match(/<#(C[A-Z0-9]+)(?:\|[^>]+)?>/i);
7
+ if (m === null || m === void 0 ? void 0 : m[1])
8
+ return `<#${m[1]}>`;
9
+ const stripped = s.replace(/^#/, "");
10
+ if (/^C[A-Z0-9]+$/i.test(stripped))
11
+ return `<#${stripped}>`;
12
+ if (/^[a-z0-9._-]+$/i.test(stripped))
13
+ return `#${stripped}`;
14
+ return;
15
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@credal/actions",
3
- "version": "0.2.189",
3
+ "version": "0.2.191",
4
4
  "type": "module",
5
5
  "description": "AI Actions by Credal AI",
6
6
  "sideEffects": false,
@@ -1,6 +0,0 @@
1
- import type { ActionTemplate } from "./parse.js";
2
- export type ActionGroups = Record<string, {
3
- description: string;
4
- actions: ActionTemplate[];
5
- }>;
6
- export declare const ACTION_GROUPS: ActionGroups;
@@ -1,248 +0,0 @@
1
- import { genericFillTemplateDefinition, confluenceOverwritePageDefinition, googlemapsValidateAddressDefinition, mathAddDefinition, mongoInsertMongoDocDefinition, slackSendMessageDefinition, slackGetChannelMessagesDefinition, slackCreateChannelDefinition, slackArchiveChannelDefinition, snowflakeGetRowByFieldValueDefinition, zendeskCreateZendeskTicketDefinition, zendeskListZendeskTicketsDefinition, zendeskGetTicketDetailsDefinition, zendeskUpdateTicketStatusDefinition, zendeskAddCommentToTicketDefinition, zendeskAssignTicketDefinition, openstreetmapGetLatitudeLongitudeFromLocationDefinition, nwsGetForecastForLocationDefinition, jiraAssignJiraTicketDefinition, jiraCommentJiraTicketDefinition, jiraCreateJiraTicketDefinition, jiraGetJiraTicketDetailsDefinition, jiraGetJiraTicketHistoryDefinition, jiraUpdateJiraTicketDetailsDefinition, jiraUpdateJiraTicketStatusDefinition, jiraGetServiceDesksDefinition, jiraCreateServiceDeskRequestDefinition, googlemapsNearbysearchRestaurantsDefinition, firecrawlScrapeUrlDefinition, resendSendEmailDefinition, linkedinCreateShareLinkedinPostUrlDefinition, googleOauthCreateNewGoogleDocDefinition, xCreateShareXPostUrlDefinition, firecrawlScrapeTweetDataWithNitterDefinition, finnhubSymbolLookupDefinition, finnhubGetBasicFinancialsDefinition, confluenceFetchPageContentDefinition, snowflakeRunSnowflakeQueryDefinition, lookerEnableUserByEmailDefinition, googleOauthUpdateDocDefinition, googleOauthScheduleCalendarMeetingDefinition, googleOauthListCalendarsDefinition, googleOauthListCalendarEventsDefinition, googleOauthUpdateCalendarEventDefinition, googleOauthDeleteCalendarEventDefinition, googleOauthCreateSpreadsheetDefinition, googleOauthUpdateSpreadsheetDefinition, googleOauthCreatePresentationDefinition, googleOauthUpdatePresentationDefinition, googleOauthSearchDriveByKeywordsDefinition, googlemailSearchGmailMessagesDefinition, googlemailListGmailThreadsDefinition, googleOauthListGroupsDefinition, googleOauthGetGroupDefinition, googleOauthListGroupMembersDefinition, googleOauthHasGroupMemberDefinition, googleOauthAddGroupMemberDefinition, googleOauthDeleteGroupMemberDefinition, salesforceUpdateRecordDefinition, salesforceCreateCaseDefinition, salesforceGenerateSalesReportDefinition, salesforceGetRecordDefinition, salesforceGetSalesforceRecordsByQueryDefinition, microsoftMessageTeamsChatDefinition, microsoftMessageTeamsChannelDefinition, asanaCommentTaskDefinition, asanaCreateTaskDefinition, asanaUpdateTaskDefinition, asanaSearchTasksDefinition, githubCreateOrUpdateFileDefinition, githubCreateBranchDefinition, githubCreatePullRequestDefinition, microsoftUpdateSpreadsheetDefinition, microsoftUpdateDocumentDefinition, microsoftCreateDocumentDefinition, microsoftGetDocumentDefinition, salesforceFetchSalesforceSchemaByObjectDefinition, firecrawlDeepResearchDefinition, jiraGetJiraIssuesByQueryDefinition, githubListPullRequestsDefinition, salesforceCreateRecordDefinition, ashbyCreateNoteDefinition, ashbyGetCandidateInfoDefinition, ashbyListCandidatesDefinition, ashbyListCandidateNotesDefinition, ashbySearchCandidatesDefinition, ashbyCreateCandidateDefinition, ashbyUpdateCandidateDefinition, ashbyAddCandidateToProjectDefinition, bingGetTopNSearchResultUrlsDefinition, gongGetGongTranscriptsDefinition, kandjiGetFVRecoveryKeyForDeviceDefinition, asanaListAsanaTasksByProjectDefinition, notionSearchByTitleDefinition, asanaGetTasksDetailsDefinition, jamfGetJamfComputerInventoryDefinition, jamfGetJamfFileVaultRecoveryKeyDefinition, oktaListOktaUsersDefinition, oktaGetOktaUserDefinition, oktaListOktaUserGroupsDefinition, oktaListOktaGroupsDefinition, oktaGetOktaGroupDefinition, oktaListOktaGroupMembersDefinition, oktaRemoveUserFromGroupDefinition, oktaAddUserToGroupDefinition, oktaResetPasswordDefinition, oktaResetMFADefinition, oktaListMFADefinition, jamfGetJamfUserComputerIdDefinition, jamfLockJamfComputerByIdDefinition, oktaTriggerOktaWorkflowDefinition, jiraOrgAssignJiraTicketDefinition, jiraOrgCreateJiraTicketDefinition, jiraOrgCommentJiraTicketDefinition, jiraOrgGetJiraTicketDetailsDefinition, jiraOrgGetJiraTicketHistoryDefinition, jiraOrgUpdateJiraTicketDetailsDefinition, jiraOrgUpdateJiraTicketStatusDefinition, jiraOrgGetJiraIssuesByQueryDefinition, googleOauthGetDriveFileContentByIdDefinition, googleOauthSearchDriveByQueryDefinition, } from "./autogen/templates.js";
2
- export const ACTION_GROUPS = {
3
- GENERIC: {
4
- description: "Generic utility actions",
5
- actions: [genericFillTemplateDefinition],
6
- },
7
- ASANA: {
8
- description: "Actions for interacting with Asana",
9
- actions: [
10
- asanaCommentTaskDefinition,
11
- asanaCreateTaskDefinition,
12
- asanaUpdateTaskDefinition,
13
- asanaSearchTasksDefinition,
14
- asanaListAsanaTasksByProjectDefinition,
15
- asanaGetTasksDetailsDefinition,
16
- ],
17
- },
18
- SLACK_LIST_CONVERSATIONS: {
19
- description: "Actions for interacting with Slack",
20
- actions: [
21
- slackSendMessageDefinition,
22
- slackGetChannelMessagesDefinition,
23
- slackCreateChannelDefinition,
24
- slackArchiveChannelDefinition,
25
- ],
26
- },
27
- CONFLUENCE: {
28
- description: "Action for interacting with Confluence",
29
- actions: [confluenceOverwritePageDefinition, confluenceFetchPageContentDefinition],
30
- },
31
- MATH_ADD: {
32
- description: "Action for adding two numbers",
33
- actions: [mathAddDefinition],
34
- },
35
- GOOGLE_MAPS: {
36
- description: "Action for interacting with Google Maps",
37
- actions: [googlemapsValidateAddressDefinition, googlemapsNearbysearchRestaurantsDefinition],
38
- },
39
- GOOGLE_DRIVE: {
40
- description: "Action for interacting with Google Drive",
41
- actions: [
42
- googleOauthCreateNewGoogleDocDefinition,
43
- googleOauthUpdateDocDefinition,
44
- googleOauthCreateSpreadsheetDefinition,
45
- googleOauthUpdateSpreadsheetDefinition,
46
- googleOauthCreatePresentationDefinition,
47
- googleOauthUpdatePresentationDefinition,
48
- googleOauthSearchDriveByKeywordsDefinition,
49
- googleOauthSearchDriveByQueryDefinition,
50
- googleOauthGetDriveFileContentByIdDefinition,
51
- ],
52
- },
53
- GOOGLE_CALENDAR: {
54
- description: "Actions for interacting with Google Calendar",
55
- actions: [
56
- googleOauthScheduleCalendarMeetingDefinition,
57
- googleOauthListCalendarsDefinition,
58
- googleOauthListCalendarEventsDefinition,
59
- googleOauthUpdateCalendarEventDefinition,
60
- googleOauthDeleteCalendarEventDefinition,
61
- ],
62
- },
63
- GMAIL: {
64
- description: "Actions for interacting with Gmail",
65
- actions: [googlemailSearchGmailMessagesDefinition, googlemailListGmailThreadsDefinition],
66
- },
67
- LINKEDIN_SHARE_POST: {
68
- description: "Action for creating a share post url on linkedin",
69
- actions: [linkedinCreateShareLinkedinPostUrlDefinition],
70
- },
71
- ZENDESK_ACTIONS: {
72
- description: "Actions for interacting with Zendesk",
73
- actions: [
74
- zendeskCreateZendeskTicketDefinition,
75
- zendeskListZendeskTicketsDefinition,
76
- zendeskGetTicketDetailsDefinition,
77
- zendeskUpdateTicketStatusDefinition,
78
- zendeskAddCommentToTicketDefinition,
79
- zendeskAssignTicketDefinition,
80
- ],
81
- },
82
- BING_SEARCH: {
83
- description: "Action for searching Bing",
84
- actions: [bingGetTopNSearchResultUrlsDefinition],
85
- },
86
- MONGO_INSERT_DOC: {
87
- description: "Action for inserting a document into a MongoDB collection",
88
- actions: [mongoInsertMongoDocDefinition],
89
- },
90
- SNOWFLAKE_ACTIONS: {
91
- description: "Action for getting content from a Snowflake table",
92
- actions: [snowflakeGetRowByFieldValueDefinition, snowflakeRunSnowflakeQueryDefinition],
93
- },
94
- JIRA_ACTIONS: {
95
- description: "Action for interacting with Jira tickets",
96
- actions: [
97
- jiraAssignJiraTicketDefinition,
98
- jiraCreateJiraTicketDefinition,
99
- jiraCommentJiraTicketDefinition,
100
- jiraGetJiraTicketDetailsDefinition,
101
- jiraGetJiraTicketHistoryDefinition,
102
- jiraUpdateJiraTicketDetailsDefinition,
103
- jiraUpdateJiraTicketStatusDefinition,
104
- jiraGetJiraIssuesByQueryDefinition,
105
- jiraGetServiceDesksDefinition,
106
- jiraCreateServiceDeskRequestDefinition,
107
- ],
108
- },
109
- JIRA_ORG_ACTIONS: {
110
- description: "Action for interacting with Jira tickets",
111
- actions: [
112
- jiraOrgAssignJiraTicketDefinition,
113
- jiraOrgCreateJiraTicketDefinition,
114
- jiraOrgCommentJiraTicketDefinition,
115
- jiraOrgGetJiraTicketDetailsDefinition,
116
- jiraOrgGetJiraTicketHistoryDefinition,
117
- jiraOrgUpdateJiraTicketDetailsDefinition,
118
- jiraOrgUpdateJiraTicketStatusDefinition,
119
- jiraOrgGetJiraIssuesByQueryDefinition,
120
- ],
121
- },
122
- OPENSTREETMAP_GET_LATITUDE_LONGITUDE_FROM_LOCATION: {
123
- description: "Action for getting the latitude and longitude of a location",
124
- actions: [openstreetmapGetLatitudeLongitudeFromLocationDefinition],
125
- },
126
- NWS_GET_FORECAST_FOR_LOCATION: {
127
- description: "Action for getting the weather forecast for a location",
128
- actions: [nwsGetForecastForLocationDefinition],
129
- },
130
- FIRECRAWL: {
131
- description: "Actions for interacting with Firecrawl",
132
- actions: [
133
- firecrawlScrapeUrlDefinition,
134
- firecrawlScrapeTweetDataWithNitterDefinition,
135
- firecrawlDeepResearchDefinition,
136
- ],
137
- },
138
- RESEND: {
139
- description: "Action for sending an email",
140
- actions: [resendSendEmailDefinition],
141
- },
142
- X: {
143
- description: "Actions for interacting with X(formerly twitter)",
144
- actions: [xCreateShareXPostUrlDefinition],
145
- },
146
- GONG: {
147
- description: "Actions for interacting with Gong",
148
- actions: [gongGetGongTranscriptsDefinition],
149
- },
150
- FINNHUB: {
151
- description: "Action for interacting with Finnhub for stock market data",
152
- actions: [finnhubSymbolLookupDefinition, finnhubGetBasicFinancialsDefinition],
153
- },
154
- JAMF: {
155
- description: "Actions for interacting with Jamf",
156
- actions: [
157
- jamfGetJamfComputerInventoryDefinition,
158
- jamfGetJamfFileVaultRecoveryKeyDefinition,
159
- jamfGetJamfUserComputerIdDefinition,
160
- jamfLockJamfComputerByIdDefinition,
161
- ],
162
- },
163
- LOOKER: {
164
- description: "Actions for interacting with Looker",
165
- actions: [lookerEnableUserByEmailDefinition],
166
- },
167
- SALESFORCE: {
168
- description: "Actions for interacting with Salesforce",
169
- actions: [
170
- salesforceUpdateRecordDefinition,
171
- salesforceCreateRecordDefinition,
172
- salesforceCreateCaseDefinition,
173
- salesforceGenerateSalesReportDefinition,
174
- salesforceGetRecordDefinition,
175
- salesforceGetSalesforceRecordsByQueryDefinition,
176
- salesforceFetchSalesforceSchemaByObjectDefinition,
177
- ],
178
- },
179
- MICROSOFT: {
180
- description: "Actions for interacting with Microsoft 365",
181
- actions: [
182
- microsoftMessageTeamsChatDefinition,
183
- microsoftMessageTeamsChannelDefinition,
184
- microsoftUpdateSpreadsheetDefinition,
185
- microsoftUpdateDocumentDefinition,
186
- microsoftCreateDocumentDefinition,
187
- microsoftGetDocumentDefinition,
188
- ],
189
- },
190
- KANDJI: {
191
- description: "Actions for interacting with Kandji",
192
- actions: [kandjiGetFVRecoveryKeyForDeviceDefinition],
193
- },
194
- GITHUB: {
195
- description: "Actions for interacting with GitHub",
196
- actions: [
197
- githubCreateOrUpdateFileDefinition,
198
- githubCreateBranchDefinition,
199
- githubCreatePullRequestDefinition,
200
- githubListPullRequestsDefinition,
201
- ],
202
- },
203
- ASHBY: {
204
- description: "Actions for interacting with Ashby",
205
- actions: [
206
- ashbyCreateNoteDefinition,
207
- ashbyGetCandidateInfoDefinition,
208
- ashbyListCandidatesDefinition,
209
- ashbyListCandidateNotesDefinition,
210
- ashbySearchCandidatesDefinition,
211
- ashbyCreateCandidateDefinition,
212
- ashbyUpdateCandidateDefinition,
213
- ashbyAddCandidateToProjectDefinition,
214
- ],
215
- },
216
- NOTION: {
217
- description: "Actions for interacting with Notion",
218
- actions: [notionSearchByTitleDefinition],
219
- },
220
- GOOGLE_GROUPS: {
221
- description: "Google Workspace Groups management actions",
222
- actions: [
223
- googleOauthListGroupsDefinition,
224
- googleOauthGetGroupDefinition,
225
- googleOauthListGroupMembersDefinition,
226
- googleOauthHasGroupMemberDefinition,
227
- googleOauthAddGroupMemberDefinition,
228
- googleOauthDeleteGroupMemberDefinition,
229
- ],
230
- },
231
- OKTA: {
232
- description: "Actions for interacting with Okta",
233
- actions: [
234
- oktaListOktaUsersDefinition,
235
- oktaGetOktaUserDefinition,
236
- oktaListOktaUserGroupsDefinition,
237
- oktaListOktaGroupsDefinition,
238
- oktaGetOktaGroupDefinition,
239
- oktaListOktaGroupMembersDefinition,
240
- oktaRemoveUserFromGroupDefinition,
241
- oktaAddUserToGroupDefinition,
242
- oktaResetPasswordDefinition,
243
- oktaResetMFADefinition,
244
- oktaListMFADefinition,
245
- oktaTriggerOktaWorkflowDefinition,
246
- ],
247
- },
248
- };
@@ -1,3 +0,0 @@
1
- import type { credalCallCopilotFunction } from "../../autogen/types";
2
- declare const callCopilot: credalCallCopilotFunction;
3
- export default callCopilot;
@@ -1,36 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
- Object.defineProperty(exports, "__esModule", { value: true });
12
- const sdk_1 = require("@credal/sdk");
13
- const callCopilot = (_a) => __awaiter(void 0, [_a], void 0, function* ({ params, authParams, }) {
14
- var _b;
15
- const requestBody = {
16
- agentId: params.agentId,
17
- query: params.query,
18
- userEmail: params.userEmail,
19
- };
20
- const baseUrl = (_b = authParams.baseUrl) !== null && _b !== void 0 ? _b : "https://app.credal.ai/api";
21
- const client = new sdk_1.CredalClient({ environment: baseUrl, apiKey: authParams.apiKey });
22
- const response = yield client.copilots.sendMessage({
23
- agentId: requestBody.agentId,
24
- message: requestBody.query,
25
- userEmail: requestBody.userEmail,
26
- });
27
- return {
28
- response: response.sendChatResult.type === "ai_response_result"
29
- ? response.sendChatResult.response.message
30
- : "Error getting response",
31
- referencedSources: response.sendChatResult.type === "ai_response_result" ? response.sendChatResult.referencedSources : [],
32
- sourcesInDataContext: response.sendChatResult.type === "ai_response_result" ? response.sendChatResult.sourcesInDataContext : [],
33
- webSearchResults: response.sendChatResult.type === "ai_response_result" ? response.sendChatResult.webSearchResults : [],
34
- };
35
- });
36
- exports.default = callCopilot;
@@ -1 +0,0 @@
1
- export * as add from "./add";
@@ -1,37 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || (function () {
19
- var ownKeys = function(o) {
20
- ownKeys = Object.getOwnPropertyNames || function (o) {
21
- var ar = [];
22
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
- return ar;
24
- };
25
- return ownKeys(o);
26
- };
27
- return function (mod) {
28
- if (mod && mod.__esModule) return mod;
29
- var result = {};
30
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
- __setModuleDefault(result, mod);
32
- return result;
33
- };
34
- })();
35
- Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.add = void 0;
37
- exports.add = __importStar(require("./add"));
@@ -1,3 +0,0 @@
1
- import { salesforceGetSalesforceRecordsByQueryFunction } from "../../autogen/types";
2
- declare const getSalesforceRecordByQuery: salesforceGetSalesforceRecordsByQueryFunction;
3
- export default getSalesforceRecordByQuery;
@@ -1,43 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
- Object.defineProperty(exports, "__esModule", { value: true });
12
- const axiosClient_1 = require("../../util/axiosClient");
13
- const getSalesforceRecordByQuery = (_a) => __awaiter(void 0, [_a], void 0, function* ({ params, authParams, }) {
14
- const { authToken, baseUrl } = authParams;
15
- const { query, limit } = params;
16
- if (!authToken || !baseUrl) {
17
- return {
18
- success: false,
19
- error: "authToken and baseUrl are required for Salesforce API",
20
- };
21
- }
22
- // The API limits the maximum number of records returned to 2000, the limit lets the user set a smaller custom limit
23
- const url = `${baseUrl}/services/data/v56.0/query/?q=${encodeURIComponent(query + " LIMIT " + (limit != undefined && limit <= 2000 ? limit : 2000))}`;
24
- try {
25
- const response = yield axiosClient_1.axiosClient.get(url, {
26
- headers: {
27
- Authorization: `Bearer ${authToken}`,
28
- },
29
- });
30
- return {
31
- success: true,
32
- records: response.data,
33
- };
34
- }
35
- catch (error) {
36
- console.error("Error retrieving Salesforce record:", error);
37
- return {
38
- success: false,
39
- error: error instanceof Error ? error.message : "An unknown error occurred",
40
- };
41
- }
42
- });
43
- exports.default = getSalesforceRecordByQuery;
@@ -1,3 +0,0 @@
1
- import type { slackArchiveChannelFunction } from "../../autogen/types.js";
2
- declare const archiveChannel: slackArchiveChannelFunction;
3
- export default archiveChannel;
@@ -1,35 +0,0 @@
1
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
- return new (P || (P = Promise))(function (resolve, reject) {
4
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
- step((generator = generator.apply(thisArg, _arguments || [])).next());
8
- });
9
- };
10
- import { WebClient } from "@slack/web-api";
11
- import { MISSING_AUTH_TOKEN } from "../../util/missingAuthConstants.js";
12
- const archiveChannel = (_a) => __awaiter(void 0, [_a], void 0, function* ({ params, authParams, }) {
13
- if (!authParams.authToken) {
14
- throw new Error(MISSING_AUTH_TOKEN);
15
- }
16
- try {
17
- const client = new WebClient(authParams.authToken);
18
- const { channelId } = params;
19
- const result = yield client.conversations.archive({ channel: channelId });
20
- if (!result.ok) {
21
- return {
22
- success: false,
23
- error: result.error || "Unknown error archiving channel",
24
- };
25
- }
26
- return { success: true };
27
- }
28
- catch (error) {
29
- return {
30
- success: false,
31
- error: error instanceof Error ? error.message : "Unknown error archiving channel",
32
- };
33
- }
34
- });
35
- export default archiveChannel;
@@ -1 +0,0 @@
1
- export * as listConversations from "./listConversations";
@@ -1,37 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || (function () {
19
- var ownKeys = function(o) {
20
- ownKeys = Object.getOwnPropertyNames || function (o) {
21
- var ar = [];
22
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
- return ar;
24
- };
25
- return ownKeys(o);
26
- };
27
- return function (mod) {
28
- if (mod && mod.__esModule) return mod;
29
- var result = {};
30
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
- __setModuleDefault(result, mod);
32
- return result;
33
- };
34
- })();
35
- Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.listConversations = void 0;
37
- exports.listConversations = __importStar(require("./listConversations"));
@@ -1,3 +0,0 @@
1
- import type { slackListConversationsFunction } from "../../autogen/types";
2
- declare const slackListConversations: slackListConversationsFunction;
3
- export default slackListConversations;
@@ -1,41 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
- Object.defineProperty(exports, "__esModule", { value: true });
12
- const web_api_1 = require("@slack/web-api");
13
- const helpers_1 = require("./helpers");
14
- const slackListConversations = (_a) => __awaiter(void 0, [_a], void 0, function* ({ authParams, }) {
15
- const client = new web_api_1.WebClient(authParams.authToken);
16
- try {
17
- const allChannels = yield (0, helpers_1.getSlackChannels)(client);
18
- const filteredChannels = [];
19
- for (const channel of allChannels) {
20
- if (channel.name && channel.topic && channel.topic.value && channel.purpose && channel.purpose.value) {
21
- const purpose = channel.purpose.value;
22
- const topic = channel.topic.value;
23
- const name = channel.name;
24
- filteredChannels.push(Object.assign(Object.assign({}, channel), { purpose, topic, name }));
25
- }
26
- }
27
- return {
28
- channels: filteredChannels,
29
- };
30
- }
31
- catch (error) {
32
- if (error instanceof Error) {
33
- // Enhance error with more context
34
- throw new Error(`Failed to list Slack conversations: ${error.message}`);
35
- }
36
- else {
37
- throw error;
38
- }
39
- }
40
- });
41
- exports.default = slackListConversations;