Skip to content

最后更新

更新日志

Magic Hour API

正常只读

浏览、搜索和查看 Magic Hour(magichour.ai)的 AI 视频和图片模板:类别、热度、预览和输出媒体、生成设置以及指南内容。 来源: magichour.ai.

基础 URL
https://api.maviapi.com/v1/sites/magichour
5
端点
1 h ago
最近验证
100%
可用率 / 7 天
1142ms
p50 延迟
GET/categories5 credits per call

类别

magichour.ai 模板主页列出的模板类别,按网站顺序排列:slug、显示名称和页面 URL。每个 slug 都可作为 `category` 传给 /templates 和 /explore。

Bearer auth. Pass your key as Authorization: Bearer <key> on every request.

This endpoint takes no parameters.

Try itLive
GET
https://api.maviapi.com/v1/sites/magichour/categories
Request
curl "https://api.maviapi.com/v1/sites/magichour/categories" \
-H "Authorization: Bearer $MAVI_KEY"
Example109 B
[
  {
    "slug": "popular",
    "name": "Popular",
    "url": "https://magichour.ai/templates/popular"
  }
]

Get all the data, no code

Collect every page of GET /categories into a dataset, for one request or for a whole list of them, then download it as CSV or JSON. A page costs the same as one call of the endpoint; the download is free.

Use Magic Hour API from Claude, ChatGPT and your coding tools

Add this URL as a custom connector and sign in to maviapi. Nothing to install.

How to connect
https://mcp.maviapi.com/mcp

Or run it locally, with each endpoint of Magic Hour API as its own tool:

claude mcp add maviapi -e MAVIAPI_TOOLS=magichour -- npx -y '@maviapi/mcp'

Import Magic Hour API into Postman and other tools

How to import

Paste a link into Postman, Insomnia, an agent framework or a no-code tool to get every endpoint with its parameters and response fields. The link always serves the current endpoints, so importing it again picks up new ones.

  • OpenAPI 3.1
    https://api.maviapi.com/v1/apis/magichour/openapi.json
  • Postman
    https://api.maviapi.com/v1/apis/magichour/postman.json

The Postman collection sends the shared demo key until you put your own key in its maviapi_key variable.

使用 Magic Hour API 进行开发

