GA

gamma-core-workflow-b

Instructions for using Gamma API to generate presentations from templates and retrieve exported files.

Install

mkdir -p .claude/skills/gamma-core-workflow-b && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/4809" && unzip -o skill.zip -d .claude/skills/gamma-core-workflow-b && rm skill.zip

Installs to .claude/skills/gamma-core-workflow-b

Activation

This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.

Generate from templates, retrieve exports, and manage sharing via Gamma
71 charsno explicit “when” trigger
Intermediate

Key capabilities

  • Generate presentations from single-page templates
  • Export presentations to PDF, PPTX, or PNG formats
  • Configure workspace and external sharing access
  • Batch generate variations from a single template
  • Retrieve temporary download links for exports

How it works

The skill utilizes the generate-poll-retrieve pattern to create content from a single-page template and retrieve temporary export URLs for the resulting file.

Inputs & outputs

You give it
Template gamma ID and generation prompt
You get back
Downloadable export URL and presentation link

When to use gamma-core-workflow-b

  • Generating presentations from single-page templates
  • Automating the export of presentations to PDF
  • Retrieving generated presentation download links
  • Managing folder organization for generated assets

About this skill

Gamma Core Workflow B: Templates & Export

Overview

Use Gamma's template-based generation (POST /v1.0/generations/from-template) and export retrieval (GET /v1.0/generations/{id}/files) endpoints. Template generation lets you replicate a single-page gamma template across multiple variations. Export retrieval gives you downloadable PDF, PPTX, and PNG files.

Prerequisites

  • Completed gamma-core-workflow-a
  • A template gamma with exactly one page (created in the Gamma app)
  • Understanding of the generate-poll-retrieve pattern

Key Concepts

  • Template gamma: A regular gamma with exactly one page, used as a repeatable template
  • gammaId: Found in the gamma URL or copied from the app
  • Export URLs: Temporary download links returned after generation — download promptly as they expire

Instructions

Step 1: Create from Template

import { createGammaClient, pollUntilDone } from "./lib/gamma";

const gamma = createGammaClient({ apiKey: process.env.GAMMA_API_KEY! });

// POST /v1.0/generations/from-template
// The template gamma MUST have exactly one page
async function generateFromTemplate(
  templateGammaId: string,
  prompt: string,
  options: {
    themeId?: string;
    exportAs?: "pdf" | "pptx" | "png";
    imageStyle?: string;
  } = {}
) {
  const { generationId } = await gamma.generateFromTemplate({
    gammaId: templateGammaId,
    prompt,
    themeId: options.themeId,
    exportAs: options.exportAs,
    imageOptions: options.imageStyle
      ? { style: options.imageStyle }
      : undefined,
  });

  return pollUntilDone(gamma, generationId);
}

// Usage: generate a sales proposal from a template
const result = await generateFromTemplate(
  "gamma_template_abc123",   // Your one-page template ID
  "Create a sales proposal for Acme Corp. Highlight our cloud migration services, 99.9% uptime SLA, and 24/7 support.",
  { exportAs: "pdf", imageStyle: "corporate professional" }
);

console.log(`View: ${result.gammaUrl}`);
console.log(`Download: ${result.exportUrl}`);

Step 2: Batch Template Generation

// Generate multiple variations from the same template
const clients = [
  { name: "Acme Corp", focus: "cloud migration" },
  { name: "TechStart Inc", focus: "AI implementation" },
  { name: "GlobalBank", focus: "security compliance" },
];

import pLimit from "p-limit";
const limit = pLimit(2); // Respect rate limits

const proposals = await Promise.allSettled(
  clients.map((client) =>
    limit(() =>
      generateFromTemplate(
        "gamma_template_abc123",
        `Proposal for ${client.name} focusing on ${client.focus}. Include pricing tier for enterprise. Reference their industry.`,
        { exportAs: "pptx" }
      )
    )
  )
);

proposals.forEach((r, i) => {
  const status = r.status === "fulfilled" ? r.value.gammaUrl : `FAILED: ${r.reason}`;
  console.log(`${clients[i].name}: ${status}`);
});

Step 3: Export Format Selection

