Skip to main content
Glama

zapcap_mcp_create_task

Create a video processing task with customizable subtitles, styling, and effects for automated video enhancement.

Instructions

Create video processing task with full customization options

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
requestYes

Implementation Reference

  • The handler function that implements the zapcap_mcp_create_task tool logic, sending a POST request to the ZapCap API to create a video processing task with customizable subtitle and style options.
    def zapcap_mcp_create_task(request: CreateTask) -> Dict[str, Any]:
        headers = {
            "x-api-key": get_api_key(),
            "Content-Type": "application/json"
        }
        
        data = {
            "templateId": request.template_id,
            "autoApprove": request.auto_approve,
            "language": request.language,
            "renderOptions": {
                "subsOptions": {
                    "emoji": request.emoji,
                    "emojiAnimation": request.emoji_animation,
                    "emphasizeKeywords": request.emphasize_keywords,
                    "animation": request.animation,
                    "punctuation": request.punctuation,
                    "displayWords": request.display_words
                },
                "styleOptions": {
                    "top": request.position_top,
                    "fontUppercase": request.font_uppercase,
                    "fontSize": request.font_size,
                    "fontWeight": request.font_weight,
                    "fontColor": request.font_color,
                    "fontShadow": request.font_shadow,
                    "stroke": request.stroke,
                    "strokeColor": request.stroke_color
                },
                "highlightOptions": {
                    "randomColourOne": request.highlight_color_1,
                    "randomColourTwo": request.highlight_color_2,
                    "randomColourThree": request.highlight_color_3
                }
            }
        }
        
        # Add B-roll settings only if enabled
        if request.enable_broll:
            data["transcribeSettings"] = {
                "broll": {
                    "brollPercent": request.broll_percent
                }
            }
        
        with httpx.Client() as client:
            response = client.post(
                f"https://api.zapcap.ai/videos/{request.video_id}/task",
                headers=headers,
                json=data
            )
        
        response.raise_for_status()
        return response.json()
  • Pydantic BaseModel defining the input parameters and validation schema for the zapcap_mcp_create_task tool.
    class CreateTask(BaseModel):
        video_id: str = Field(description="Video ID from upload")
        template_id: str = Field(description="Template ID")
        auto_approve: bool = Field(default=True, description="Auto approve the task")
        language: str = Field(default="en", description="Language code")
        enable_broll: bool = Field(default=False, description="Enable B-roll (requires video > 8-10 seconds)")
        broll_percent: int = Field(default=30, description="B-roll percentage (0-100)")
        # Subtitle options
        emoji: bool = Field(default=True, description="Enable emoji in subtitles")
        emoji_animation: bool = Field(default=True, description="Enable emoji animation")
        emphasize_keywords: bool = Field(default=True, description="Emphasize keywords")
        animation: bool = Field(default=True, description="Enable subtitle animation")
        punctuation: bool = Field(default=True, description="Include punctuation")
        display_words: int = Field(default=1, description="Number of words to display")
        # Style options
        position_top: int = Field(default=60, description="Subtitle position from top")
        font_uppercase: bool = Field(default=True, description="Use uppercase font")
        font_size: int = Field(default=30, description="Font size")
        font_weight: int = Field(default=900, description="Font weight")
        font_color: str = Field(default="#ffffff", description="Font color")
        font_shadow: str = Field(default="l", description="Font shadow (s/m/l)")
        stroke: str = Field(default="s", description="Stroke style")
        stroke_color: str = Field(default="#000000", description="Stroke color")
        # Highlight colors
        highlight_color_1: str = Field(default="#2bf82a", description="First highlight color")
        highlight_color_2: str = Field(default="#fdfa14", description="Second highlight color")
        highlight_color_3: str = Field(default="#f01916", description="Third highlight color")
  • FastMCP decorator that registers the zapcap_mcp_create_task function as an MCP tool.
    @mcp.tool(description="Create video processing task with full customization options")

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/bogdanminko/zapcap-mcp-server'

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