Skip to main content
Glama

export_frame

Export a specific frame from a Premiere Pro sequence as an image file in formats like PNG, JPG, or TIFF by specifying the sequence ID, timestamp, and output path.

Instructions

Exports a single frame from a sequence as an image file.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
formatNoThe image format
outputPathYesThe absolute path where the image file will be saved
sequenceIdYesThe ID of the sequence
timeYesThe time in seconds to export the frame from

Implementation Reference

  • The main handler method for the 'export_frame' tool. It constructs and executes an ExtendScript command via the PremiereProBridge to export a single frame from the specified sequence at the given time to the output path in the desired format.
    private async exportFrame(sequenceId: string, time: number, outputPath: string, format = 'png'): Promise<any> { const script = ` try { var sequence = app.project.getSequenceByID("${sequenceId}"); if (!sequence) { JSON.stringify({ success: false, error: "Sequence not found" }); return; } sequence.exportFrame(new Time("${time}s"), "${outputPath}", "${format}"); JSON.stringify({ success: true, message: "Frame exported successfully", sequenceId: "${sequenceId}", time: ${time}, outputPath: "${outputPath}", format: "${format}" }); } catch (e) { JSON.stringify({ success: false, error: e.toString() }); } `; return await this.bridge.executeScript(script); }
  • The input schema definition (using Zod) and tool metadata for 'export_frame' in the getAvailableTools() method, which is used for MCP tool discovery and validation.
    name: 'export_frame', description: 'Exports a single frame from a sequence as an image file.', inputSchema: z.object({ sequenceId: z.string().describe('The ID of the sequence'), time: z.number().describe('The time in seconds to export the frame from'), outputPath: z.string().describe('The absolute path where the image file will be saved'), format: z.enum(['png', 'jpg', 'tiff']).optional().describe('The image format') }) },
  • The switch statement case in the executeTool method that registers and dispatches 'export_frame' tool calls to the corresponding handler.
    return await this.exportFrame(args.sequenceId, args.time, args.outputPath, args.format);

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/hetpatel-11/Adobe_Premiere_Pro_MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server