To ensure legal compliance, I need to comply with multiple requirements.
Since spotipy and ytmusicapi use the MIT license, I should do the same for ease of licensing. I should include a LICENSE.txt file.
Although not a legal requirement, I can add a readme that politely requests payment (or at least attribution) for my work (no matter how small it may be).
I need to make it clear how ytmusicapi works. I need to inform the user that it will "open an invisible browser that accesses YouTube Music using their credentials". Each utility will need to print what it does.
Warn user that the rater and downloader will call yt-dlp and ffmpeg, so they need to install them and accept their licenses.
I need to comply with the Spotify license terms about retaining their data. That means I need to make it clear the "songs db" is a cache by updating its name in the code, and adding comments to the code.
"This tool, its integrated ytmusicapi library, and its integrated spotipy library operate under the MIT license. To unofficially summarize: you can run with tool with almost no restrictions, but if bad things happen, it's your own fault for trusting random pieces of code from the internet. The specific, legally binding text of the MIT license is the following block of text:
"Playlist Optimizer" Copyright (c) 2022 Andrew LeDawson
"ytmusicapi" Copyright (c) 2020 sigma67
"spotipy" Copyright (c) 2021 Paul Lamere
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
As required by Spotify, you must agree to the following paragraph to access the Spotify API: You do not have any warranties or representations on behalf of Spotify and you disclaim all implied warranties with respect to the Spotify Platform, Spotify Service and Spotify Content, including the implied warranties of: merchantability, fitness for a particular purpose, and non-infringement. You are prohibited from modifying or creating derivative works based on the Spotify Platform, Spotify Service, or Spotify Content. You are prohibited from decompiling, reverse-engineering, disassembling, and otherwise reducing the Spotify Platform, Spotify Service, and Spotify Content to source code or other human-perceivable form, to the full extent allowed by law. The developer of this tool disclaims any liability on the part of third parties (e.g., Spotify). Spotify is a third party beneficiary of this end user license agreement and privacy policy and is entitled to directly enforce this end user license agreement.
This tool can also call ffplay (a tool from the ffmpeg collection) and yt-dlp while rating songs or downloading your songs. Since you have to install/copy them yourself, you are agreeing to their licenses. This tool should warn you when it might run those tools on your behalf.
Privacy Policy: This tool will describe how it uses and transmits your data with simple language every time you run it - you just have to read each of the prompts. It is designed to only use your data to make requests to Spotify and YouTube Music, with permission. You can delete the cookies.txt file, headers_auth.json, and spotify.json files to purge the credentials used to make those requests (which include the only cookies used by this tool). You can delete the song_datacache.yts and playlist*.ytp files to remove your cached song data and cached playlists, respectively. And you can delete user_preferences.plo to remove any preferences you have set. This tool is not designed to place or access any trackers, user data, or cookies besides what is mentioned above. If you have any questions, open an issue on this tool's GitHub repository so it can be answered: https://github.com/andrew-ledawson/playlist-optimizer/issues/"
To ensure legal compliance, I need to comply with multiple requirements.
"This tool, its integrated ytmusicapi library, and its integrated spotipy library operate under the MIT license. To unofficially summarize: you can run with tool with almost no restrictions, but if bad things happen, it's your own fault for trusting random pieces of code from the internet. The specific, legally binding text of the MIT license is the following block of text:
"Playlist Optimizer" Copyright (c) 2022 Andrew LeDawson "ytmusicapi" Copyright (c) 2020 sigma67 "spotipy" Copyright (c) 2021 Paul Lamere Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
As required by Spotify, you must agree to the following paragraph to access the Spotify API: You do not have any warranties or representations on behalf of Spotify and you disclaim all implied warranties with respect to the Spotify Platform, Spotify Service and Spotify Content, including the implied warranties of: merchantability, fitness for a particular purpose, and non-infringement. You are prohibited from modifying or creating derivative works based on the Spotify Platform, Spotify Service, or Spotify Content. You are prohibited from decompiling, reverse-engineering, disassembling, and otherwise reducing the Spotify Platform, Spotify Service, and Spotify Content to source code or other human-perceivable form, to the full extent allowed by law. The developer of this tool disclaims any liability on the part of third parties (e.g., Spotify). Spotify is a third party beneficiary of this end user license agreement and privacy policy and is entitled to directly enforce this end user license agreement.
This tool can also call ffplay (a tool from the ffmpeg collection) and yt-dlp while rating songs or downloading your songs. Since you have to install/copy them yourself, you are agreeing to their licenses. This tool should warn you when it might run those tools on your behalf.
Privacy Policy: This tool will describe how it uses and transmits your data with simple language every time you run it - you just have to read each of the prompts. It is designed to only use your data to make requests to Spotify and YouTube Music, with permission. You can delete the cookies.txt file, headers_auth.json, and spotify.json files to purge the credentials used to make those requests (which include the only cookies used by this tool). You can delete the song_datacache.yts and playlist*.ytp files to remove your cached song data and cached playlists, respectively. And you can delete user_preferences.plo to remove any preferences you have set. This tool is not designed to place or access any trackers, user data, or cookies besides what is mentioned above. If you have any questions, open an issue on this tool's GitHub repository so it can be answered: https://github.com/andrew-ledawson/playlist-optimizer/issues/"