选择一个端点开始

  • 类别 GET /categories

    magichour.ai 模板主页列出的模板类别,按网站顺序排列:slug、显示名称和页面 URL。每个 slug 都可作为 `category` 传给 /templates 和 /explore。

  • 模板 GET /templates

    magichour.ai 某个类别下的模板,与网站列出的一致:'all' 为模板主页(约 60 个热门模板),其他类别为对应页面的前约 20 个模板。每个模板包含 id、name、description、url、project_type、source_type、tags、used_count、size、created_at(UTC)、预览和输出媒体的 URL,以及预填的生成设置。

    GET /templates 的参数和响应字段
    请求参数
    名称类型 / 位置必填说明
    categorystring / query否category slug (see /categories); 'all' = the templates hub 可选值: all, popular, new, animation, video-to-video, image-to-video, text-to-video, face-swap, character-replace, lip-sync, talking-photo, music-video, memes, movies, sports, tiktok, bollywood, transition, kpop, ai-image-editor, clothes-changer, ai-video-effects, ai-dance-video, camera-motion, ai-transformation-video, anime-video, video-game, ai-video-styles.
    project_typestring / query否keep only templates of this generation type, e.g. FACE_SWAP
    tagstring / query否keep only templates carrying this tag (case-insensitive), e.g. KPOP, MEMES, POPULAR, TIKTOK
    sortstring / query否'default' = the site's order, 'most_used' = most used first, 'newest' = newest first 可选值: default, most_used, newest.
    响应字段
    字段类型说明
    categorystring
    category_namestring
    countinteger
    templatesobject[]
    templates[].idstring
    templates[].namestring
    templates[].descriptionstring
    templates[].urlstring
    templates[].project_typestring
    templates[].source_typestring
    templates[].tagsstring[]
    templates[].used_countinteger
    templates[].widthinteger
    templates[].heightinteger
    templates[].created_atstring
    templates[].authornull
    templates[].preview_urlstring
    templates[].output_urlsstring[]
    templates[].settingsobject
    templates[].settings.fpsinteger
    templates[].settings.endSecondsinteger
    templates[].settings.startSecondsinteger
    templates[].settings.videoFile_urlstring
    templates[].settings.initialImage_urlstring
    paginationobject
    pagination.countinteger
    pagination.has_moreboolean
    pagination.next_cursornull
    fetched_atstring
    ageinteger
  • 探索 GET /explore

    一次调用完成发现:返回某次搜索(传入 q 时)或某个类别下的模板,其中前 `details` 个模板附带 `details` = {content: 指南内容(同 /templates/{id}),related_templates: [...]};其余模板的 details 为 null。

    GET /explore 的参数和响应字段
    请求参数
    名称类型 / 位置必填说明
    qstring / query否free-text search; when set the search is used and category is ignored
    categorystring / query否category slug to browse when q is empty (see /categories); 'all' = the templates hub 可选值: all, popular, new, animation, video-to-video, image-to-video, text-to-video, face-swap, character-replace, lip-sync, talking-photo, music-video, memes, movies, sports, tiktok, bollywood, transition, kpop, ai-image-editor, clothes-changer, ai-video-effects, ai-dance-video, camera-motion, ai-transformation-video, anime-video, video-game, ai-video-styles.
    detailsinteger / query否how many of the top results (0-5) to enrich with full detail
    project_typestring / query否only templates of this generation type, e.g. FACE_SWAP
    tagstring / query否only templates carrying this tag (case-insensitive), e.g. KPOP, MEMES, POPULAR, TIKTOK
    sortstring / query否'default' = the site's order, 'most_used' = most used first, 'newest' = newest first 可选值: default, most_used, newest.
    响应字段
    字段类型说明
    flowstring
    querynull
    categorystring
    details_requestedinteger
    countinteger
    templatesobject[]
    templates[].idstring
    templates[].namestring
    templates[].descriptionstring
    templates[].urlstring
    templates[].project_typestring
    templates[].source_typestring
    templates[].tagsstring[]
    templates[].used_countinteger
    templates[].widthinteger
    templates[].heightinteger
    templates[].created_atstring
    templates[].authornull
    templates[].preview_urlstring
    templates[].output_urlsstring[]
    templates[].settingsobject
    templates[].settings.fpsinteger
    templates[].settings.endSecondsinteger
    templates[].settings.startSecondsinteger
    templates[].settings.videoFile_urlstring
    templates[].settings.initialImage_urlstring
    templates[].detailsobject
    templates[].details.contentobject
    templates[].details.content.overviewstring
    templates[].details.content.what_it_doesstring
    templates[].details.content.who_its_forstring
    templates[].details.content.summarystring
    templates[].details.content.how_toobject[]
    templates[].details.content.how_to[].titlestring
    templates[].details.content.how_to[].descriptionstring
    templates[].details.content.use_casesobject[]
    templates[].details.content.use_cases[].titlestring
    templates[].details.content.use_cases[].descriptionstring
    templates[].details.content.use_cases[].bulletsstring[]
    templates[].details.content.best_practicesobject[]
    templates[].details.content.best_practices[].titlestring
    templates[].details.content.best_practices[].descriptionstring
    templates[].details.content.faqsobject[]
    templates[].details.content.faqs[].questionstring
    templates[].details.content.faqs[].answerstring
    templates[].details.content.related_toolsobject[]
    templates[].details.content.related_tools[].namestring
    templates[].details.content.related_tools[].urlstring
    templates[].details.content.related_tools[].descriptionstring
    templates[].details.relatedobject[]
    templates[].details.related[].idstring
    templates[].details.related[].namestring
    templates[].details.related[].urlstring
    paginationobject
    pagination.countinteger
    pagination.has_moreboolean
    pagination.next_cursornull
    fetched_atstring
    ageinteger
  • 搜索 GET /search

    与自由文本查询匹配的模板,来自 magichour.ai 自身的模板搜索(取其前 20 条结果,未指定排序时按其相关性排序)。模板字段同 /templates。

    GET /search 的参数和响应字段
    请求参数
    名称类型 / 位置必填说明
    qstring / query否search text, e.g. 'dance'
    project_typestring / query否only templates of this generation type (applied in the site's search), e.g. FACE_SWAP
    tagstring / query否keep only templates carrying this tag (case-insensitive), e.g. KPOP, MEMES, POPULAR, TIKTOK
    sortstring / query否'default' = the site's order, 'most_used' = most used first, 'newest' = newest first 可选值: default, most_used, newest.
    响应字段
    字段类型说明
    querystring
    countinteger
    templatesobject[]
    templates[].idstring
    templates[].namestring
    templates[].descriptionstring
    templates[].urlstring
    templates[].project_typestring
    templates[].source_typestring
    templates[].tagsstring[]
    templates[].used_countinteger
    templates[].widthinteger
    templates[].heightinteger
    templates[].created_atstring
    templates[].authornull
    templates[].preview_urlstring
    templates[].output_urlsstring[]
    templates[].settingsobject
    templates[].settings.fpsinteger
    templates[].settings.modelstring
    templates[].settings.promptstring
    templates[].settings.versionstring
    templates[].settings.endSecondsinteger
    templates[].settings.resolutionstring
    templates[].settings.aspectRatiostring
    templates[].settings.startSecondsinteger
    paginationobject
    pagination.countinteger
    pagination.has_moreboolean
    pagination.next_cursornull
    fetched_atstring
    ageinteger
  • 模板 GET /templates/{id}

    单个 magichour.ai 模板的完整信息:包含 /templates 的全部字段及其指南内容(概述、功能说明、适用人群、摘要、操作步骤、使用场景、最佳实践、相关工具、常见问题;纯文本,模板没有指南时为 null),`related`:网站与该模板一同展示的相关模板(字段同 /templates),以及 `source_url`:读取该模板所用的 magichour.ai 页面。

    GET /templates/{id} 的参数和响应字段
    请求参数
    名称类型 / 位置必填说明
    idstring / path是template id, or the id-slug from a template url (e.g. cmndlx5bh000kqe7u7n2fmy3v-bullet-time)
    响应字段
    字段类型说明
    idstring
    namestring
    descriptionstring
    urlstring
    project_typestring
    source_typestring
    tagsstring[]
    used_countinteger
    widthinteger
    heightinteger
    created_atstring
    authornull
    preview_urlstring
    output_urlsstring[]
    settingsobject
    settings.fpsinteger
    settings.lorastring
    settings.modelstring
    settings.versionstring
    settings.endSecondsinteger
    settings.resolutionstring
    settings.startSecondsinteger
    settings.initialImage_urlstring
    source_urlstring
    contentobject
    content.overviewstring
    content.what_it_doesstring
    content.who_its_forstring
    content.summarystring
    content.how_toobject[]
    content.how_to[].titlestring
    content.how_to[].descriptionstring
    content.use_casesobject[]
    content.use_cases[].titlestring
    content.use_cases[].descriptionstring
    content.use_cases[].bulletsstring[]
    content.best_practicesobject[]
    content.best_practices[].titlestring
    content.best_practices[].descriptionstring
    content.faqsobject[]
    content.faqs[].questionstring
    content.faqs[].answerstring
    content.related_toolsobject[]
    content.related_tools[].namestring
    content.related_tools[].urlstring
    content.related_tools[].descriptionstring
    relatedobject[]
    related[].idstring
    related[].namestring
    related[].descriptionstring
    related[].urlstring
    related[].project_typestring
    related[].source_typestring
    related[].tagsstring[]
    related[].used_countinteger
    related[].widthinteger
    related[].heightinteger
    related[].created_atstring
    related[].authornull
    related[].preview_urlstring
    related[].output_urlsstring[]
    related[].settingsobject
    paginationobject
    pagination.countinteger
    pagination.has_moreboolean
    pagination.next_cursornull
    fetched_atstring
    ageinteger

将 Magic Hour 数据导出为 CSV

下面的每个列表都可以下载为 CSV 文件,每条记录一行。用上方控制台下面的 "Get all the data, no code" 卡片把列表收集到数据集中。数据集会逐页读取列表,之后可下载为 CSV、JSON 或 JSONL。

列表CSV 列
模板GET /templatesid, name, description, url, project_type, source_type, tags, used_count, width, height, created_at, author, preview_url, output_urls, settings
探索GET /exploreid, name, description, url, project_type, source_type, tags, used_count, width, height, created_at, author, preview_url, output_urls, settings, details
搜索GET /searchid, name, description, url, project_type, source_type, tags, used_count, width, height, created_at, author, preview_url, output_urls, settings
模板GET /templates/{id}id, name, description, url, project_type, source_type, tags, used_count, width, height, created_at, author, preview_url, output_urls, settings

嵌套的值(列表或对象)以 JSON 写入同一个单元格。 数据集和导出如何工作

Magic Hour API 常见问题

能获取什么数据、费用多少、如何调用。

Magic Hour 有官方 API 吗?

有,Magic Hour 提供自己的 API:Magic Hour API(核实日期:2026-11-25)。本页的 Magic Hour API 与它无关,是非官方 API:它是 maviapi 针对 magichour.ai 上的公开数据提供的独立托管 API,并非由 Magic Hour 开发、认可或支持。

Magic Hour API 可以获取哪些数据?

Magic Hour API 有 5 个端点。每个端点都返回 JSON,参数和字段见上方的文档:

  • GET /categories: magichour.ai 模板主页列出的模板类别,按网站顺序排列:slug、显示名称和页面 URL。
  • GET /templates: magichour.ai 某个类别下的模板,与网站列出的一致:'all' 为模板主页(约 60 个热门模板),其他类别为对应页面的前约 20 个模板。
  • GET /explore: 一次调用完成发现:返回某次搜索(传入 q 时)或某个类别下的模板,其中前 `details` 个模板附带 `details` = {content: 指南内容(同 /templates/{id}),related_templates: [...]};其余模板的 details 为 null。
  • GET /search: 与自由文本查询匹配的模板,来自 magichour.ai 自身的模板搜索(取其前 20 条结果,未指定排序时按其相关性排序)。
  • GET /templates/{id}: 单个 magichour.ai 模板的完整信息:包含 /templates 的全部字段及其指南内容(概述、功能说明、适用人群、摘要、操作步骤、使用场景、最佳实践、相关工具、常见问题;纯文本,模板没有指南时为 null),`related`:网站与该模板一同展示的相关模板(字段同 /templates),以及…

Magic Hour API 的价格是多少?

调用用您 maviapi 套餐中的积分支付,只有成功的调用才会计费。此 API 的每个端点每次调用消耗 5 个积分。在 Hobby 套餐下(每月 $49,含 250,000 个积分),1,000 次调用约 $0.98。失败的调用不收费。Free 套餐每月提供 1,000 个积分,无需信用卡。超出部分请查看套餐和积分价格。

如何调用 Magic Hour API?

向端点发送 HTTPS 请求,并在 Authorization 请求头中带上您的 API 密钥。例如 GET /categories:

cURL
curl 'https://api.maviapi.com/v1/sites/magichour/categories' \
  -H "Authorization: Bearer $MAVI_KEY"

在您的 API 密钥页面创建密钥,或者先在上方的控制台中用免费测试密钥试用任意端点。

以 JSON 获取 Magic Hour 数据有哪些方式?

以 JSON 获取 Magic Hour 数据的每种方式适合不同的需求:

  • Magic Hour API: 需要写入权限、账号数据或与 Magic Hour 签订协议时更合适。
  • 自己写爬虫: 完全由自己掌控,不依赖任何服务商,但解析、被拦截的请求以及 magichour.ai 每次改版后的修复都要自己负责。更适合从很少变化的页面一次性获取数据。
  • Apify: 一个 Actor 市场,Actor 由您自己运行,输入、输出和价格由各个 Actor 决定。当已有 Actor 能返回您需要的数据,或者您想托管自己的代码时更合适。参见maviapi 与 Apify 的对比。
  • RapidAPI: 一个汇集了众多提供方 API 的平台,用一个 RapidAPI 密钥调用,每个 API 单独定价。当您已经在使用该平台,并且其中某个 API 能满足需求时更合适。来源:RapidAPI docs。
  • maviapi: 本页的 Magic Hour API:5 个带文档的端点、公开的响应结构,以及一个可用于整个目录的密钥。当这些数据是您产品的一部分,而您不想维护爬虫时更合适。

magichour.ai 改版后会怎样?

您的代码不需要改动。magichour.ai 修改页面时,maviapi 会让 Magic Hour API 保持可用,您继续调用同样的端点,并得到本页文档所述结构的 JSON。它当前的运行状况见状态页,变更记录见它的更新日志。

更新会破坏我的 Magic Hour API 集成吗?

不会。您正在使用的端点,其结构永远不会改变:新的字段、可选参数和端点只会加在旁边,会破坏调用的变更则作为新端点发布。请忽略您不认识的响应字段,新内容请关注更新日志。

  • Pixelbin API

    以 JSON 形式提供 Pixelbin 的公开目录:全部图像转换(标识符、参数、允许的取值、默认值、示例)、全部 AI 工具(描述、定价、常见问题)和全部博客文章(全文),支持搜索、筛选和分页,另有一个集搜索与详情于一体的…

  • Upsampler API

    以 JSON 形式提供 Upsampler.com 的 AI 模型目录:收录其全部图像/视频生成、放大和编辑模型,含评分、速度、积分价格、基准测试排名、优势、提示词技巧和示例输出,另有按工具划分的模型对比和 Upsampler 博客。

  • Tripadvisor API

    来自 Tripadvisor 的行程规划数据:支持地点搜索,并可按地点(geo_id)获取景点、餐厅和酒店,包含评分、评论、价格和坐标。先用 /search 解析地名,再通过…