- Python Programming Blueprints
- Daniel Furtado Marcus Pennington
- 326字
- 2021-06-24 18:53:48
Creating a Remote-Control Application with Spotify
Spotify is a music streaming service that was developed in Stockholm, Sweden. The first version was released back in 2008 and today it doesn't only provide music, but video and podcasts as well. Growing rapidly from a startup in Sweden to the biggest music service in the world, Spotify has apps running on video game consoles and mobile phones, and has integration with many social networks.
The company really has changed how we consume music and has also enabled not only well-known artists but small indie artists to share their music with the world.
Luckily, Spotify is also a great platform for developers and provides a really nice and well-documented REST API where it's possible to make searches by artists, albums, song names, and also create and share playlists.
For the second application in this book, we are going to develop a terminal application where we can:
- Search artists
- Search albums
- Search tracks
- Play music
Apart from all these features, we are going to implement functions so we can control the Spotify application through the terminal.
First, we are going to go through the process of creating a new application on Spotify; then, it will be time to develop a small framework that will wrap some parts of Spotify's REST API. We are also going to work on implementing different types of authentication supported by Spotify, in order to consume its REST API.
When all these core functionalities are in place, we are going to develop a terminal user interface using the curses package that is distributed with Python.
In this chapter, you will learn:
- How to create a Spotify app
- How to use OAuth
- Object-oriented programming concepts
- Using the popular package Requests to consume REST APIs
- How to design terminal user interfaces using curses
I don't know about you, but I really feel like writing code and listening to some good music, so let's get right into it!
- Application Development with Qt Creator(Second Edition)
- 物聯網安全(原書第2版)
- 局域網組建、管理與維護項目教程(Windows Server 2003)
- 通信簡史:從信鴿到6G+
- NB-IoT物聯網技術解析與案例詳解
- 企業網絡安全管理
- 城域網與廣域網(第2版)
- 基于性能的保障理論與方法
- 物聯網與智能家居
- 夢工廠之材質N次方:Maya材質手冊
- 一本書讀懂物聯網
- 移動物聯網:商業模式+案例分析+應用實戰
- LwIP應用開發實戰指南:基于STM32
- 5G非正交多址接入技術:理論、算法與實現
- Hands-On Docker for Microservices with Python