UNPKG

mattermost-redux

Version:

Common code (API client, Redux stores, logic, utility functions) for building a Mattermost client

48 lines (47 loc) 6.09 kB
import type { AnyAction } from 'redux'; import type { Command, CommandArgs, DialogSubmission, IncomingWebhook, IncomingWebhooksWithCount, OAuthApp, OutgoingOAuthConnection, OutgoingWebhook, SubmitDialogResponse } from '@mattermost/types/integrations'; import type { ActionFuncAsync } from 'mattermost-redux/types/actions'; export declare function createIncomingHook(hook: IncomingWebhook): ActionFuncAsync<IncomingWebhook, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getIncomingHook(hookId: string): ActionFuncAsync<IncomingWebhook, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getIncomingHooks(teamId?: string, page?: number, perPage?: number, includeTotalCount?: boolean): ActionFuncAsync<IncomingWebhook[] | IncomingWebhooksWithCount>; export declare function isIncomingWebhooksWithCount(data: any): data is IncomingWebhooksWithCount; export declare function removeIncomingHook(hookId: string): ActionFuncAsync; export declare function updateIncomingHook(hook: IncomingWebhook): ActionFuncAsync<IncomingWebhook, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function createOutgoingHook(hook: OutgoingWebhook): ActionFuncAsync<OutgoingWebhook, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getOutgoingHook(hookId: string): ActionFuncAsync<OutgoingWebhook, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getOutgoingHooks(channelId?: string, teamId?: string, page?: number, perPage?: number): ActionFuncAsync<OutgoingWebhook[], import("@mattermost/types/store").GlobalState, AnyAction>; export declare function removeOutgoingHook(hookId: string): ActionFuncAsync; export declare function updateOutgoingHook(hook: OutgoingWebhook): ActionFuncAsync<OutgoingWebhook, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function regenOutgoingHookToken(hookId: string): ActionFuncAsync<OutgoingWebhook, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getCommands(teamId: string): ActionFuncAsync<Command[], import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getAutocompleteCommands(teamId: string, page?: number, perPage?: number): ActionFuncAsync<Command[], import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getCustomTeamCommands(teamId: string): ActionFuncAsync<Command[], import("@mattermost/types/store").GlobalState, AnyAction>; export declare function addCommand(command: Command): ActionFuncAsync<Command, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function editCommand(command: Command): ActionFuncAsync<Command, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function executeCommand(command: string, args: CommandArgs): ActionFuncAsync<import("@mattermost/types/integrations").CommandResponse, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function regenCommandToken(id: string): ActionFuncAsync; export declare function deleteCommand(id: string): ActionFuncAsync; export declare function addOAuthApp(app: OAuthApp): ActionFuncAsync<OAuthApp, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function editOAuthApp(app: OAuthApp): ActionFuncAsync<OAuthApp, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getOAuthApps(page?: number, perPage?: number): ActionFuncAsync<OAuthApp[], import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getOutgoingOAuthConnections(teamId: string, page?: number, perPage?: number): ActionFuncAsync<OutgoingOAuthConnection[], import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getOutgoingOAuthConnectionsForAudience(teamId: string, audience: string, page?: number, perPage?: number): ActionFuncAsync<OutgoingOAuthConnection[], import("@mattermost/types/store").GlobalState, AnyAction>; export declare function addOutgoingOAuthConnection(teamId: string, connection: OutgoingOAuthConnection): ActionFuncAsync<OutgoingOAuthConnection, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function editOutgoingOAuthConnection(teamId: string, connection: OutgoingOAuthConnection): ActionFuncAsync<OutgoingOAuthConnection, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getOutgoingOAuthConnection(teamId: string, connectionId: string): ActionFuncAsync<OutgoingOAuthConnection, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function validateOutgoingOAuthConnection(teamId: string, connection: OutgoingOAuthConnection): ActionFuncAsync<OutgoingOAuthConnection, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getAppsOAuthAppIDs(): ActionFuncAsync<string[], import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getAppsBotIDs(): ActionFuncAsync<string[], import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getOAuthApp(appId: string): ActionFuncAsync<OAuthApp, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function getAuthorizedOAuthApps(): ActionFuncAsync<OAuthApp[]>; export declare function deauthorizeOAuthApp(clientId: string): ActionFuncAsync<import("@mattermost/types/client4").StatusOK, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function deleteOAuthApp(id: string): ActionFuncAsync; export declare function regenOAuthAppSecret(appId: string): ActionFuncAsync<OAuthApp, import("@mattermost/types/store").GlobalState, AnyAction>; export declare function deleteOutgoingOAuthConnection(id: string): ActionFuncAsync<boolean>; export declare function submitInteractiveDialog(submission: DialogSubmission): ActionFuncAsync<SubmitDialogResponse>; export declare function lookupInteractiveDialog(submission: DialogSubmission): ActionFuncAsync<{ items: Array<{ text: string; value: string; }>; }>;