// Export is specified at generation time via `exportAs`
// You cannot export an already-generated gamma via the API
// Instead, generate with the desired export format

// PDF export — best for sharing externally
const pdfResult = await gamma.generate({
  content: "Annual report for 2025",
  outputFormat: "document",
  exportAs: "pdf",
});

// PPTX export — for editing in PowerPoint/Google Slides
// Note: PPTX exports may have layout shifts and font differences
const pptxResult = await gamma.generate({
  content: "Team kickoff presentation",
  outputFormat: "presentation",
  exportAs: "pptx",
});

// PNG export — for thumbnails or social sharing
const pngResult = await gamma.generate({
  content: "Product announcement graphic",
  outputFormat: "social_post",
  exportAs: "png",
});

Step 4: Retrieve Export Files

// After generation completes, exportUrl is in the poll response
// Download files promptly — URLs expire after a period

import { writeFile } from "node:fs/promises";

async function downloadExport(generationId: string, outputPath: string) {
  // Poll until complete
  const result = await pollUntilDone(gamma, generationId);

  if (!result.exportUrl) {
    throw new Error("No export URL — did you specify exportAs?");
  }

  // Download the file
  const response = await fetch(result.exportUrl);
  if (!response.ok) throw new Error(`Download failed: ${response.status}`);

  const buffer = Buffer.from(await response.arrayBuffer());
  await writeFile(outputPath, buffer);
  console.log(`Saved to ${outputPath} (${buffer.length} bytes)`);
}

// Usage
const { generationId } = await gamma.generate({
  content: "Sales deck for Q1 review",
  outputFormat: "presentation",
  exportAs: "pdf",
});

await downloadExport(generationId, "./output/q1-review.pdf");

Step 5: Sharing Configuration

// Configure who can access the generated gamma
const { generationId } = await gamma.generate({
  content: "Internal strategy document",
  outputFormat: "document",
  sharingOptions: {
    // Workspace members
    workspaceAccess: "comment",  // noAccess | view | comment | edit | fullAccess

    // External (non-workspace) visitors
    externalAccess: "noAccess",  // Lock down for internal docs

    // Share with specific people via email
    emailOptions: {
      emails: ["[email protected]"],
      accessLevel: "view",
    },
  },
});

Step 6: curl Reference

# Generate from template
curl -X POST "https://public-api.gamma.app/v1.0/generations/from-template" \
  -H "X-API-KEY: ${GAMMA_API_KEY}" \
  -H "Content-Type: application/json" \
  -d '{
    "gammaId": "your_template_gamma_id",
    "prompt": "Create a proposal for Acme Corp focusing on cloud services",
    "exportAs": "pdf",
    "themeId": "theme_abc123",
    "imageOptions": { "style": "photorealistic" },
    "sharingOptions": {
      "workspaceAccess": "edit",
      "externalAccess": "view"
    }
  }'

# Poll for result
curl "https://public-api.gamma.app/v1.0/generations/${GEN_ID}" \
  -H "X-API-KEY: ${GAMMA_API_KEY}" | jq '{status, gammaUrl, exportUrl, creditsUsed}'

Export Format Comparison

FormatBest ForFidelityEditable?
PDFSharing, printingHighNo
PPTXEditing in PowerPoint/SlidesMedium (layout shifts possible)Yes
PNGThumbnails, social mediaHigh (single image)No

Error Handling

ErrorCauseSolution
"Template must have exactly one page"Multi-page templateEdit template to single page
Empty exportUrlexportAs not specifiedAdd exportAs to generation request
Download URL expiredToo slow to downloadDownload immediately after completion
422 on template generationInvalid gammaIdVerify template ID from Gamma app URL

Resources

Next Steps

Proceed to gamma-common-errors for troubleshooting API issues.

When not to use it

  • Using multi-page gammas as templates
  • Exporting already-generated gammas without specifying format at generation time

Prerequisites

Completed gamma-core-workflow-aTemplate gamma with exactly one page

Limitations

  • Template gamma must have exactly one page
  • Export URLs expire after a period
  • PPTX exports may have layout shifts

How it compares

