Rdio Desktop API 是否为曲目提供唯一 ID?

发布于 2024-12-19 16:58:44 字数 330 浏览 5 评论 0 原文

我为自己构建了一个小型桌面应用程序,用于记录来自 iTunes 和 Rdio 的收听情况,以便我可以根据我随着时间的推移听音乐的方式创建强大的播放列表,但它要求每个曲目都有一个永远不会改变的唯一 ID,无论我用哪个应用程序听。我目前使用 Python 中的 appscript 从 iTunes 检索唯一 ID:

from appscript import *
it = app('iTunes')
it.current_track.persistent_ID()

但是,当浏览 Rdio Suite AppleScript 词典时,我没有看到任何附加到曲目的唯一 ID。建议?

I've built a small desktop app for myself that logs listens from iTunes and Rdio so I can create powerful playlists based on how I listen to music over time, but it requires each track to have a unique ID that will never change, regardless of which app I used to listen. I currently retrieve unique IDs from iTunes using appscript in Python:

from appscript import *
it = app('iTunes')
it.current_track.persistent_ID()

However, when poking through the Rdio Suite AppleScript Dictionary I don't see any kind of unique ID attached to tracks. Suggestions?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

我很OK 2024-12-26 16:58:45

Rdio 有一个 API。以下是有关如何获取当前播放曲目的一些信息:http://groups.google.com/group/rdio-api/browse_thread/thread/23d52c77b4e56a55/3b8a897f0835fd90

您还可以通过 Applescript 获取当前播放曲目的 url。这应该作为轨道的一种唯一 ID:

osascript -e 'tell app "Rdio" to get the rdio url of the current track'

Rdio has an API. Here's some info on how to get the currently playing track: http://groups.google.com/group/rdio-api/browse_thread/thread/23d52c77b4e56a55/3b8a897f0835fd90

You can also get the url of the currently playing track via Applescript. This should serve as a sort of unique ID for the track:

osascript -e 'tell app "Rdio" to get the rdio url of the current track'
公布 2024-12-26 16:58:45

所有 Rdio 对象,包括 Tracks 有一个 key 属性,它是唯一的 ID,可用于使用 获取

All Rdio objects, including Tracks have a key attribute that is the unique ID that can be used to look it up in Rdio using get.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文