Skip to content

Latest commit

 

History

History
87 lines (80 loc) · 4.38 KB

File metadata and controls

87 lines (80 loc) · 4.38 KB

in the main page, click on the green code button then download zip. then unzip the folder anywhere you want to keep the program.

Install node (to run the local web server to interact with soundcloud)

  1. download and install node from the node website
    https://nodejs.org/en/download/package-manager
    
    1. to test node is setup correctly run the following command in a terminal
    node --version
    npm --version
    
    1. you should see a version number for node and for npm
    2. if it does not work your installation was unsuccessful or node and/or npm have not been added to your path
  2. run the script to install the node dependances
    1. WINDOWS: run setup_dependancies.bat
    2. MACOS: run setup_dependancies.sh

Get soundcloud credentials

  1. create a copy of sc_config_template.js in the Soundcloud-Local folder and rename it to sc_config.js
  2. open sc_config.js in your preferred text editor
  3. open chrome
  4. visit soundcloud.com (login if you aren't already)
  5. open chrome's devtools by pressing F12 or right-click in chrome and click inspect
  6. go to the network tab in devtools
  7. go to the feed page
  8. enable Filter in network tab by clicking the funnel icon (between the stop and magnifying glass icons) an extra row with a small filter icon and input box with Filter written in it should appear
  9. in the filter input box, enter the following
    stream?
    
  10. now there should only be one network request in the list. click on that request, it will show the details of the request in a sub-window to the right
  11. click on the Headers tab in the request details sub-window
  12. Scroll all the way down, you should see a sub-section called Request Headers
  13. under Request Headers, find Authorization, its value should look like OAuth 2-123456-123456789-abcdefghijklmn
  14. copy the value of Authorization WITHOUT THE OAuth PART
    2-123456-123456789-abcdefghijklmn
    
  15. in sc_config.js that you opened earlier, paste the Authorization value without OAuth or any spaces into oauth_token
  16. back in the network tab, click on the Payload tab in the request details sub-window
  17. find client_id and copy the value
  18. in sc_config.js, paste the client_id value without any spaces into client_id
  19. back in the network tab, find user_urn it should look like soundcloud:users:123456789
  20. copy the numbers of user_urn WITHOUT THE soundcloud:users:
    123456789
    
  21. in sc_config.js, paste the user_urn numbers without any spaces into user_id
  22. go to your profile page
  23. back in the filter input box, replace stream? with the following
    tracks?
    
  24. you might have multiple results, click on one that has a symbol next to it that looks like {;}, another way to check you selected the right one is in selected requests' subwindow on the right, under the General section, the second entry Request Method should be GET (if you see OPTIONS then select a different request)
  25. Scroll all the way down, you should see a sub-section called Request Headers
  26. under Request Headers, find x-datadome-clientid, its value should look like AKJSDHalkjdnsaKLJASBDKLJBJaslkjbdLKJBJDSlkjbsakljbjdaLKJBJ
  27. copy the value of x-datadome-clientid
  28. in sc_config.js, paste the x-datadome-clientid value without any spaces into datadome_clientid
  29. back in the network tab, find User-Agent, its value should look like Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36
  30. copy the value of User-Agent
  31. in sc_config.js, paste the User-Agent value without any spaces into user_agent
  32. your sc_config.js should now look like
    const oauth_token = "2-123456-123456789-abcdefghijklmn";
    const client_id = "JKSHDFKljhfkjlshfalhfalhfalkdfhs";
    const user_id = "123456789";
    const datadome_clientid = "AKJSDHalkjdnsaKLJASBDKLJBJaslkjbdLKJBJDSlkjbsakljbjdaLKJBJ";
    const user_agent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36"
    
    if (typeof module !== "undefined" && module.exports) {
      module.exports = {
        oauth_token,
        client_id,
        user_id,
        datadome_clientid,
        user_agent
      };
    }
    
  33. save and close sc_config.js and chrome