@credal/actions 0.2.84 → 0.2.87
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/dist/actions/actionMapper.js +1 -7
- package/dist/actions/autogen/templates.d.ts +0 -1
- package/dist/actions/autogen/templates.js +27 -33
- package/dist/actions/autogen/types.d.ts +32 -29
- package/dist/actions/autogen/types.js +23 -8
- package/dist/actions/providers/google-oauth/editAGoogleCalendarEvent.js +11 -3
- package/dist/actions/providers/google-oauth/getDriveFileContentById.js +46 -50
- package/dist/actions/providers/google-oauth/listCalendarEvents.js +17 -6
- package/dist/actions/providers/google-oauth/scheduleCalendarMeeting.js +3 -7
- package/dist/actions/providers/google-oauth/searchDriveByQuery.js +4 -6
- package/dist/actions/providers/google-oauth/updateCalendarEvent.js +10 -2
- package/dist/actions/providers/slack/createChannel.js +20 -0
- package/dist/actions/providers/slack/getChannelMessages.js +1 -1
- package/dist/actions/providers/slack/helpers.js +1 -0
- package/dist/actions/providers/slack/sendMessage.js +12 -5
- package/dist/actions/providers/snowflake/runSnowflakeQuery.js +6 -4
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { genericFillTemplateParamsSchema, genericFillTemplateOutputSchema, confluenceOverwritePageParamsSchema, confluenceOverwritePageOutputSchema, googlemapsValidateAddressOutputSchema, googlemapsValidateAddressParamsSchema, googleOauthCreateNewGoogleDocParamsSchema, googleOauthCreateNewGoogleDocOutputSchema, mathAddOutputSchema, mathAddParamsSchema, mongoInsertMongoDocOutputSchema, mongoInsertMongoDocParamsSchema, slackSendMessageOutputSchema, slackSendMessageParamsSchema, slackGetChannelMessagesOutputSchema, slackGetChannelMessagesParamsSchema, slackArchiveChannelParamsSchema, slackArchiveChannelOutputSchema, 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, jiraGetServiceDesksParamsSchema, jiraGetServiceDesksOutputSchema, 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, googleOauthScheduleCalendarMeetingParamsSchema, googleOauthScheduleCalendarMeetingOutputSchema, googleOauthListCalendarsParamsSchema, googleOauthListCalendarsOutputSchema, googleOauthListCalendarEventsParamsSchema, googleOauthListCalendarEventsOutputSchema, googleOauthUpdateCalendarEventParamsSchema, googleOauthUpdateCalendarEventOutputSchema, googleOauthDeleteCalendarEventParamsSchema, googleOauthDeleteCalendarEventOutputSchema, googleOauthEditAGoogleCalendarEventParamsSchema, googleOauthEditAGoogleCalendarEventOutputSchema, googleOauthCreatePresentationParamsSchema, googleOauthCreatePresentationOutputSchema, googleOauthUpdatePresentationParamsSchema, googleOauthUpdatePresentationOutputSchema, googleOauthSearchDriveByKeywordsParamsSchema, googleOauthSearchDriveByKeywordsOutputSchema, googleOauthListGroupsOutputSchema, googleOauthListGroupsParamsSchema, googleOauthGetGroupOutputSchema, googleOauthGetGroupParamsSchema, googleOauthListGroupMembersOutputSchema, googleOauthListGroupMembersParamsSchema, googleOauthHasGroupMemberOutputSchema, googleOauthHasGroupMemberParamsSchema, googleOauthAddGroupMemberOutputSchema, googleOauthAddGroupMemberParamsSchema, googleOauthDeleteGroupMemberOutputSchema, googleOauthDeleteGroupMemberParamsSchema, gongGetGongTranscriptsParamsSchema, gongGetGongTranscriptsOutputSchema, ashbyCreateNoteParamsSchema, ashbyCreateNoteOutputSchema, ashbyGetCandidateInfoParamsSchema, ashbyGetCandidateInfoOutputSchema, salesforceUpdateRecordParamsSchema, salesforceUpdateRecordOutputSchema, salesforceCreateCaseParamsSchema, salesforceCreateCaseOutputSchema, salesforceGenerateSalesReportParamsSchema, salesforceGenerateSalesReportOutputSchema, salesforceGetRecordParamsSchema, salesforceGetRecordOutputSchema, ashbyListCandidatesParamsSchema, ashbyListCandidatesOutputSchema, ashbyListCandidateNotesParamsSchema, ashbyListCandidateNotesOutputSchema, ashbySearchCandidatesParamsSchema, ashbySearchCandidatesOutputSchema, ashbyCreateCandidateParamsSchema, ashbyCreateCandidateOutputSchema, ashbyUpdateCandidateParamsSchema, ashbyUpdateCandidateOutputSchema, microsoftMessageTeamsChatParamsSchema, microsoftMessageTeamsChatOutputSchema, microsoftMessageTeamsChannelParamsSchema, microsoftMessageTeamsChannelOutputSchema, salesforceGetSalesforceRecordsByQueryParamsSchema, salesforceGetSalesforceRecordsByQueryOutputSchema, asanaCommentTaskParamsSchema, asanaCommentTaskOutputSchema, asanaCreateTaskParamsSchema, asanaCreateTaskOutputSchema, asanaUpdateTaskParamsSchema, asanaUpdateTaskOutputSchema, githubCreateOrUpdateFileParamsSchema, githubCreateOrUpdateFileOutputSchema, githubCreateBranchParamsSchema, githubCreateBranchOutputSchema, githubCreatePullRequestParamsSchema, githubCreatePullRequestOutputSchema, microsoftUpdateSpreadsheetParamsSchema, microsoftUpdateSpreadsheetOutputSchema, microsoftUpdateDocumentParamsSchema, microsoftUpdateDocumentOutputSchema, microsoftGetDocumentParamsSchema, microsoftGetDocumentOutputSchema, salesforceFetchSalesforceSchemaByObjectParamsSchema, salesforceFetchSalesforceSchemaByObjectOutputSchema, githubListPullRequestsParamsSchema, githubListPullRequestsOutputSchema, jiraGetJiraIssuesByQueryOutputSchema, jiraGetJiraIssuesByQueryParamsSchema, salesforceCreateRecordParamsSchema, salesforceCreateRecordOutputSchema, firecrawlDeepResearchParamsSchema, firecrawlDeepResearchOutputSchema, bingGetTopNSearchResultUrlsParamsSchema, bingGetTopNSearchResultUrlsOutputSchema, ashbyAddCandidateToProjectParamsSchema, ashbyAddCandidateToProjectOutputSchema, microsoftCreateDocumentParamsSchema, microsoftCreateDocumentOutputSchema, kandjiGetFVRecoveryKeyForDeviceParamsSchema, kandjiGetFVRecoveryKeyForDeviceOutputSchema, asanaListAsanaTasksByProjectParamsSchema, asanaListAsanaTasksByProjectOutputSchema, asanaSearchTasksParamsSchema, asanaSearchTasksOutputSchema, asanaGetTasksDetailsParamsSchema, asanaGetTasksDetailsOutputSchema, notionSearchByTitleParamsSchema, notionSearchByTitleOutputSchema, jamfGetJamfComputerInventoryParamsSchema, jamfGetJamfComputerInventoryOutputSchema, jamfGetJamfFileVaultRecoveryKeyParamsSchema, jamfGetJamfFileVaultRecoveryKeyOutputSchema, googlemailSearchGmailMessagesOutputSchema, googlemailSearchGmailMessagesParamsSchema, googlemailListGmailThreadsOutputSchema, googlemailListGmailThreadsParamsSchema, oktaListOktaUsersParamsSchema, oktaListOktaUsersOutputSchema, oktaGetOktaUserParamsSchema, oktaGetOktaUserOutputSchema, oktaListOktaUserGroupsParamsSchema, oktaListOktaUserGroupsOutputSchema, oktaListOktaGroupsParamsSchema, oktaListOktaGroupsOutputSchema, oktaGetOktaGroupParamsSchema, oktaGetOktaGroupOutputSchema, oktaListOktaGroupMembersParamsSchema, oktaListOktaGroupMembersOutputSchema, oktaRemoveUserFromGroupParamsSchema, oktaRemoveUserFromGroupOutputSchema, oktaAddUserToGroupParamsSchema, oktaAddUserToGroupOutputSchema, oktaResetPasswordParamsSchema, oktaResetPasswordOutputSchema, oktaResetMFAParamsSchema, oktaResetMFAOutputSchema, oktaListMFAParamsSchema, oktaListMFAOutputSchema, jamfGetJamfUserComputerIdParamsSchema, jamfGetJamfUserComputerIdOutputSchema, jamfLockJamfComputerByIdParamsSchema, jamfLockJamfComputerByIdOutputSchema, oktaTriggerOktaWorkflowParamsSchema, oktaTriggerOktaWorkflowOutputSchema, gitlabSearchGroupOutputSchema, gitlabSearchGroupParamsSchema, githubSearchRepositoryOutputSchema, githubSearchRepositoryParamsSchema, githubSearchOrganizationOutputSchema, githubSearchOrganizationParamsSchema, salesforceSearchSalesforceRecordsParamsSchema, salesforceSearchSalesforceRecordsOutputSchema, googleOauthGetDriveFileContentByIdOutputSchema, googleOauthGetDriveFileContentByIdParamsSchema, googleOauthSearchDriveByQueryOutputSchema, googleOauthSearchDriveByQueryParamsSchema, googleOauthSearchDriveByQueryAndGetFileContentParamsSchema, googleOauthSearchDriveByQueryAndGetFileContentOutputSchema, googleOauthQueryGoogleBigQueryParamsSchema, googleOauthQueryGoogleBigQueryOutputSchema, githubGetFileContentParamsSchema, githubGetFileContentOutputSchema, githubListDirectoryOutputSchema, githubListDirectoryParamsSchema, 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, jiraPublicCommentOnServiceDeskRequestParamsSchema, jiraPublicCommentOnServiceDeskRequestOutputSchema, googlemailSendGmailParamsSchema, googlemailSendGmailOutputSchema, gitlabListDirectoryParamsSchema, gitlabListDirectoryOutputSchema, firecrawlSearchAndScrapeOutputSchema, firecrawlSearchAndScrapeParamsSchema, firecrawlGetTopNSearchResultUrlsParamsSchema, firecrawlGetTopNSearchResultUrlsOutputSchema, } 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, jiraGetServiceDesksParamsSchema, jiraGetServiceDesksOutputSchema, 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, googleOauthScheduleCalendarMeetingParamsSchema, googleOauthScheduleCalendarMeetingOutputSchema, googleOauthListCalendarsParamsSchema, googleOauthListCalendarsOutputSchema, googleOauthListCalendarEventsParamsSchema, googleOauthListCalendarEventsOutputSchema, googleOauthUpdateCalendarEventParamsSchema, googleOauthUpdateCalendarEventOutputSchema, googleOauthDeleteCalendarEventParamsSchema, googleOauthDeleteCalendarEventOutputSchema, googleOauthEditAGoogleCalendarEventParamsSchema, googleOauthEditAGoogleCalendarEventOutputSchema, googleOauthCreatePresentationParamsSchema, googleOauthCreatePresentationOutputSchema, googleOauthUpdatePresentationParamsSchema, googleOauthUpdatePresentationOutputSchema, googleOauthSearchDriveByKeywordsParamsSchema, googleOauthSearchDriveByKeywordsOutputSchema, googleOauthListGroupsOutputSchema, googleOauthListGroupsParamsSchema, googleOauthGetGroupOutputSchema, googleOauthGetGroupParamsSchema, googleOauthListGroupMembersOutputSchema, googleOauthListGroupMembersParamsSchema, googleOauthHasGroupMemberOutputSchema, googleOauthHasGroupMemberParamsSchema, googleOauthAddGroupMemberOutputSchema, googleOauthAddGroupMemberParamsSchema, googleOauthDeleteGroupMemberOutputSchema, googleOauthDeleteGroupMemberParamsSchema, gongGetGongTranscriptsParamsSchema, gongGetGongTranscriptsOutputSchema, ashbyCreateNoteParamsSchema, ashbyCreateNoteOutputSchema, ashbyGetCandidateInfoParamsSchema, ashbyGetCandidateInfoOutputSchema, salesforceUpdateRecordParamsSchema, salesforceUpdateRecordOutputSchema, salesforceCreateCaseParamsSchema, salesforceCreateCaseOutputSchema, salesforceGenerateSalesReportParamsSchema, salesforceGenerateSalesReportOutputSchema, salesforceGetRecordParamsSchema, salesforceGetRecordOutputSchema, ashbyListCandidatesParamsSchema, ashbyListCandidatesOutputSchema, ashbyListCandidateNotesParamsSchema, ashbyListCandidateNotesOutputSchema, ashbySearchCandidatesParamsSchema, ashbySearchCandidatesOutputSchema, ashbyCreateCandidateParamsSchema, ashbyCreateCandidateOutputSchema, ashbyUpdateCandidateParamsSchema, ashbyUpdateCandidateOutputSchema, microsoftMessageTeamsChatParamsSchema, microsoftMessageTeamsChatOutputSchema, microsoftMessageTeamsChannelParamsSchema, microsoftMessageTeamsChannelOutputSchema, salesforceGetSalesforceRecordsByQueryParamsSchema, salesforceGetSalesforceRecordsByQueryOutputSchema, asanaCommentTaskParamsSchema, asanaCommentTaskOutputSchema, asanaCreateTaskParamsSchema, asanaCreateTaskOutputSchema, asanaUpdateTaskParamsSchema, asanaUpdateTaskOutputSchema, githubCreateOrUpdateFileParamsSchema, githubCreateOrUpdateFileOutputSchema, githubCreateBranchParamsSchema, githubCreateBranchOutputSchema, githubCreatePullRequestParamsSchema, githubCreatePullRequestOutputSchema, microsoftUpdateSpreadsheetParamsSchema, microsoftUpdateSpreadsheetOutputSchema, microsoftUpdateDocumentParamsSchema, microsoftUpdateDocumentOutputSchema, microsoftGetDocumentParamsSchema, microsoftGetDocumentOutputSchema, salesforceFetchSalesforceSchemaByObjectParamsSchema, salesforceFetchSalesforceSchemaByObjectOutputSchema, githubListPullRequestsParamsSchema, githubListPullRequestsOutputSchema, jiraGetJiraIssuesByQueryOutputSchema, jiraGetJiraIssuesByQueryParamsSchema, salesforceCreateRecordParamsSchema, salesforceCreateRecordOutputSchema, firecrawlDeepResearchParamsSchema, firecrawlDeepResearchOutputSchema, bingGetTopNSearchResultUrlsParamsSchema, bingGetTopNSearchResultUrlsOutputSchema, ashbyAddCandidateToProjectParamsSchema, ashbyAddCandidateToProjectOutputSchema, microsoftCreateDocumentParamsSchema, microsoftCreateDocumentOutputSchema, kandjiGetFVRecoveryKeyForDeviceParamsSchema, kandjiGetFVRecoveryKeyForDeviceOutputSchema, asanaListAsanaTasksByProjectParamsSchema, asanaListAsanaTasksByProjectOutputSchema, asanaSearchTasksParamsSchema, asanaSearchTasksOutputSchema, asanaGetTasksDetailsParamsSchema, asanaGetTasksDetailsOutputSchema, notionSearchByTitleParamsSchema, notionSearchByTitleOutputSchema, jamfGetJamfComputerInventoryParamsSchema, jamfGetJamfComputerInventoryOutputSchema, jamfGetJamfFileVaultRecoveryKeyParamsSchema, jamfGetJamfFileVaultRecoveryKeyOutputSchema, googlemailSearchGmailMessagesOutputSchema, googlemailSearchGmailMessagesParamsSchema, googlemailListGmailThreadsOutputSchema, googlemailListGmailThreadsParamsSchema, oktaListOktaUsersParamsSchema, oktaListOktaUsersOutputSchema, oktaGetOktaUserParamsSchema, oktaGetOktaUserOutputSchema, oktaListOktaUserGroupsParamsSchema, oktaListOktaUserGroupsOutputSchema, oktaListOktaGroupsParamsSchema, oktaListOktaGroupsOutputSchema, oktaGetOktaGroupParamsSchema, oktaGetOktaGroupOutputSchema, oktaListOktaGroupMembersParamsSchema, oktaListOktaGroupMembersOutputSchema, oktaRemoveUserFromGroupParamsSchema, oktaRemoveUserFromGroupOutputSchema, oktaAddUserToGroupParamsSchema, oktaAddUserToGroupOutputSchema, oktaResetPasswordParamsSchema, oktaResetPasswordOutputSchema, oktaResetMFAParamsSchema, oktaResetMFAOutputSchema, oktaListMFAParamsSchema, oktaListMFAOutputSchema, jamfGetJamfUserComputerIdParamsSchema, jamfGetJamfUserComputerIdOutputSchema, jamfLockJamfComputerByIdParamsSchema, jamfLockJamfComputerByIdOutputSchema, oktaTriggerOktaWorkflowParamsSchema, oktaTriggerOktaWorkflowOutputSchema, gitlabSearchGroupOutputSchema, gitlabSearchGroupParamsSchema, githubSearchRepositoryOutputSchema, githubSearchRepositoryParamsSchema, githubSearchOrganizationOutputSchema, githubSearchOrganizationParamsSchema, salesforceSearchSalesforceRecordsParamsSchema, salesforceSearchSalesforceRecordsOutputSchema, googleOauthGetDriveFileContentByIdOutputSchema, googleOauthGetDriveFileContentByIdParamsSchema, googleOauthSearchDriveByQueryOutputSchema, googleOauthSearchDriveByQueryParamsSchema, googleOauthSearchDriveByQueryAndGetFileContentParamsSchema, googleOauthSearchDriveByQueryAndGetFileContentOutputSchema, googleOauthQueryGoogleBigQueryParamsSchema, googleOauthQueryGoogleBigQueryOutputSchema, githubGetFileContentParamsSchema, githubGetFileContentOutputSchema, githubListDirectoryOutputSchema, githubListDirectoryParamsSchema, 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, jiraPublicCommentOnServiceDeskRequestParamsSchema, jiraPublicCommentOnServiceDeskRequestOutputSchema, googlemailSendGmailParamsSchema, googlemailSendGmailOutputSchema, gitlabListDirectoryParamsSchema, gitlabListDirectoryOutputSchema, firecrawlSearchAndScrapeOutputSchema, firecrawlSearchAndScrapeParamsSchema, firecrawlGetTopNSearchResultUrlsParamsSchema, firecrawlGetTopNSearchResultUrlsOutputSchema, } 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";
|
|
@@ -107,7 +107,6 @@ import resetPassword from "./providers/okta/resetPassword.js";
|
|
|
107
107
|
import resetMFA from "./providers/okta/resetMFA.js";
|
|
108
108
|
import listMFA from "./providers/okta/listMFA.js";
|
|
109
109
|
import createChannel from "./providers/slack/createChannel.js";
|
|
110
|
-
import archiveChannel from "./providers/slack/archiveChannel.js";
|
|
111
110
|
import getJamfUserComputerId from "./providers/jamf/getJamfUserComputerId.js";
|
|
112
111
|
import lockJamfComputerById from "./providers/jamf/lockJamfComputerById.js";
|
|
113
112
|
import triggerOktaWorkflow from "./providers/okta/triggerOktaWorkflow.js";
|
|
@@ -285,11 +284,6 @@ export const ActionMapper = {
|
|
|
285
284
|
paramsSchema: slackCreateChannelParamsSchema,
|
|
286
285
|
outputSchema: slackCreateChannelOutputSchema,
|
|
287
286
|
},
|
|
288
|
-
archiveChannel: {
|
|
289
|
-
fn: archiveChannel,
|
|
290
|
-
paramsSchema: slackArchiveChannelParamsSchema,
|
|
291
|
-
outputSchema: slackArchiveChannelOutputSchema,
|
|
292
|
-
},
|
|
293
287
|
},
|
|
294
288
|
confluence: {
|
|
295
289
|
overwritePage: {
|
|
@@ -7,7 +7,6 @@ export declare const asanaUpdateTaskDefinition: ActionTemplate;
|
|
|
7
7
|
export declare const asanaSearchTasksDefinition: ActionTemplate;
|
|
8
8
|
export declare const asanaGetTasksDetailsDefinition: ActionTemplate;
|
|
9
9
|
export declare const slackCreateChannelDefinition: ActionTemplate;
|
|
10
|
-
export declare const slackArchiveChannelDefinition: ActionTemplate;
|
|
11
10
|
export declare const slackSendMessageDefinition: ActionTemplate;
|
|
12
11
|
export declare const slackGetChannelMessagesDefinition: ActionTemplate;
|
|
13
12
|
export declare const mathAddDefinition: ActionTemplate;
|
|
@@ -544,43 +544,17 @@ export const slackCreateChannelDefinition = {
|
|
|
544
544
|
name: "createChannel",
|
|
545
545
|
provider: "slack",
|
|
546
546
|
};
|
|
547
|
-
export const slackArchiveChannelDefinition = {
|
|
548
|
-
description: "Archives a Slack channel using a bot token, joins the channel to archive if not already a member",
|
|
549
|
-
scopes: ["channels:manage"],
|
|
550
|
-
parameters: {
|
|
551
|
-
type: "object",
|
|
552
|
-
required: ["channelName"],
|
|
553
|
-
properties: {
|
|
554
|
-
channelName: {
|
|
555
|
-
type: "string",
|
|
556
|
-
description: "The name of the channel to archive",
|
|
557
|
-
},
|
|
558
|
-
},
|
|
559
|
-
},
|
|
560
|
-
output: {
|
|
561
|
-
type: "object",
|
|
562
|
-
required: ["success"],
|
|
563
|
-
properties: {
|
|
564
|
-
success: {
|
|
565
|
-
type: "boolean",
|
|
566
|
-
description: "Whether the channel was archived successfully",
|
|
567
|
-
},
|
|
568
|
-
error: {
|
|
569
|
-
type: "string",
|
|
570
|
-
description: "The error that occurred if the channel was not archived successfully",
|
|
571
|
-
},
|
|
572
|
-
},
|
|
573
|
-
},
|
|
574
|
-
name: "archiveChannel",
|
|
575
|
-
provider: "slack",
|
|
576
|
-
};
|
|
577
547
|
export const slackSendMessageDefinition = {
|
|
578
548
|
description: "Sends a message to a Slack channel",
|
|
579
549
|
scopes: ["chat:write"],
|
|
580
550
|
parameters: {
|
|
581
551
|
type: "object",
|
|
582
|
-
required: ["
|
|
552
|
+
required: ["message"],
|
|
583
553
|
properties: {
|
|
554
|
+
channelId: {
|
|
555
|
+
type: "string",
|
|
556
|
+
description: "The ID of the channel to send the message to",
|
|
557
|
+
},
|
|
584
558
|
channelName: {
|
|
585
559
|
type: "string",
|
|
586
560
|
description: "The name of the Slack channel to send the message to (e.g. general, alerts)",
|
|
@@ -2814,6 +2788,10 @@ export const snowflakeRunSnowflakeQueryDefinition = {
|
|
|
2814
2788
|
type: "string",
|
|
2815
2789
|
description: "The name of the Snowflake account",
|
|
2816
2790
|
},
|
|
2791
|
+
username: {
|
|
2792
|
+
type: "string",
|
|
2793
|
+
description: "The username of the Snowflake Credential (optional)",
|
|
2794
|
+
},
|
|
2817
2795
|
outputFormat: {
|
|
2818
2796
|
type: "string",
|
|
2819
2797
|
description: "The format of the output",
|
|
@@ -4422,6 +4400,10 @@ export const googleOauthScheduleCalendarMeetingDefinition = {
|
|
|
4422
4400
|
type: "boolean",
|
|
4423
4401
|
description: "Whether to use Google Meet for the meeting",
|
|
4424
4402
|
},
|
|
4403
|
+
timeZone: {
|
|
4404
|
+
type: "string",
|
|
4405
|
+
description: "The time zone for the meeting, IANA Time Zone identifier (e.g., 'America/New_York')",
|
|
4406
|
+
},
|
|
4425
4407
|
},
|
|
4426
4408
|
},
|
|
4427
4409
|
output: {
|
|
@@ -4623,6 +4605,10 @@ export const googleOauthListCalendarEventsDefinition = {
|
|
|
4623
4605
|
},
|
|
4624
4606
|
},
|
|
4625
4607
|
},
|
|
4608
|
+
timezone: {
|
|
4609
|
+
type: "string",
|
|
4610
|
+
description: "Timezone the user is currently based out of, given by their calender, follows the IANA Time Zone Database format, defaults to UTC if not defined",
|
|
4611
|
+
},
|
|
4626
4612
|
error: {
|
|
4627
4613
|
type: "string",
|
|
4628
4614
|
description: "Error message if listing failed",
|
|
@@ -4697,6 +4683,10 @@ export const googleOauthUpdateCalendarEventDefinition = {
|
|
|
4697
4683
|
},
|
|
4698
4684
|
},
|
|
4699
4685
|
},
|
|
4686
|
+
timeZone: {
|
|
4687
|
+
type: "string",
|
|
4688
|
+
description: "The time zone for the event, IANA Time Zone identifier (e.g., 'America/New_York')",
|
|
4689
|
+
},
|
|
4700
4690
|
},
|
|
4701
4691
|
},
|
|
4702
4692
|
},
|
|
@@ -4787,6 +4777,10 @@ export const googleOauthEditAGoogleCalendarEventDefinition = {
|
|
|
4787
4777
|
},
|
|
4788
4778
|
},
|
|
4789
4779
|
},
|
|
4780
|
+
timeZone: {
|
|
4781
|
+
type: "string",
|
|
4782
|
+
description: "The time zone for the event, IANA Time Zone identifier (e.g., 'America/New_York')",
|
|
4783
|
+
},
|
|
4790
4784
|
},
|
|
4791
4785
|
},
|
|
4792
4786
|
output: {
|
|
@@ -6845,7 +6839,7 @@ export const googleOauthSearchDriveByQueryAndGetFileContentDefinition = {
|
|
|
6845
6839
|
properties: {
|
|
6846
6840
|
query: {
|
|
6847
6841
|
type: "string",
|
|
6848
|
-
description: "
|
|
6842
|
+
description: "Google Drive API search syntax, eg \"fullText contains 'Valentine\\'s Day'\"",
|
|
6849
6843
|
},
|
|
6850
6844
|
limit: {
|
|
6851
6845
|
type: "number",
|
|
@@ -6857,7 +6851,7 @@ export const googleOauthSearchDriveByQueryAndGetFileContentDefinition = {
|
|
|
6857
6851
|
},
|
|
6858
6852
|
searchDriveByDrive: {
|
|
6859
6853
|
type: "boolean",
|
|
6860
|
-
description: "
|
|
6854
|
+
description: "Search drive by drive or run a general search",
|
|
6861
6855
|
},
|
|
6862
6856
|
orderByQuery: {
|
|
6863
6857
|
type: "string",
|
|
@@ -58,12 +58,14 @@ export declare const AuthParamsSchema: z.ZodObject<{
|
|
|
58
58
|
tenantId: z.ZodOptional<z.ZodString>;
|
|
59
59
|
refreshToken: z.ZodOptional<z.ZodString>;
|
|
60
60
|
redirectUri: z.ZodOptional<z.ZodString>;
|
|
61
|
+
userEmail: z.ZodOptional<z.ZodString>;
|
|
61
62
|
}, "strip", z.ZodTypeAny, {
|
|
63
|
+
userEmail?: string | undefined;
|
|
62
64
|
subdomain?: string | undefined;
|
|
65
|
+
username?: string | undefined;
|
|
63
66
|
authToken?: string | undefined;
|
|
64
67
|
baseUrl?: string | undefined;
|
|
65
68
|
apiKey?: string | undefined;
|
|
66
|
-
username?: string | undefined;
|
|
67
69
|
userAgent?: string | undefined;
|
|
68
70
|
emailFrom?: string | undefined;
|
|
69
71
|
emailReplyTo?: string | undefined;
|
|
@@ -78,11 +80,12 @@ export declare const AuthParamsSchema: z.ZodObject<{
|
|
|
78
80
|
refreshToken?: string | undefined;
|
|
79
81
|
redirectUri?: string | undefined;
|
|
80
82
|
}, {
|
|
83
|
+
userEmail?: string | undefined;
|
|
81
84
|
subdomain?: string | undefined;
|
|
85
|
+
username?: string | undefined;
|
|
82
86
|
authToken?: string | undefined;
|
|
83
87
|
baseUrl?: string | undefined;
|
|
84
88
|
apiKey?: string | undefined;
|
|
85
|
-
username?: string | undefined;
|
|
86
89
|
userAgent?: string | undefined;
|
|
87
90
|
emailFrom?: string | undefined;
|
|
88
91
|
emailReplyTo?: string | undefined;
|
|
@@ -722,35 +725,18 @@ export declare const slackCreateChannelOutputSchema: z.ZodObject<{
|
|
|
722
725
|
}>;
|
|
723
726
|
export type slackCreateChannelOutputType = z.infer<typeof slackCreateChannelOutputSchema>;
|
|
724
727
|
export type slackCreateChannelFunction = ActionFunction<slackCreateChannelParamsType, AuthParamsType, slackCreateChannelOutputType>;
|
|
725
|
-
export declare const slackArchiveChannelParamsSchema: z.ZodObject<{
|
|
726
|
-
channelName: z.ZodString;
|
|
727
|
-
}, "strip", z.ZodTypeAny, {
|
|
728
|
-
channelName: string;
|
|
729
|
-
}, {
|
|
730
|
-
channelName: string;
|
|
731
|
-
}>;
|
|
732
|
-
export type slackArchiveChannelParamsType = z.infer<typeof slackArchiveChannelParamsSchema>;
|
|
733
|
-
export declare const slackArchiveChannelOutputSchema: z.ZodObject<{
|
|
734
|
-
success: z.ZodBoolean;
|
|
735
|
-
error: z.ZodOptional<z.ZodString>;
|
|
736
|
-
}, "strip", z.ZodTypeAny, {
|
|
737
|
-
success: boolean;
|
|
738
|
-
error?: string | undefined;
|
|
739
|
-
}, {
|
|
740
|
-
success: boolean;
|
|
741
|
-
error?: string | undefined;
|
|
742
|
-
}>;
|
|
743
|
-
export type slackArchiveChannelOutputType = z.infer<typeof slackArchiveChannelOutputSchema>;
|
|
744
|
-
export type slackArchiveChannelFunction = ActionFunction<slackArchiveChannelParamsType, AuthParamsType, slackArchiveChannelOutputType>;
|
|
745
728
|
export declare const slackSendMessageParamsSchema: z.ZodObject<{
|
|
746
|
-
|
|
729
|
+
channelId: z.ZodOptional<z.ZodString>;
|
|
730
|
+
channelName: z.ZodOptional<z.ZodString>;
|
|
747
731
|
message: z.ZodString;
|
|
748
732
|
}, "strip", z.ZodTypeAny, {
|
|
749
733
|
message: string;
|
|
750
|
-
channelName
|
|
734
|
+
channelName?: string | undefined;
|
|
735
|
+
channelId?: string | undefined;
|
|
751
736
|
}, {
|
|
752
737
|
message: string;
|
|
753
|
-
channelName
|
|
738
|
+
channelName?: string | undefined;
|
|
739
|
+
channelId?: string | undefined;
|
|
754
740
|
}>;
|
|
755
741
|
export type slackSendMessageParamsType = z.infer<typeof slackSendMessageParamsSchema>;
|
|
756
742
|
export declare const slackSendMessageOutputSchema: z.ZodObject<{
|
|
@@ -2805,6 +2791,7 @@ export declare const snowflakeRunSnowflakeQueryParamsSchema: z.ZodObject<{
|
|
|
2805
2791
|
role: z.ZodOptional<z.ZodString>;
|
|
2806
2792
|
query: z.ZodString;
|
|
2807
2793
|
accountName: z.ZodString;
|
|
2794
|
+
username: z.ZodOptional<z.ZodString>;
|
|
2808
2795
|
outputFormat: z.ZodOptional<z.ZodEnum<["json", "csv"]>>;
|
|
2809
2796
|
limit: z.ZodOptional<z.ZodNumber>;
|
|
2810
2797
|
codeInterpreterLimit: z.ZodOptional<z.ZodNumber>;
|
|
@@ -2816,6 +2803,7 @@ export declare const snowflakeRunSnowflakeQueryParamsSchema: z.ZodObject<{
|
|
|
2816
2803
|
warehouse: string;
|
|
2817
2804
|
limit?: number | undefined;
|
|
2818
2805
|
role?: string | undefined;
|
|
2806
|
+
username?: string | undefined;
|
|
2819
2807
|
outputFormat?: "json" | "csv" | undefined;
|
|
2820
2808
|
codeInterpreterLimit?: number | undefined;
|
|
2821
2809
|
codeInterpreterImageGenLimit?: number | undefined;
|
|
@@ -2826,6 +2814,7 @@ export declare const snowflakeRunSnowflakeQueryParamsSchema: z.ZodObject<{
|
|
|
2826
2814
|
warehouse: string;
|
|
2827
2815
|
limit?: number | undefined;
|
|
2828
2816
|
role?: string | undefined;
|
|
2817
|
+
username?: string | undefined;
|
|
2829
2818
|
outputFormat?: "json" | "csv" | undefined;
|
|
2830
2819
|
codeInterpreterLimit?: number | undefined;
|
|
2831
2820
|
codeInterpreterImageGenLimit?: number | undefined;
|
|
@@ -3205,6 +3194,7 @@ export declare const googleOauthScheduleCalendarMeetingParamsSchema: z.ZodObject
|
|
|
3205
3194
|
description: z.ZodOptional<z.ZodString>;
|
|
3206
3195
|
attendees: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
3207
3196
|
useGoogleMeet: z.ZodOptional<z.ZodBoolean>;
|
|
3197
|
+
timeZone: z.ZodOptional<z.ZodString>;
|
|
3208
3198
|
}, "strip", z.ZodTypeAny, {
|
|
3209
3199
|
name: string;
|
|
3210
3200
|
calendarId: string;
|
|
@@ -3213,6 +3203,7 @@ export declare const googleOauthScheduleCalendarMeetingParamsSchema: z.ZodObject
|
|
|
3213
3203
|
description?: string | undefined;
|
|
3214
3204
|
attendees?: string[] | undefined;
|
|
3215
3205
|
useGoogleMeet?: boolean | undefined;
|
|
3206
|
+
timeZone?: string | undefined;
|
|
3216
3207
|
}, {
|
|
3217
3208
|
name: string;
|
|
3218
3209
|
calendarId: string;
|
|
@@ -3221,6 +3212,7 @@ export declare const googleOauthScheduleCalendarMeetingParamsSchema: z.ZodObject
|
|
|
3221
3212
|
description?: string | undefined;
|
|
3222
3213
|
attendees?: string[] | undefined;
|
|
3223
3214
|
useGoogleMeet?: boolean | undefined;
|
|
3215
|
+
timeZone?: string | undefined;
|
|
3224
3216
|
}>;
|
|
3225
3217
|
export type googleOauthScheduleCalendarMeetingParamsType = z.infer<typeof googleOauthScheduleCalendarMeetingParamsSchema>;
|
|
3226
3218
|
export declare const googleOauthScheduleCalendarMeetingOutputSchema: z.ZodObject<{
|
|
@@ -3379,6 +3371,7 @@ export declare const googleOauthListCalendarEventsOutputSchema: z.ZodObject<{
|
|
|
3379
3371
|
} | undefined;
|
|
3380
3372
|
hangoutLink?: string | undefined;
|
|
3381
3373
|
}>, "many">;
|
|
3374
|
+
timezone: z.ZodOptional<z.ZodString>;
|
|
3382
3375
|
error: z.ZodOptional<z.ZodString>;
|
|
3383
3376
|
}, "strip", z.ZodTypeAny, {
|
|
3384
3377
|
success: boolean;
|
|
@@ -3405,6 +3398,7 @@ export declare const googleOauthListCalendarEventsOutputSchema: z.ZodObject<{
|
|
|
3405
3398
|
hangoutLink?: string | undefined;
|
|
3406
3399
|
}[];
|
|
3407
3400
|
error?: string | undefined;
|
|
3401
|
+
timezone?: string | undefined;
|
|
3408
3402
|
}, {
|
|
3409
3403
|
success: boolean;
|
|
3410
3404
|
events: {
|
|
@@ -3430,6 +3424,7 @@ export declare const googleOauthListCalendarEventsOutputSchema: z.ZodObject<{
|
|
|
3430
3424
|
hangoutLink?: string | undefined;
|
|
3431
3425
|
}[];
|
|
3432
3426
|
error?: string | undefined;
|
|
3427
|
+
timezone?: string | undefined;
|
|
3433
3428
|
}>;
|
|
3434
3429
|
export type googleOauthListCalendarEventsOutputType = z.infer<typeof googleOauthListCalendarEventsOutputSchema>;
|
|
3435
3430
|
export type googleOauthListCalendarEventsFunction = ActionFunction<googleOauthListCalendarEventsParamsType, AuthParamsType, googleOauthListCalendarEventsOutputType>;
|
|
@@ -3454,6 +3449,7 @@ export declare const googleOauthUpdateCalendarEventParamsSchema: z.ZodObject<{
|
|
|
3454
3449
|
email?: string | undefined;
|
|
3455
3450
|
displayName?: string | undefined;
|
|
3456
3451
|
}>>;
|
|
3452
|
+
timeZone: z.ZodOptional<z.ZodString>;
|
|
3457
3453
|
}, "strip", z.ZodTypeAny, {
|
|
3458
3454
|
status?: string | undefined;
|
|
3459
3455
|
description?: string | undefined;
|
|
@@ -3462,6 +3458,7 @@ export declare const googleOauthUpdateCalendarEventParamsSchema: z.ZodObject<{
|
|
|
3462
3458
|
start?: string | undefined;
|
|
3463
3459
|
end?: string | undefined;
|
|
3464
3460
|
attendees?: string[] | undefined;
|
|
3461
|
+
timeZone?: string | undefined;
|
|
3465
3462
|
organizer?: {
|
|
3466
3463
|
email?: string | undefined;
|
|
3467
3464
|
displayName?: string | undefined;
|
|
@@ -3474,6 +3471,7 @@ export declare const googleOauthUpdateCalendarEventParamsSchema: z.ZodObject<{
|
|
|
3474
3471
|
start?: string | undefined;
|
|
3475
3472
|
end?: string | undefined;
|
|
3476
3473
|
attendees?: string[] | undefined;
|
|
3474
|
+
timeZone?: string | undefined;
|
|
3477
3475
|
organizer?: {
|
|
3478
3476
|
email?: string | undefined;
|
|
3479
3477
|
displayName?: string | undefined;
|
|
@@ -3490,6 +3488,7 @@ export declare const googleOauthUpdateCalendarEventParamsSchema: z.ZodObject<{
|
|
|
3490
3488
|
start?: string | undefined;
|
|
3491
3489
|
end?: string | undefined;
|
|
3492
3490
|
attendees?: string[] | undefined;
|
|
3491
|
+
timeZone?: string | undefined;
|
|
3493
3492
|
organizer?: {
|
|
3494
3493
|
email?: string | undefined;
|
|
3495
3494
|
displayName?: string | undefined;
|
|
@@ -3506,6 +3505,7 @@ export declare const googleOauthUpdateCalendarEventParamsSchema: z.ZodObject<{
|
|
|
3506
3505
|
start?: string | undefined;
|
|
3507
3506
|
end?: string | undefined;
|
|
3508
3507
|
attendees?: string[] | undefined;
|
|
3508
|
+
timeZone?: string | undefined;
|
|
3509
3509
|
organizer?: {
|
|
3510
3510
|
email?: string | undefined;
|
|
3511
3511
|
displayName?: string | undefined;
|
|
@@ -3551,6 +3551,7 @@ export declare const googleOauthEditAGoogleCalendarEventParamsSchema: z.ZodObjec
|
|
|
3551
3551
|
email?: string | undefined;
|
|
3552
3552
|
displayName?: string | undefined;
|
|
3553
3553
|
}>>;
|
|
3554
|
+
timeZone: z.ZodOptional<z.ZodString>;
|
|
3554
3555
|
}, "strip", z.ZodTypeAny, {
|
|
3555
3556
|
calendarId: string;
|
|
3556
3557
|
eventId: string;
|
|
@@ -3561,6 +3562,7 @@ export declare const googleOauthEditAGoogleCalendarEventParamsSchema: z.ZodObjec
|
|
|
3561
3562
|
start?: string | undefined;
|
|
3562
3563
|
end?: string | undefined;
|
|
3563
3564
|
attendees?: string[] | undefined;
|
|
3565
|
+
timeZone?: string | undefined;
|
|
3564
3566
|
organizer?: {
|
|
3565
3567
|
email?: string | undefined;
|
|
3566
3568
|
displayName?: string | undefined;
|
|
@@ -3575,6 +3577,7 @@ export declare const googleOauthEditAGoogleCalendarEventParamsSchema: z.ZodObjec
|
|
|
3575
3577
|
start?: string | undefined;
|
|
3576
3578
|
end?: string | undefined;
|
|
3577
3579
|
attendees?: string[] | undefined;
|
|
3580
|
+
timeZone?: string | undefined;
|
|
3578
3581
|
organizer?: {
|
|
3579
3582
|
email?: string | undefined;
|
|
3580
3583
|
displayName?: string | undefined;
|
|
@@ -3664,19 +3667,19 @@ export declare const googleOauthCreateSpreadsheetParamsSchema: z.ZodObject<{
|
|
|
3664
3667
|
timeZone: z.ZodOptional<z.ZodString>;
|
|
3665
3668
|
autoRecalc: z.ZodOptional<z.ZodEnum<["ON_CHANGE", "MINUTE", "HOUR"]>>;
|
|
3666
3669
|
}, "strip", z.ZodTypeAny, {
|
|
3667
|
-
locale?: string | undefined;
|
|
3668
3670
|
timeZone?: string | undefined;
|
|
3671
|
+
locale?: string | undefined;
|
|
3669
3672
|
autoRecalc?: "ON_CHANGE" | "MINUTE" | "HOUR" | undefined;
|
|
3670
3673
|
}, {
|
|
3671
|
-
locale?: string | undefined;
|
|
3672
3674
|
timeZone?: string | undefined;
|
|
3675
|
+
locale?: string | undefined;
|
|
3673
3676
|
autoRecalc?: "ON_CHANGE" | "MINUTE" | "HOUR" | undefined;
|
|
3674
3677
|
}>>;
|
|
3675
3678
|
}, "strip", z.ZodTypeAny, {
|
|
3676
3679
|
title: string;
|
|
3677
3680
|
properties?: {
|
|
3678
|
-
locale?: string | undefined;
|
|
3679
3681
|
timeZone?: string | undefined;
|
|
3682
|
+
locale?: string | undefined;
|
|
3680
3683
|
autoRecalc?: "ON_CHANGE" | "MINUTE" | "HOUR" | undefined;
|
|
3681
3684
|
} | undefined;
|
|
3682
3685
|
sheets?: {
|
|
@@ -3691,8 +3694,8 @@ export declare const googleOauthCreateSpreadsheetParamsSchema: z.ZodObject<{
|
|
|
3691
3694
|
}, {
|
|
3692
3695
|
title: string;
|
|
3693
3696
|
properties?: {
|
|
3694
|
-
locale?: string | undefined;
|
|
3695
3697
|
timeZone?: string | undefined;
|
|
3698
|
+
locale?: string | undefined;
|
|
3696
3699
|
autoRecalc?: "ON_CHANGE" | "MINUTE" | "HOUR" | undefined;
|
|
3697
3700
|
} | undefined;
|
|
3698
3701
|
sheets?: {
|
|
@@ -55,6 +55,7 @@ export const AuthParamsSchema = z.object({
|
|
|
55
55
|
tenantId: z.string().optional(),
|
|
56
56
|
refreshToken: z.string().optional(),
|
|
57
57
|
redirectUri: z.string().optional(),
|
|
58
|
+
userEmail: z.string().optional(),
|
|
58
59
|
});
|
|
59
60
|
export const genericFillTemplateParamsSchema = z.object({
|
|
60
61
|
template: z.string().describe("The template string to be processed and returned"),
|
|
@@ -216,15 +217,12 @@ export const slackCreateChannelOutputSchema = z.object({
|
|
|
216
217
|
channelUrl: z.string().describe("The URL of the created channel").optional(),
|
|
217
218
|
error: z.string().describe("The error that occurred if the channel was not created successfully").optional(),
|
|
218
219
|
});
|
|
219
|
-
export const slackArchiveChannelParamsSchema = z.object({
|
|
220
|
-
channelName: z.string().describe("The name of the channel to archive"),
|
|
221
|
-
});
|
|
222
|
-
export const slackArchiveChannelOutputSchema = z.object({
|
|
223
|
-
success: z.boolean().describe("Whether the channel was archived successfully"),
|
|
224
|
-
error: z.string().describe("The error that occurred if the channel was not archived successfully").optional(),
|
|
225
|
-
});
|
|
226
220
|
export const slackSendMessageParamsSchema = z.object({
|
|
227
|
-
|
|
221
|
+
channelId: z.string().describe("The ID of the channel to send the message to").optional(),
|
|
222
|
+
channelName: z
|
|
223
|
+
.string()
|
|
224
|
+
.describe("The name of the Slack channel to send the message to (e.g. general, alerts)")
|
|
225
|
+
.optional(),
|
|
228
226
|
message: z.string().describe("The message content to send to Slack. Can include markdown formatting."),
|
|
229
227
|
});
|
|
230
228
|
export const slackSendMessageOutputSchema = z.object({
|
|
@@ -849,6 +847,7 @@ export const snowflakeRunSnowflakeQueryParamsSchema = z.object({
|
|
|
849
847
|
role: z.string().describe("The snowflake role to use for executing the query").optional(),
|
|
850
848
|
query: z.string().describe("The SQL query to execute"),
|
|
851
849
|
accountName: z.string().describe("The name of the Snowflake account"),
|
|
850
|
+
username: z.string().describe("The username of the Snowflake Credential (optional)").optional(),
|
|
852
851
|
outputFormat: z.enum(["json", "csv"]).describe("The format of the output").optional(),
|
|
853
852
|
limit: z.number().describe("A limit on the number of rows to return").optional(),
|
|
854
853
|
codeInterpreterLimit: z
|
|
@@ -1515,6 +1514,10 @@ export const googleOauthScheduleCalendarMeetingParamsSchema = z.object({
|
|
|
1515
1514
|
.describe("The attendees of the meeting")
|
|
1516
1515
|
.optional(),
|
|
1517
1516
|
useGoogleMeet: z.boolean().describe("Whether to use Google Meet for the meeting").optional(),
|
|
1517
|
+
timeZone: z
|
|
1518
|
+
.string()
|
|
1519
|
+
.describe("The time zone for the meeting, IANA Time Zone identifier (e.g., 'America/New_York')")
|
|
1520
|
+
.optional(),
|
|
1518
1521
|
});
|
|
1519
1522
|
export const googleOauthScheduleCalendarMeetingOutputSchema = z.object({
|
|
1520
1523
|
success: z.boolean().describe("Whether the meeting was scheduled successfully"),
|
|
@@ -1582,6 +1585,10 @@ export const googleOauthListCalendarEventsOutputSchema = z.object({
|
|
|
1582
1585
|
})
|
|
1583
1586
|
.describe("A calendar event"))
|
|
1584
1587
|
.describe("List of events"),
|
|
1588
|
+
timezone: z
|
|
1589
|
+
.string()
|
|
1590
|
+
.describe("Timezone the user is currently based out of, given by their calender, follows the IANA Time Zone Database format, defaults to UTC if not defined")
|
|
1591
|
+
.optional(),
|
|
1585
1592
|
error: z.string().describe("Error message if listing failed").optional(),
|
|
1586
1593
|
});
|
|
1587
1594
|
export const googleOauthUpdateCalendarEventParamsSchema = z.object({
|
|
@@ -1606,6 +1613,10 @@ export const googleOauthUpdateCalendarEventParamsSchema = z.object({
|
|
|
1606
1613
|
})
|
|
1607
1614
|
.describe("The new organizer of the event")
|
|
1608
1615
|
.optional(),
|
|
1616
|
+
timeZone: z
|
|
1617
|
+
.string()
|
|
1618
|
+
.describe("The time zone for the event, IANA Time Zone identifier (e.g., 'America/New_York')")
|
|
1619
|
+
.optional(),
|
|
1609
1620
|
})
|
|
1610
1621
|
.describe("The fields to update on the event")
|
|
1611
1622
|
.optional(),
|
|
@@ -1636,6 +1647,10 @@ export const googleOauthEditAGoogleCalendarEventParamsSchema = z.object({
|
|
|
1636
1647
|
})
|
|
1637
1648
|
.describe("The new organizer of the event")
|
|
1638
1649
|
.optional(),
|
|
1650
|
+
timeZone: z
|
|
1651
|
+
.string()
|
|
1652
|
+
.describe("The time zone for the event, IANA Time Zone identifier (e.g., 'America/New_York')")
|
|
1653
|
+
.optional(),
|
|
1639
1654
|
});
|
|
1640
1655
|
export const googleOauthEditAGoogleCalendarEventOutputSchema = z.object({
|
|
1641
1656
|
success: z.boolean().describe("Whether the event was edited successfully"),
|
|
@@ -13,17 +13,25 @@ const editAGoogleCalendarEvent = (_a) => __awaiter(void 0, [_a], void 0, functio
|
|
|
13
13
|
if (!authParams.authToken) {
|
|
14
14
|
return { success: false, error: MISSING_AUTH_TOKEN, eventId: "", eventUrl: "" };
|
|
15
15
|
}
|
|
16
|
-
const { calendarId, eventId, title, description, start, end, location, attendees, status, organizer } = params;
|
|
16
|
+
const { calendarId, eventId, title, description, start, end, location, attendees, status, organizer, timeZone } = params;
|
|
17
17
|
const url = `https://www.googleapis.com/calendar/v3/calendars/${encodeURIComponent(calendarId)}/events/${encodeURIComponent(eventId)}`;
|
|
18
18
|
const body = {};
|
|
19
19
|
if (title !== undefined)
|
|
20
20
|
body.summary = title;
|
|
21
21
|
if (description !== undefined)
|
|
22
22
|
body.description = description;
|
|
23
|
-
if (start !== undefined)
|
|
23
|
+
if (start !== undefined) {
|
|
24
24
|
body.start = { dateTime: start };
|
|
25
|
-
|
|
25
|
+
if (timeZone) {
|
|
26
|
+
body.start.timeZone = timeZone;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
if (end !== undefined) {
|
|
26
30
|
body.end = { dateTime: end };
|
|
31
|
+
if (timeZone) {
|
|
32
|
+
body.end.timeZone = timeZone;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
27
35
|
if (location !== undefined)
|
|
28
36
|
body.location = location;
|
|
29
37
|
if (attendees !== undefined)
|
|
@@ -13,48 +13,57 @@ import { MISSING_AUTH_TOKEN } from "../../util/missingAuthConstants.js";
|
|
|
13
13
|
import { extractTextFromPdf } from "../../../utils/pdf.js";
|
|
14
14
|
import { getGoogleDocContent, getGoogleSheetContent, getGoogleSlidesContent } from "../../../utils/google.js";
|
|
15
15
|
const getDriveFileContentById = (_a) => __awaiter(void 0, [_a], void 0, function* ({ params, authParams, }) {
|
|
16
|
+
var _b, _c, _d, _e;
|
|
16
17
|
if (!authParams.authToken) {
|
|
17
18
|
return { success: false, error: MISSING_AUTH_TOKEN };
|
|
18
19
|
}
|
|
19
20
|
const BASE_URL = "https://www.googleapis.com/drive/v3/files/";
|
|
20
|
-
const {
|
|
21
|
-
const
|
|
22
|
-
const
|
|
21
|
+
const headers = { Authorization: `Bearer ${authParams.authToken}` };
|
|
22
|
+
const { limit } = params;
|
|
23
|
+
const timeoutLimit = params.timeoutLimit !== undefined && params.timeoutLimit > 0 ? params.timeoutLimit * 1000 : 15000;
|
|
24
|
+
const axiosClient = createAxiosClientWithTimeout(timeoutLimit);
|
|
25
|
+
// helper to fetch drive metadata with fields we need (incl. shortcut details)
|
|
26
|
+
const fetchMeta = (fid) => __awaiter(void 0, void 0, void 0, function* () {
|
|
27
|
+
const metaUrl = `${BASE_URL}${encodeURIComponent(fid)}` +
|
|
28
|
+
`?fields=name,mimeType,size,driveId,parents,` +
|
|
29
|
+
`shortcutDetails(targetId,targetMimeType)` +
|
|
30
|
+
`&supportsAllDrives=true`;
|
|
31
|
+
const res = yield axiosClient.get(metaUrl, { headers });
|
|
32
|
+
return res.data;
|
|
33
|
+
});
|
|
23
34
|
try {
|
|
24
|
-
//
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
35
|
+
// 1) metadata (possibly a shortcut)
|
|
36
|
+
let meta = yield fetchMeta(params.fileId);
|
|
37
|
+
// 2) resolve shortcut transparently (re-point to target id + mime)
|
|
38
|
+
if (meta.mimeType === "application/vnd.google-apps.shortcut" && ((_b = meta.shortcutDetails) === null || _b === void 0 ? void 0 : _b.targetId)) {
|
|
39
|
+
meta = yield fetchMeta(meta.shortcutDetails.targetId);
|
|
40
|
+
}
|
|
41
|
+
const fileName = (_c = meta.name) !== null && _c !== void 0 ? _c : "";
|
|
42
|
+
const mimeType = (_d = meta.mimeType) !== null && _d !== void 0 ? _d : "";
|
|
43
|
+
const size = meta.size ? parseInt(meta.size, 10) : undefined;
|
|
44
|
+
const driveId = meta.driveId;
|
|
30
45
|
// Check if file is too large (50MB limit for safety)
|
|
31
46
|
const maxMegabytes = params.fileSizeLimit && params.fileSizeLimit > 0 ? params.fileSizeLimit : 50;
|
|
32
47
|
const maxFileSize = maxMegabytes * 1024 * 1024;
|
|
33
|
-
if (size &&
|
|
34
|
-
return {
|
|
35
|
-
success: false,
|
|
36
|
-
error: "File too large (" + maxMegabytes + "MB)",
|
|
37
|
-
};
|
|
48
|
+
if (size !== undefined && size > maxFileSize) {
|
|
49
|
+
return { success: false, error: `File too large (${maxMegabytes}MB)` };
|
|
38
50
|
}
|
|
39
51
|
let content = "";
|
|
40
|
-
const
|
|
52
|
+
const sharedDriveParam = driveId ? "&supportsAllDrives=true" : "";
|
|
41
53
|
// Google Docs - use Google Docs API instead of Drive export
|
|
42
54
|
if (mimeType === "application/vnd.google-apps.document") {
|
|
43
|
-
content = yield getGoogleDocContent(fileId, authParams.authToken, axiosClient,
|
|
55
|
+
content = yield getGoogleDocContent(params.fileId, authParams.authToken, axiosClient, sharedDriveParam);
|
|
44
56
|
}
|
|
45
|
-
// Google Sheets - use Google Sheets API instead of Drive export
|
|
46
57
|
else if (mimeType === "application/vnd.google-apps.spreadsheet") {
|
|
47
|
-
content = yield getGoogleSheetContent(fileId, authParams.authToken, axiosClient,
|
|
58
|
+
content = yield getGoogleSheetContent(params.fileId, authParams.authToken, axiosClient, sharedDriveParam);
|
|
48
59
|
}
|
|
49
|
-
// Google Slides - use Google Slides API instead of Drive export
|
|
50
60
|
else if (mimeType === "application/vnd.google-apps.presentation") {
|
|
51
|
-
content = yield getGoogleSlidesContent(fileId, authParams.authToken, axiosClient,
|
|
61
|
+
content = yield getGoogleSlidesContent(params.fileId, authParams.authToken, axiosClient, sharedDriveParam);
|
|
52
62
|
}
|
|
53
|
-
// PDF files - download and extract text using pdfjs-dist
|
|
54
63
|
else if (mimeType === "application/pdf") {
|
|
55
|
-
const downloadUrl = `${BASE_URL}${encodeURIComponent(fileId)}?alt=media${
|
|
64
|
+
const downloadUrl = `${BASE_URL}${encodeURIComponent(params.fileId)}?alt=media${sharedDriveParam}`;
|
|
56
65
|
const downloadRes = yield axiosClient.get(downloadUrl, {
|
|
57
|
-
headers
|
|
66
|
+
headers,
|
|
58
67
|
responseType: "arraybuffer",
|
|
59
68
|
});
|
|
60
69
|
try {
|
|
@@ -67,18 +76,16 @@ const getDriveFileContentById = (_a) => __awaiter(void 0, [_a], void 0, function
|
|
|
67
76
|
};
|
|
68
77
|
}
|
|
69
78
|
}
|
|
70
|
-
// Word documents (.docx or .doc) - download and extract text using mammoth
|
|
71
79
|
else if (mimeType === "application/vnd.openxmlformats-officedocument.wordprocessingml.document" ||
|
|
72
80
|
mimeType === "application/msword") {
|
|
73
|
-
const downloadUrl = `${BASE_URL}${encodeURIComponent(fileId)}?alt=media${
|
|
81
|
+
const downloadUrl = `${BASE_URL}${encodeURIComponent(params.fileId)}?alt=media${sharedDriveParam}`;
|
|
74
82
|
const downloadRes = yield axiosClient.get(downloadUrl, {
|
|
75
|
-
headers
|
|
83
|
+
headers,
|
|
76
84
|
responseType: "arraybuffer",
|
|
77
85
|
});
|
|
78
86
|
try {
|
|
79
|
-
// mammoth works with .docx files. It will ignore formatting and return raw text
|
|
80
87
|
const result = yield mammoth.extractRawText({ buffer: Buffer.from(downloadRes.data) });
|
|
81
|
-
content = result.value
|
|
88
|
+
content = (_e = result.value) !== null && _e !== void 0 ? _e : "";
|
|
82
89
|
}
|
|
83
90
|
catch (wordError) {
|
|
84
91
|
return {
|
|
@@ -87,38 +94,27 @@ const getDriveFileContentById = (_a) => __awaiter(void 0, [_a], void 0, function
|
|
|
87
94
|
};
|
|
88
95
|
}
|
|
89
96
|
}
|
|
90
|
-
else if (mimeType === "text/plain" ||
|
|
91
|
-
|
|
92
|
-
mimeType === "application/rtf" ||
|
|
93
|
-
(mimeType === null || mimeType === void 0 ? void 0 : mimeType.startsWith("text/"))) {
|
|
94
|
-
// Text-based files
|
|
95
|
-
const downloadUrl = `${BASE_URL}${encodeURIComponent(fileId)}?alt=media${sharedDriveParams}`;
|
|
97
|
+
else if (mimeType === "text/plain" || mimeType === "text/html" || mimeType === "application/rtf") {
|
|
98
|
+
const downloadUrl = `${BASE_URL}${encodeURIComponent(params.fileId)}?alt=media${sharedDriveParam}`;
|
|
96
99
|
const downloadRes = yield axiosClient.get(downloadUrl, {
|
|
97
|
-
headers
|
|
100
|
+
headers,
|
|
98
101
|
responseType: "text",
|
|
99
102
|
});
|
|
100
103
|
content = downloadRes.data;
|
|
101
104
|
}
|
|
102
105
|
else {
|
|
103
|
-
|
|
104
|
-
return {
|
|
105
|
-
success: false,
|
|
106
|
-
error: `Unsupported file type: ${mimeType}`,
|
|
107
|
-
};
|
|
106
|
+
return { success: false, error: `Unsupported file type: ${mimeType}` };
|
|
108
107
|
}
|
|
109
|
-
//
|
|
110
|
-
content = content
|
|
108
|
+
// 5) normalize whitespace + apply content limit
|
|
109
|
+
content = (content !== null && content !== void 0 ? content : "")
|
|
110
|
+
.trim()
|
|
111
|
+
.replace(/\r?\n+/g, " ")
|
|
112
|
+
.replace(/ +/g, " ");
|
|
111
113
|
const originalLength = content.length;
|
|
112
|
-
content = content.replace(/\r?\n+/g, " ").replace(/ +/g, " ");
|
|
113
114
|
if (limit && content.length > limit) {
|
|
114
|
-
content = content.
|
|
115
|
+
content = content.slice(0, limit);
|
|
115
116
|
}
|
|
116
|
-
return {
|
|
117
|
-
success: true,
|
|
118
|
-
content,
|
|
119
|
-
fileName,
|
|
120
|
-
fileLength: originalLength,
|
|
121
|
-
};
|
|
117
|
+
return { success: true, content, fileName, fileLength: originalLength };
|
|
122
118
|
}
|
|
123
119
|
catch (error) {
|
|
124
120
|
console.error("Error getting Google Drive file content", error);
|
|
@@ -14,14 +14,23 @@ const listCalendarEvents = (_a) => __awaiter(void 0, [_a], void 0, function* ({
|
|
|
14
14
|
return { success: false, error: MISSING_AUTH_TOKEN, events: [] };
|
|
15
15
|
}
|
|
16
16
|
const { calendarId, query, maxResults, timeMin, timeMax } = params;
|
|
17
|
-
const url = `https://www.googleapis.com/calendar/v3/calendars/${encodeURIComponent(calendarId)}/events`;
|
|
18
|
-
const allEvents = [];
|
|
19
|
-
let pageToken = undefined;
|
|
20
|
-
let fetchedCount = 0;
|
|
21
|
-
const max = maxResults !== null && maxResults !== void 0 ? maxResults : 250; // Default to 250 if not specified, Google API max is 250
|
|
22
17
|
try {
|
|
18
|
+
// First, fetch the calendar's timezone
|
|
19
|
+
const calendarUrl = `https://www.googleapis.com/calendar/v3/calendars/${encodeURIComponent(calendarId)}`;
|
|
20
|
+
const calendarRes = yield axiosClient.get(calendarUrl, {
|
|
21
|
+
headers: {
|
|
22
|
+
Authorization: `Bearer ${authParams.authToken}`,
|
|
23
|
+
},
|
|
24
|
+
});
|
|
25
|
+
const calendarTimezone = calendarRes.data.timeZone || "UTC";
|
|
26
|
+
// Now fetch the events
|
|
27
|
+
const eventsUrl = `https://www.googleapis.com/calendar/v3/calendars/${encodeURIComponent(calendarId)}/events`;
|
|
28
|
+
const allEvents = [];
|
|
29
|
+
let pageToken = undefined;
|
|
30
|
+
let fetchedCount = 0;
|
|
31
|
+
const max = maxResults !== null && maxResults !== void 0 ? maxResults : 250; // Default to 250 if not specified, Google API max is 250
|
|
23
32
|
while (fetchedCount < max) {
|
|
24
|
-
const res = yield axiosClient.get(
|
|
33
|
+
const res = yield axiosClient.get(eventsUrl, {
|
|
25
34
|
headers: {
|
|
26
35
|
Authorization: `Bearer ${authParams.authToken}`,
|
|
27
36
|
},
|
|
@@ -33,6 +42,7 @@ const listCalendarEvents = (_a) => __awaiter(void 0, [_a], void 0, function* ({
|
|
|
33
42
|
orderBy: "startTime",
|
|
34
43
|
timeMin,
|
|
35
44
|
timeMax,
|
|
45
|
+
timeZone: calendarTimezone, // Include the calendar's timezone in the request
|
|
36
46
|
},
|
|
37
47
|
});
|
|
38
48
|
const { items = [], nextPageToken = undefined } = res.data;
|
|
@@ -81,6 +91,7 @@ const listCalendarEvents = (_a) => __awaiter(void 0, [_a], void 0, function* ({
|
|
|
81
91
|
return {
|
|
82
92
|
success: true,
|
|
83
93
|
events: allEvents,
|
|
94
|
+
timezone: calendarTimezone, // Include the calendar's timezone in the response
|
|
84
95
|
};
|
|
85
96
|
}
|
|
86
97
|
catch (error) {
|
|
@@ -17,17 +17,13 @@ const scheduleCalendarMeeting = (_a) => __awaiter(void 0, [_a], void 0, function
|
|
|
17
17
|
if (!authParams.authToken) {
|
|
18
18
|
throw new Error(MISSING_AUTH_TOKEN);
|
|
19
19
|
}
|
|
20
|
-
const { calendarId, name, start, end, description, attendees, useGoogleMeet } = params;
|
|
20
|
+
const { calendarId, name, start, end, description, attendees, useGoogleMeet, timeZone } = params;
|
|
21
21
|
// https://developers.google.com/calendar/api/v3/reference/events/insert
|
|
22
22
|
let createEventApiUrl = `https://www.googleapis.com/calendar/v3/calendars/${calendarId}/events`;
|
|
23
23
|
const data = {
|
|
24
24
|
summary: name,
|
|
25
|
-
start: {
|
|
26
|
-
|
|
27
|
-
},
|
|
28
|
-
end: {
|
|
29
|
-
dateTime: end,
|
|
30
|
-
},
|
|
25
|
+
start: Object.assign({ dateTime: start }, (timeZone && { timeZone })),
|
|
26
|
+
end: Object.assign({ dateTime: end }, (timeZone && { timeZone })),
|
|
31
27
|
};
|
|
32
28
|
if (description) {
|
|
33
29
|
data.description = description;
|
|
@@ -42,7 +42,7 @@ const searchDriveByQuery = (_a) => __awaiter(void 0, [_a], void 0, function* ({
|
|
|
42
42
|
}
|
|
43
43
|
const { query, limit, searchDriveByDrive, orderByQuery } = params;
|
|
44
44
|
// Can't use orderBy on quereis that include fullText
|
|
45
|
-
const safeOrderBy = query.includes("fullText") ? undefined : orderByQuery;
|
|
45
|
+
const safeOrderBy = query.includes("fullText") ? undefined : (orderByQuery !== null && orderByQuery !== void 0 ? orderByQuery : "modifiedTime desc");
|
|
46
46
|
try {
|
|
47
47
|
if (searchDriveByDrive) {
|
|
48
48
|
return yield searchAllDrivesIndividually(query, authParams.authToken, limit, safeOrderBy);
|
|
@@ -63,8 +63,7 @@ const searchDriveByQuery = (_a) => __awaiter(void 0, [_a], void 0, function* ({
|
|
|
63
63
|
// Original search method - search all drives at once
|
|
64
64
|
const searchAllDrivesAtOnce = (query, authToken, limit, orderByQuery) => __awaiter(void 0, void 0, void 0, function* () {
|
|
65
65
|
var _a;
|
|
66
|
-
const
|
|
67
|
-
const url = `https://www.googleapis.com/drive/v3/files?q=${encodeURIComponent(query)}&fields=files(id,name,mimeType,webViewLink)&supportsAllDrives=true&includeItemsFromAllDrives=true&corpora=allDrives&pageSize=1000&orderBy=${encodeURIComponent(orderBy)}`;
|
|
66
|
+
const url = `https://www.googleapis.com/drive/v3/files?q=${encodeURIComponent(query)}&fields=files(id,name,mimeType,webViewLink)&supportsAllDrives=true&includeItemsFromAllDrives=true&corpora=allDrives&pageSize=1000${orderByQuery ? `&orderBy=${encodeURIComponent(orderByQuery)}` : ""}`;
|
|
68
67
|
const res = yield axiosClient.get(url, {
|
|
69
68
|
headers: {
|
|
70
69
|
Authorization: `Bearer ${authToken}`,
|
|
@@ -136,17 +135,16 @@ const getAllDrives = (authToken) => __awaiter(void 0, void 0, void 0, function*
|
|
|
136
135
|
const searchSingleDrive = (query, driveId, authToken, orderByQuery) => __awaiter(void 0, void 0, void 0, function* () {
|
|
137
136
|
var _a;
|
|
138
137
|
const files = [];
|
|
139
|
-
const orderBy = orderByQuery || "modifiedTime desc";
|
|
140
138
|
let nextPageToken;
|
|
141
139
|
do {
|
|
142
140
|
let url;
|
|
143
141
|
if (driveId === "root") {
|
|
144
142
|
// Search in user's personal drive
|
|
145
|
-
url = `https://www.googleapis.com/drive/v3/files?q=${encodeURIComponent(query)}&fields=files(id,name,mimeType,webViewLink),nextPageToken&pageSize=1000
|
|
143
|
+
url = `https://www.googleapis.com/drive/v3/files?q=${encodeURIComponent(query)}&fields=files(id,name,mimeType,webViewLink),nextPageToken&pageSize=1000${orderByQuery ? `&orderBy=${encodeURIComponent(orderByQuery)}` : ""}${nextPageToken ? `&pageToken=${nextPageToken}` : ""}`;
|
|
146
144
|
}
|
|
147
145
|
else {
|
|
148
146
|
// Search in specific shared drive
|
|
149
|
-
url = `https://www.googleapis.com/drive/v3/files?q=${encodeURIComponent(`${query} and parents in '${driveId}'`)}&fields=files(id,name,mimeType,webViewLink),nextPageToken&supportsAllDrives=true&includeItemsFromAllDrives=true&corpora=drive&driveId=${driveId}&pageSize=1000
|
|
147
|
+
url = `https://www.googleapis.com/drive/v3/files?q=${encodeURIComponent(`${query} and parents in '${driveId}'`)}&fields=files(id,name,mimeType,webViewLink),nextPageToken&supportsAllDrives=true&includeItemsFromAllDrives=true&corpora=drive&driveId=${driveId}&pageSize=1000${orderByQuery ? `&orderBy=${encodeURIComponent(orderByQuery)}` : ""}${nextPageToken ? `&pageToken=${nextPageToken}` : ""}`;
|
|
150
148
|
}
|
|
151
149
|
const res = yield axiosClient.get(url, {
|
|
152
150
|
headers: {
|
|
@@ -21,10 +21,18 @@ const updateCalendarEvent = (_a) => __awaiter(void 0, [_a], void 0, function* ({
|
|
|
21
21
|
body.summary = updates.title;
|
|
22
22
|
if (updates.description != undefined)
|
|
23
23
|
body.description = updates.description;
|
|
24
|
-
if (updates.start != undefined)
|
|
24
|
+
if (updates.start != undefined) {
|
|
25
25
|
body.start = { dateTime: updates.start };
|
|
26
|
-
|
|
26
|
+
if (updates.timeZone) {
|
|
27
|
+
body.start.timeZone = updates.timeZone;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
if (updates.end != undefined) {
|
|
27
31
|
body.end = { dateTime: updates.end };
|
|
32
|
+
if (updates.timeZone) {
|
|
33
|
+
body.end.timeZone = updates.timeZone;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
28
36
|
if (updates.location != undefined)
|
|
29
37
|
body.location = updates.location;
|
|
30
38
|
if (updates.attendees != undefined)
|
|
@@ -10,9 +10,11 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
10
10
|
import { WebClient } from "@slack/web-api";
|
|
11
11
|
import { MISSING_AUTH_TOKEN } from "../../util/missingAuthConstants.js";
|
|
12
12
|
const createChannel = (_a) => __awaiter(void 0, [_a], void 0, function* ({ params, authParams, }) {
|
|
13
|
+
var _b;
|
|
13
14
|
if (!authParams.authToken) {
|
|
14
15
|
throw new Error(MISSING_AUTH_TOKEN);
|
|
15
16
|
}
|
|
17
|
+
const userEmail = authParams.userEmail;
|
|
16
18
|
try {
|
|
17
19
|
const client = new WebClient(authParams.authToken);
|
|
18
20
|
const { channelName, isPrivate } = params;
|
|
@@ -27,6 +29,24 @@ const createChannel = (_a) => __awaiter(void 0, [_a], void 0, function* ({ param
|
|
|
27
29
|
error: error || "Unknown error creating channel",
|
|
28
30
|
};
|
|
29
31
|
}
|
|
32
|
+
if (!userEmail) {
|
|
33
|
+
return {
|
|
34
|
+
success: false,
|
|
35
|
+
error: "userEmail must be provided in authParams to invite user to private channel",
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
const userID = yield client.users.lookupByEmail({ email: userEmail });
|
|
39
|
+
if (!((_b = userID.user) === null || _b === void 0 ? void 0 : _b.id)) {
|
|
40
|
+
return {
|
|
41
|
+
success: false,
|
|
42
|
+
error: `Could not find user with email ${userEmail}`,
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
// Add the user who asked to create the channel to the channel
|
|
46
|
+
yield client.conversations.invite({
|
|
47
|
+
channel: channel.id,
|
|
48
|
+
users: userID.user.id,
|
|
49
|
+
});
|
|
30
50
|
return {
|
|
31
51
|
success: true,
|
|
32
52
|
channelId: channel.id,
|
|
@@ -22,7 +22,7 @@ const getChannelMessages = (_a) => __awaiter(void 0, [_a], void 0, function* ({
|
|
|
22
22
|
let channelId = inputChannelId;
|
|
23
23
|
if (!channelId) {
|
|
24
24
|
const allChannels = yield getSlackChannels(client);
|
|
25
|
-
const channel = allChannels.find(channel => channel.name === channelName
|
|
25
|
+
const channel = allChannels.find(channel => channel.name === channelName);
|
|
26
26
|
if (!channel || !channel.id) {
|
|
27
27
|
throw Error(`Channel with name ${channelName} not found`);
|
|
28
28
|
}
|
|
@@ -22,6 +22,7 @@ export function getSlackChannels(client) {
|
|
|
22
22
|
const allChannelsIterable = yield client.paginate("conversations.list", {
|
|
23
23
|
exclude_archived: true,
|
|
24
24
|
limit,
|
|
25
|
+
types: "public_channel,private_channel",
|
|
25
26
|
});
|
|
26
27
|
try {
|
|
27
28
|
for (var _d = true, _e = __asyncValues(allChannelsIterable), _f; _f = yield _e.next(), _a = _f.done, !_a; _d = true) {
|
|
@@ -12,19 +12,26 @@ import { slackSendMessageOutputSchema, } from "../../autogen/types.js";
|
|
|
12
12
|
import { getSlackChannels } from "./helpers.js";
|
|
13
13
|
import { MISSING_AUTH_TOKEN } from "../../util/missingAuthConstants.js";
|
|
14
14
|
const sendMessage = (_a) => __awaiter(void 0, [_a], void 0, function* ({ params, authParams, }) {
|
|
15
|
+
var _b;
|
|
15
16
|
if (!authParams.authToken) {
|
|
16
17
|
throw new Error(MISSING_AUTH_TOKEN);
|
|
17
18
|
}
|
|
19
|
+
const { channelId: inputChannelId, channelName, message } = params;
|
|
20
|
+
if (!inputChannelId && !channelName) {
|
|
21
|
+
throw Error("Either channelId or channelName must be provided");
|
|
22
|
+
}
|
|
18
23
|
const client = new WebClient(authParams.authToken);
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
24
|
+
let channelId = inputChannelId;
|
|
25
|
+
if (!channelId) {
|
|
26
|
+
const allChannels = yield getSlackChannels(client);
|
|
27
|
+
channelId = (_b = allChannels.find(channel => channel.name == channelName)) === null || _b === void 0 ? void 0 : _b.id;
|
|
28
|
+
}
|
|
29
|
+
if (!channelId) {
|
|
23
30
|
throw Error(`Channel with name ${channelName} not found`);
|
|
24
31
|
}
|
|
25
32
|
try {
|
|
26
33
|
yield client.chat.postMessage({
|
|
27
|
-
channel:
|
|
34
|
+
channel: channelId,
|
|
28
35
|
blocks: [
|
|
29
36
|
{
|
|
30
37
|
type: "section",
|
|
@@ -12,7 +12,8 @@ import { connectToSnowflakeAndWarehouse, getSnowflakeConnection } from "./auth/g
|
|
|
12
12
|
import { formatDataForCodeInterpreter } from "../../util/formatDataForCodeInterpreter.js";
|
|
13
13
|
snowflake.configure({ logLevel: "ERROR" });
|
|
14
14
|
const runSnowflakeQuery = (_a) => __awaiter(void 0, [_a], void 0, function* ({ params, authParams, }) {
|
|
15
|
-
|
|
15
|
+
var _b;
|
|
16
|
+
const { databaseName, warehouse, query, accountName, outputFormat = "json", limit, role, username } = params;
|
|
16
17
|
const executeQueryAndFormatData = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
17
18
|
const formattedQuery = query.trim().replace(/\s+/g, " "); // Normalize all whitespace to single spaces
|
|
18
19
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
@@ -35,13 +36,14 @@ const runSnowflakeQuery = (_a) => __awaiter(void 0, [_a], void 0, function* ({ p
|
|
|
35
36
|
const formattedData = formatDataForCodeInterpreter(queryResults, outputFormat);
|
|
36
37
|
return { formattedData: formattedData, resultsLength: fullResultLength };
|
|
37
38
|
});
|
|
38
|
-
|
|
39
|
-
|
|
39
|
+
const snowflakeUsername = (_b = authParams.username) !== null && _b !== void 0 ? _b : username;
|
|
40
|
+
if (!snowflakeUsername) {
|
|
41
|
+
throw new Error("Snowflake username is required in authParams or as a action parameter.");
|
|
40
42
|
}
|
|
41
43
|
// Set up a connection using snowflake-sdk
|
|
42
44
|
const connection = getSnowflakeConnection({
|
|
43
45
|
account: accountName,
|
|
44
|
-
username:
|
|
46
|
+
username: snowflakeUsername,
|
|
45
47
|
warehouse: warehouse,
|
|
46
48
|
database: databaseName,
|
|
47
49
|
role: role,
|