CocoaPods trunk is moving to be read-only. Read more on the blog, there are 14 months to go.
| TestsTested | ✗ |
| LangLanguage | SwiftSwift |
| License | MIT |
| ReleasedLast Release | Aug 2017 |
| SwiftSwift Version | 4.0 |
| SPMSupports SPM | ✓ |
Maintained by Scott Hoyt.
The Missing Apple Music SDK. Written in Swift.
Add to your Package.swift file like so:
import PackageDescription
let package = Package(
name: "<YOUR_PROJECT_NAME>",
dependencies: [
.package(url: "https://github.com/scottrhoyt/Cider.git", from: "0.10.0")
]
)To use the Apple Music API, you will need to generate a developer token. Instructions for how to do this can be found in the Apple Music API reference.
Once you have an Apple Music Key you can use a 3rd party library/tool to generate your token. I created a Node.js library and CLI tool that you can find here.
let developerToken = "<developer_token>"
let cider = CiderClient(storefront: .unitedStates, developerToken: developerToken)cider.search(term: "Michael Jackson", types: [.albums, .songs]) { results, error in
// Process the results or error
}let songId = "<song_id>"
cider.song(id: songId) { result, error in
// Process the results or error
}The full API reference can be found here.
MIT