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 { youtubeAuth } from '../common/auth';
import { downloadCaptionTrackOutputSchema } from '../output-schemas';
import { youtubeDownloadCaptionAction } from './download-caption';
export const youtubeDownloadCaptionTrackAction = createAction({
auth: youtubeAuth,
outputSchema: downloadCaptionTrackOutputSchema,
name: 'download_caption_track',
classification: 'READ',
displayName: 'Download Caption Track',
description:
'Returns a caption track text by caption ID using the YouTube captions.download endpoint. Requires permission to edit the video, so it only works for captions on videos the authenticated user owns. Auto-generated (asr) caption tracks cannot be downloaded and will return a 403.',
audience: 'ai',
aiMetadata: {
description:
'Downloads the raw text of one caption track by caption ID, optionally as SRT, VTT, SBV, SCC or TTML and machine-translated into a target language. Use it after List Caption Tracks supplies the caption ID. It only serves tracks on videos the connected account can edit, and auto-generated (asr) tracks are refused with a 403. Read-only and idempotent.',
idempotent: true,
},
props: youtubeDownloadCaptionAction.props,
run: async (context) => ({
caption: await youtubeDownloadCaptionAction.run(context),
}),
});