这项功能适用于音乐服务、歌单策划、婚礼歌单生成器、DJ 工具、活动平台、电台节目、音乐博客、唱片店、唱片公司,以及任何展示或生成歌曲列表的业务。
向 Soundiiz 发送 JSON 格式的歌曲列表,即可获取临时导入链接。你可以在网站或应用中展示这个链接,让用户在 Soundiiz 中打开列表、核对歌曲,再转移到预设的目标平台或选择自己喜欢的音乐服务。
例如,如果你的服务会生成婚礼歌单、DJ 演出歌单、电台榜单或精选音乐,可以在旁边添加“通过 Soundiiz 转移”或“导入到我的音乐服务”按钮。
工作流程
你的系统向 Soundiiz 发送 POST 请求,其中包含歌单标题、可选的来源信息、可选的目标平台,以及歌曲列表。
Soundiiz 返回临时链接shareUrl。
随后,你可以将用户重定向到这个 URL,在新标签页中打开它,或将它关联到网站上的按钮。
用户可以:
常见使用场景
这项功能可用于多种服务,例如:
你无需为每个音乐流媒体服务单独开发集成。Soundiiz 会处理音乐平台的连接和转移流程。
通过 MCP 连接 AI 助手
如果你的 AI 应用支持自定义远程 MCP 服务器,可以将它连接到 Soundiiz,以准备歌单导入、列出导入目标并查看转移选项。请参阅通过 MCP 将 AI 助手连接到 Soundiiz 的指南(英文)。
导入 AI 生成歌单的其他方式
AI 生成的歌曲列表也可以在没有 MCP 连接的情况下导入:
Artist - Title格式的内容,并引导用户在 Soundiiz 中打开导入歌单 > 纯文本,粘贴列表、核对歌曲并选择目标平台。请参阅纯文本导入指南。shareUrl值。创建这个临时链接无需 API 密钥或 Soundiiz 订阅。不要编造链接,也不要声称目标音乐服务中已经创建了歌单。用户需要在 Soundiiz 中核对歌曲列表并完成转移。转移条件和用户套餐的限制仍然适用。已知歌手姓名时请填写;不确定的可选专辑或 ISRC 信息请省略,不要猜测。
接口地址
POST https://soundiiz.com/go/import-playlist
Content-Type: application/json
JSON 请求体
请求体必须是有效的 JSON 对象。
{
"title": "Wedding Party Playlist",
"sourceName": "My Wedding Playlist Builder",
"sourceLogo": "https://example.com/logo.png",
"description": "A playlist generated for Sarah & James wedding party.",
"destination": "spotify",
"tracklist": [
{
"title": "Get Lucky",
"artists": ["Daft Punk", "Pharrell Williams"],
"album": "Random Access Memories",
"isrc": "USQX91300105"
},
{
"title": "One More Time",
"artists": ["Daft Punk"]
},
{
"title": "September",
"artists": ["Earth, Wind & Fire"]
}
]
}
必填字段
每首歌都必须包含title。
可选字段
当destination对应可接收歌单的平台时,Soundiiz 会跳过目标选择步骤。不提供此字段时,用户会在 Soundiiz 中选择目标。如果提供,内容必须是非空的 Soundiiz 平台 corename,且该服务可用、可连接并能接收歌单。空值、无效、未知或不受支持的目标会返回 HTTP 400,不会改为手动选择。
支持的目标平台 corename
此接口支持的全部 38 个目标平台,更新于 2026 年 11 月 2 日。请在可选字段destination中使用准确的 API corename,它可能与服务名称或公开 URL 的 slug 不同。
对于 Apple Music,请使用applemusicapp。其他 Soundiiz 入口使用的别名applemusic不适用于此接口。对于 YouTube Music,请使用ytmusic,而不是youtube-music。
服务可用性和账号使用条件可能会变化。请查看服务功能和平台状态。功能目录使用公开的 slug,而非 API corename。要让用户在 Soundiiz 中自行选择目标,请省略destination;无效或不受支持的值会返回 HTTP 400。
歌曲的可选字段
多位歌手的示例:
{
"title": "Get Lucky",
"artists": ["Daft Punk", "Pharrell Williams"],
"album": "Random Access Memories",
"isrc": "USQX91300105"
}
歌手为单个字符串的示例:
{
"title": "Billie Jean",
"artists": "Michael Jackson"
}
成功响应
如果导入请求被接受,Soundiiz 会返回一个可分享给用户的临时 URL。
{
"status": "success",
"nbTracks": 3,
"shareUrl": "https://soundiiz.com/go/import-playlist/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"expiresAt": 1782220923
}
按钮流程示例
常见实现方式如下:
- 用户在你的网站上查看歌曲列表。
- 点击“通过 Soundiiz 转移”等按钮。
- 你的后端通过 POST 接口将歌曲列表发送给 Soundiiz。
- Soundiiz 返回链接
shareUrl。 - 你的网站将用户重定向到这个 URL。
例如,你的界面可以在“Spotify”按钮中发送"destination": "spotify",并在“其他”按钮中省略此字段,让用户在 Soundiiz 中自行选择平台。
按钮文案示例:
cURL 示例
curl -X POST "https://soundiiz.com/go/import-playlist" \
-H "Content-Type: application/json" \
-d '{
"title": "Wedding Party Playlist",
"sourceName": "My Wedding Playlist Builder",
"sourceLogo": "https://example.com/logo.png",
"description": "A playlist generated for Sarah & James wedding party.",
"destination": "spotify",
"tracklist": [
{
"title": "Get Lucky",
"artists": ["Daft Punk", "Pharrell Williams"],
"album": "Random Access Memories",
"isrc": "USQX91300105"
},
{
"title": "One More Time",
"artists": ["Daft Punk"]
},
{
"title": "September",
"artists": ["Earth, Wind & Fire"]
}
]
}'
错误响应
如果请求无效,Soundiiz 会返回错误响应。
{
"status": "error",
"message": "Invalid JSON body."
}
其他可能的验证错误包括:
{
"status": "error",
"message": "Missing playlist 'title' field."
}
{
"status": "error",
"message": "Missing or empty 'tracklist'."
}
{
"status": "error",
"message": "Missing track title at index 1."
}
{
"status": "error",
"message": "Invalid tracklist. Your tracklist must include at least 1 track and up to 200 tracks."
}
{
"status": "error",
"message": "Invalid playlist 'destination' field."
}
{
"status": "error",
"message": "Unsupported playlist destination 'unknown'."
}
重要说明
导入链接是临时链接,请在生成后尽快使用。
歌曲列表必须包含 1 至 200 首歌。
Soundiiz 会使用所提供的歌曲标题和歌手信息,帮助用户找到对应歌曲并转移到所选目标平台。
此接口不会直接在用户账号中创建歌单,而是创建一个临时的 Soundiiz 导入页面。用户可在其中核对歌曲列表,再转移到预设的目标平台或选择其他目标。