SlideSpeak Presentation Skill
This skill enables you to create and edit PowerPoint presentations using the SlideSpeak API.
IMPORTANT: Timing Behavior
Presentation generation takes 30-60 seconds.
Option 1: Wait for completion (default)
Run the command and wait. The script polls internally until complete:
node scripts/slidespeak.mjs generate --text "Topic"
- - Blocks until the task finishes (typically 30-60 seconds)
- Returns the complete result with download URL
Option 2: Return immediately with --no-wait
If you cannot wait for the command to complete, use
--no-wait:
node scripts/slidespeak.mjs generate --text "Topic" --no-wait
Returns immediately with:
CODEBLOCK2
Then poll the status until complete:
node scripts/slidespeak.mjs status <task_id>
When
task_status is
SUCCESS, use the
request_id to download.
Timeout behavior
If the script times out while waiting, it returns the task_id so you can continue polling:
CODEBLOCK4
Setup
The SLIDESPEAK_API_KEY environment variable must be set. Get your API key from https://app.slidespeak.co/settings/developer
Quick Reference
All commands use the helper script at scripts/slidespeak.mjs. The script handles API authentication and waits for async tasks to complete automatically (no manual polling needed).
Generate a Presentation from Text
CODEBLOCK5
Options:
- -
--text (required): Topic or content for the presentation - INLINECODE8 : Number of slides (default: 10)
- INLINECODE9 : Template name or ID (default: "default")
- INLINECODE10 : Output language (default: "ORIGINAL")
- INLINECODE11 : casual, professional, funny, educational, sales_pitch
- INLINECODE12 : concise, standard, text-heavy
- INLINECODE13 : Disable stock image fetching
- INLINECODE14 : Exclude cover slide
- INLINECODE15 : Exclude table of contents
Generate from an Uploaded Document
First upload the document, then generate:
CODEBLOCK6
Supported formats: .pdf, .docx, .doc, .pptx, .ppt, .xlsx, .txt, INLINECODE23
List Available Templates
CODEBLOCK7
Download a Presentation
After generation completes, use the request_id to download:
CODEBLOCK8
Returns a JSON object with a short-lived download URL.
Edit an Existing Presentation
Edit slides in an existing presentation:
CODEBLOCK9
Edit types:
- -
INSERT: Add a new slide at the position - INLINECODE26 : Replace existing slide content
- INLINECODE27 : Delete the slide (no prompt needed)
Check Task Status
For debugging or manual polling:
CODEBLOCK10
Get Account Info
CODEBLOCK11
Slide-by-Slide Generation
For precise control over each slide, use the slide-by-slide endpoint. See references/API.md for the full schema.
CODEBLOCK12
Where slides.json contains:
CODEBLOCK13
Webhooks
Subscribe to receive notifications when tasks complete:
CODEBLOCK14
Error Handling
The script outputs JSON with either:
- - Success: INLINECODE30
- Error: INLINECODE31
Common Workflows
Create a presentation about a topic
CODEBLOCK15
Create a presentation from a PDF report
CODEBLOCK16
Edit a presentation to add a new slide
CODEBLOCK17
Additional Resources
For detailed API documentation including all parameters, layout types, and constraints, read references/API.md.
SlideSpeak 演示文稿技能
此技能使您能够使用 SlideSpeak API 创建和编辑 PowerPoint 演示文稿。
重要提示:时间行为
生成演示文稿需要 30-60 秒。
选项 1:等待完成(默认)
运行命令并等待。脚本会在内部轮询直至完成:
bash
node scripts/slidespeak.mjs generate --text 主题
- - 阻塞直到任务完成(通常 30-60 秒)
- 返回包含下载链接的完整结果
选项 2:使用 --no-wait 立即返回
如果您无法等待命令完成,请使用 --no-wait:
bash
node scripts/slidespeak.mjs generate --text 主题 --no-wait
立即返回:
json
{
success: true,
data: {
task_id: abc123...,
message: 任务已启动。使用以下命令检查状态:node scripts/slidespeak.mjs status abc123...
}
}
然后轮询状态直至完成:
bash
node scripts/slidespeak.mjs status
当 taskstatus 为 SUCCESS 时,使用 requestid 进行下载。
超时行为
如果脚本在等待时超时,它会返回 task_id,以便您可以继续轮询:
json
{
success: true,
data: {
complete: false,
task_id: abc123...,
task_status: STARTED,
message: 任务仍在处理中。使用以下命令检查状态:node scripts/slidespeak.mjs status abc123...
}
}
设置
必须设置 SLIDESPEAKAPIKEY 环境变量。从 https://app.slidespeak.co/settings/developer 获取您的 API 密钥。
快速参考
所有命令都使用位于 scripts/slidespeak.mjs 的帮助脚本。该脚本处理 API 身份验证并自动等待异步任务完成(无需手动轮询)。
从文本生成演示文稿
bash
node scripts/slidespeak.mjs generate --text 您的主题或内容 --length 6
选项:
- - --text(必需):演示文稿的主题或内容
- --length:幻灯片数量(默认:10)
- --template:模板名称或 ID(默认:default)
- --language:输出语言(默认:ORIGINAL)
- --tone:casual、professional、funny、educational、sales_pitch
- --verbosity:concise、standard、text-heavy
- --no-images:禁用库存图片获取
- --no-cover:排除封面幻灯片
- --no-toc:排除目录
从上传的文档生成
先上传文档,然后生成:
bash
上传文档(PDF、DOCX、PPTX 等)
node scripts/slidespeak.mjs upload /path/to/document.pdf
使用返回的 document_uuid 生成
node scripts/slidespeak.mjs generate --document
--length 10
支持的格式:.pdf、.docx、.doc、.pptx、.ppt、.xlsx、.txt、.md
列出可用模板
bash
默认模板
node scripts/slidespeak.mjs templates
品牌模板(如果已配置)
node scripts/slidespeak.mjs templates --branded
下载演示文稿
生成完成后,使用 request_id 下载:
bash
node scripts/slidespeak.mjs download
返回一个包含短期有效下载链接的 JSON 对象。
编辑现有演示文稿
编辑现有演示文稿中的幻灯片:
bash
在位置 2 插入新幻灯片
node scripts/slidespeak.mjs edit-slide \
--presentation-id \
--type INSERT \
--position 2 \
--prompt 关于市场分析的内容
重新生成位置 3 的幻灯片
node scripts/slidespeak.mjs edit-slide \
--presentation-id \
--type REGENERATE \
--position 3 \
--prompt 此幻灯片的更新内容
移除位置 4 的幻灯片
node scripts/slidespeak.mjs edit-slide \
--presentation-id \
--type REMOVE \
--position 4
编辑类型:
- - INSERT:在指定位置添加新幻灯片
- REGENERATE:替换现有幻灯片内容
- REMOVE:删除幻灯片(无需提示)
检查任务状态
用于调试或手动轮询:
bash
node scripts/slidespeak.mjs status
获取账户信息
bash
node scripts/slidespeak.mjs me
逐张幻灯片生成
如需精确控制每张幻灯片,请使用逐张幻灯片端点。完整模式请参见 references/API.md。
bash
node scripts/slidespeak.mjs generate-slides --config slides.json
其中 slides.json 包含:
json
{
slides: [
{title: 引言, layout: title, content: 欢迎信息},
{title: 要点, layout: bullets, item_amount: 4, content: 主要讨论点}
],
template: default
}
Webhooks
订阅以在任务完成时接收通知:
bash
订阅
node scripts/slidespeak.mjs webhook-subscribe --url https://your-webhook.com/endpoint
取消订阅
node scripts/slidespeak.mjs webhook-unsubscribe --url https://your-webhook.com/endpoint
错误处理
脚本输出 JSON,包含以下之一:
- - 成功:{success: true, data: {...}}
- 错误:{success: false, error: message}
常见工作流程
创建关于某个主题的演示文稿
bash
node scripts/slidespeak.mjs generate --text 机器学习入门 --length 8 --tone educational
从 PDF 报告创建演示文稿
bash
上传 PDF
RESULT=$(node scripts/slidespeak.mjs upload report.pdf)
DOCID=$(echo $RESULT | jq -r .data.documentuuid)
生成演示文稿
node scripts/slidespeak.mjs generate --document $DOC_ID --length 12
编辑演示文稿以添加新幻灯片
bash
node scripts/slidespeak.mjs edit-slide \
--presentation-id abc123 \
--type INSERT \
--position 5 \
--prompt 添加一张关于季度收入增长并包含图表的幻灯片
其他资源
有关包括所有参数、布局类型和约束的详细 API 文档,请阅读 references/API.md。