Task Breakdown & Plan
We are using Trello to create and assign tasks (see image below).
Backend NodeJS - write NodeJS code which takes an access token and makes API calls to retrieve tacks from Artists, Albums, Playlists, etc. Code should also provide functions for generating a tree which represents a logic scheme for a playlist using various types of nodes (source nodes, logic gate nodes, filter nodes, etc.). Resolving the tree should compute the final track list and save to a new playlist on the. The tree should be able to generate by parsing a JSON string representing its configuration.
Spotify Developer Management - Setup access for the team on the Spotify Developer Dashboard.
Spotify Login - utilize the Spotify templates to host a site that lets the user login with Spotify. Obtain a refresh token which will enable our API calls. Repeat for Apple Music down the road.
Front End Site - Create site using HTML, CSS, Javascript, React, and various libraries. This is how the end user will interact with our platform. It should include a login hook for Spotify (and eventually Apple music). It should provide the ability to create an account and view / edit your smart playlists via a drag and drop system. Should communicate with the backend server for account management requests, and editing / saving playlists configurations via JSON transfer.
Caching - Cache responses of backend API calls using Redis to limit the number of calls we have to make.
MongoDB - Create database for holding account credentials, user info, user access tokens for Spotify & Apple music, and JSON strings representing playlist configurations.
Amazon Web Services - get our site hosted on AWS instead of on the Raspberry Pi.
Concepts
Alternative designs we've considered include:
Login method
Login with credentials for our site. We hold your Spotify access token.
Login with your Spotify.
Server infrastructure
Raspberry Pi (access site via IP address)
Amazon Web Services
Access Tiers
Everything is free. Unlimited smart playlists of unlimited size / API call counts. Playlists are automatically updated for everyone.
Free and paid tier - Free tier has limits on smart playlist counts and API call counts. Playlists are generated one time and must be manually updated by regenerating. Paid tier has unlimited smart playlist counts and API call counts, playlists are automatically updated for them periodically.
Selection
The designs we believe make the most sense...
Login with credentials for our site and just link your Spotify and Apple Music. Once we integrate Apple Music we can't force users to login with a Spotify account.
Raspberry Pi for now but eventually AWS - Pi is free for now and easy to work with during the development process. But when we launch on AWS we won't have to worry about the IP changing (we will have a unique domain) and we can easily scale up resources when necessary.
Free Tier is in development for now, to be reassessed later on in development cycle depending on whether or not we start to hit API call restraints
Design
We are using Lucidchart to prototype what the site should look like in the end. It is viewable here.
Analysis
Hardware Specifications :
Raspberry Pi 3b+ for initial hosting
Eventually migrate to AWS
Software Specifications :
Backend - Cron and NodeJS using the following libraries - dotenv, express, http, https, request, and request-promise.
Frontend - HTML, CSS, and Javascript using the following libraries - React, Animation Event, Leader Line, Plain Draggable, Cookie Parser, Cors, and dotenv.
Test Plan
Design tests procedures to validate product features
Example Test Procedure 1:
Playlist A OR Playlist B
Log in to Smart Playlist Manager
Ensure Spotify account is linked
Use website tools to create playlist configuration: Playlist A OR Playlist B
Create playlist
Open Spotify
Observe new playlist
Compare contents of playlist to expected results
This can be repeated for more complicated logic schemes and for Apple Music smart playlists.
Example Test Procedure 2:
Cross Platform Playlist
Log in to Smart Playlist Manager
Ensure Spotify & Apple Music accounts are linked
Use website tools to route a Spotify playlist to Apple Music or vice versa.
Finalize and ensure playlists are identical (to the extend that the can be).