This approach automates the generation and export process programmatically, whereas manual creation requires using the Gamma app interface.

Compared to similar skills

gamma-core-workflow-b side by side with the closest alternatives in the catalog.

SkillInstallsUpdatedSafetyDifficulty
gamma-core-workflow-b (this skill)125dCautionIntermediate
telegram-bot-builder1066moReviewIntermediate
mcp-integration218moReviewIntermediate
n8n-workflow-patterns162moNo flagsAdvanced

Try saying

Example prompts that trigger this skill in your AI assistant.

More by jeremylongshore

View all by jeremylongshore

analyzing-logs

jeremylongshore

Analyze application logs to detect performance issues, identify error patterns, and improve stability by extracting key insights.

14123

ollama-setup

jeremylongshore

Configure auto-configure Ollama when user needs local LLM deployment, free AI alternatives, or wants to eliminate hosted API costs. Trigger phrases: "install ollama", "local AI", "free LLM", "self-hosted AI", "replace OpenAI", "no API costs". Use when appropriate context detected. Trigger with relevant phrases based on skill purpose.

1167

backtesting-trading-strategies

jeremylongshore

Backtest crypto and traditional trading strategies against historical data. Calculates performance metrics (Sharpe, Sortino, max drawdown), generates equity curves, and optimizes strategy parameters. Use when user wants to test a trading strategy, validate signals, or compare approaches. Trigger with phrases like "backtest strategy", "test trading strategy", "historical performance", "simulate trades", "optimize parameters", or "validate signals".

1071

generating-database-seed-data

jeremylongshore

Process this skill enables AI assistant to generate realistic test data and database seed scripts for development and testing environments. it uses faker libraries to create realistic data, maintains relational integrity, and allows configurable data volumes. u... Use when working with databases or data models. Trigger with phrases like 'database', 'query', or 'schema'.

1033

cursor-codebase-indexing

jeremylongshore

Execute set up and optimize Cursor codebase indexing. Triggers on "cursor index setup", "codebase indexing", "index codebase", "cursor semantic search". Use when working with cursor codebase indexing functionality. Trigger with phrases like "cursor codebase indexing", "cursor indexing", "cursor".

885

testing-mobile-apps

jeremylongshore

Execute mobile app testing on iOS and Android devices/simulators. Use when performing specialized testing. Trigger with phrases like "test mobile app", "run iOS tests", or "validate Android functionality".

810

You might also like

telegram-bot-builder

davila7

Expert in building Telegram bots that solve real problems - from simple automation to complex AI-powered bots. Covers bot architecture, the Telegram Bot API, user experience, monetization strategies, and scaling bots to thousands of users. Use when: telegram bot, bot api, telegram automation, chat bot telegram, tg bot.

106130

mcp-integration

anthropics

This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context Protocol", "connect external service", mentions "${CLAUDE_PLUGIN_ROOT} with MCP", or discusses MCP server types (SSE, stdio, HTTP, WebSocket). Provides comprehensive guidance for integrating Model Context Protocol servers into Claude Code plugins for external tool and service integration.

21123

n8n-workflow-patterns

czlonkowski

Proven workflow architectural patterns from real n8n workflows. Use when building new workflows, designing workflow structure, choosing workflow patterns, planning workflow architecture, or asking about webhook processing, HTTP API integration, database operations, AI agent workflows, or scheduled tasks.

16115

n8n-code-javascript

czlonkowski

Write JavaScript code in n8n Code nodes. Use when writing JavaScript in n8n, using $input/$json/$node syntax, making HTTP requests with $helpers, working with dates using DateTime, troubleshooting Code node errors, or choosing between Code node modes.

7122

n8n-expression-syntax

czlonkowski

Validate n8n expression syntax and fix common errors. Use when writing n8n expressions, using {{}} syntax, accessing $json/$node variables, troubleshooting expression errors, or working with webhook data in workflows.

6111

n8n-node-configuration

czlonkowski

Operation-aware node configuration guidance. Use when configuring nodes, understanding property dependencies, determining required fields, choosing between get_node_essentials and get_node_info, or learning common configuration patterns by node type.

7108

Search skills

Search the agent skills registry