AI Agents & MCPs & AI Workflow Automation • (~400 MCP servers for AI agents) • AI Automation / AI Agent with MCPs • AI Workflows & AI Agents • MCPs for AI Agents
TypeScript ai-agentai-agent-toolsai-agentsai-agents-frameworkmcpmcp-servermcp-toolsmcpsn8n-alternativeno-code-automationworkflowworkflow-automationworkflows
import { createAction } from '@activepieces/pieces-framework';
import { microsoftTeamsAuth } from '../../../auth';
import { microsoftTeamsAiProps } from '../../../common/ai-props';
import { microsoftTeamsClient } from '../../../common/client';
import { microsoftTeamsHideChatOutputSchema } from '../../../output-schemas';
export const unhideChat = createAction({
auth: microsoftTeamsAuth,
name: 'microsoft_teams_unhide_chat',
outputSchema: microsoftTeamsHideChatOutputSchema,
displayName: 'Unhide Chat',
description: 'Unhides a chat for the signed-in user.',
audience: 'ai',
classification: 'WRITE',
aiMetadata: {
description:
"Shows a chat hidden with Hide Chat in the signed-in user's chat list again, by chat ID from List Chats. Only affects the signed-in user.",
idempotent: true,
},
props: {
chatId: microsoftTeamsAiProps.chatId({ required: true }),
},
async run(context) {
const { chatId } = context.propsValue;
const user = await microsoftTeamsClient.signedInUser({ auth: context.auth });
const client = microsoftTeamsClient.create({ auth: context.auth });
await client.api(`/chats/${chatId}/unhideForUser`).post({ user });
return { success: true };
},
});