Skip to content

Instantly share code, notes, and snippets.

View hack0x90's full-sized avatar

hack0x90 hack0x90

View GitHub Profile
@hack0x90
hack0x90 / run_sc.bash
Created May 15, 2022 20:54
Running SoundCloud Downloader Script
node index.js "https://soundcloud.com/shanyhaider/teri-photo-shany-haider-ft-zubab-rana-kashmir-beats"
@hack0x90
hack0x90 / sc_index.js
Created May 15, 2022 20:53
SoundCloud mp3 Download Index.js File
import { spawn } from 'child_process';
import { parse } from 'node-html-parser';
const client_id = process.env.SOUNDCLOUD_CLIENT_ID;
const link = process.argv[2] || 'https://soundcloud.com/rashidaliofficial/kabhi-kabhi-aditi';
/*
* Download SoundCloud track page HTML code
@hack0x90
hack0x90 / sc-download-setup.bash
Created May 15, 2022 20:52
Setup SoundCloud mp3 download project
npm init -y soundcloud-downloader
cd soundcloud-downloader
npm install --save node-html-parser
touch index.js
code .
@hack0x90
hack0x90 / sc_track_playlist_request.txt
Created May 15, 2022 20:50
SoundCloud Track Playlist request URL
https://api-v2.soundcloud.com/media/soundcloud:tracks:1222368529/a55e2774-0c3b-4ad7-9490-215e0cfce14d/stream/hls?client_id=uN6D9tWD2uBjPHpRPgZExfzjyz0Sv4Bf&track_authorization=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJnZW8iOiJQSyIsInN1YiI6IiIsInJpZCI6ImIxMjgwMTA4LTljMmMtNDM4Mi1iNTBkLWEwNmQzYjc4NGNkNyIsImlhdCI6MTY1MjAzNTE2MX0.Orl46D2FPe7PcJcR-SGxQ5roZ6_75Ss-93PdEkUnEkw
@hack0x90
hack0x90 / sc_track_playlist_route.txt
Created May 15, 2022 20:49
SoundCloud Track Playlist route
https://cf-hls-media.sndcdn.com/playlist/uWlzccjYfaS3.128.mp3/playlist.m3u8?Policy=eyJTdGF0ZW1lbnQiOlt7IlJlc291cmNlIjoiKjovL2NmLWhscy1tZWRpYS5zbmRjZG4uY29tL3BsYXlsaXN0L3VXbHpjY2pZZmFTMy4xMjgubXAzL3BsYXlsaXN0Lm0zdTgqIiwiQ29uZGl0aW9uIjp7IkRhdGVMZXNzVGhhbiI6eyJBV1M6RXBvY2hUaW1lIjoxNjUyMDM1NDUzfX19XX0_&Signature=ZLM9vBNwkWm8Di~dPqTlYRK-8rVCL0xFwDThRf9Lm6NWfCEi1C4xQKBsZmZAyMZegCjd~tLB7PQhu~bndZFbg-HS5PLoFowZKvLoqdudl28S7eLWhl~F5a7V~WctrbHBBKnmbcuJgBDodOleYR4jz-kqruQm8gx9TuOrRqp6AmMAihMo53vyHXm8uU3nGhu7D35Y1faKTI5hqGuv3IdS0cxKCAcQBPriSw6cncwEo5vr8S8UCyxnhjZpMteQ16f5B73UKWKvsN9WrKIT6egKI5cg57z7jlLofw8BIUab5pmXX7xpPGAy6K3z620xw5x3nw8CvE91QVSOhkrKH2euMg__&Key-Pair-Id=APKAI6TU7MMXM5DG6EPQ&track_authorization=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJnZW8iOiJQSyIsInN1YiI6IiIsInJpZCI6ImIxMjgwMTA4LTljMmMtNDM4Mi1iNTBkLWEwNmQzYjc4NGNkNyIsImlhdCI6MTY1MjAzNTE2MX0.Orl46D2FPe7PcJcR-SGxQ5roZ6_75Ss-93PdEkUnEkw
@hack0x90
hack0x90 / sc_hydration_obj.js
Created May 15, 2022 20:45
SoundCloud hydration object
[
{...},
{...},
{...},
{...},
{...},
{...},
{...},
{
"hydratable": "sound",
@hack0x90
hack0x90 / sc_script_start.html
Created May 15, 2022 20:44
SoundCloud Track Page HTML script tag start of script
// Start of code
window.__sc_hydration = [{"hydratable":"anonymousId","data":"676018-67194 ... ];
@hack0x90
hack0x90 / soundcloud_track_page_html_script_tag.html
Last active May 15, 2022 20:39
SoundCloud Track Page HTML script tag contents
<script>
window.__sc_hydration = [{"hydratable":"anonymousId","data":"676018-671947-481806-62137"},{"hydratable":"features","data":{"features":["mobi_use_onetrust_gb","v2_enable_onetrust_user_id","v2_use_onetrust_tcfv2_eu1","v2_ie11_support_end","v2_use_onetrust_eu2","mobi_enable_onetrust_tcfv2","mobi_use_onetrust_eu1","v2_use_onetrust_user_id_eu2","v2_enable_sourcepoint_tcfv2","mobi_peace_ukraine_logo_takeover","v2_peace_ukraine_logo_takeover","mobi_social_sharing","mobi_use_onetrust_tcfv2_eu2","mobi_use_onetrust_user_id_eu1","mobi_enable_onetrust_user_id","mobi_use_onetrust_user_id_ex_us","mobi_use_onetrust_tcfv2_eu1","v2_post_with_caption","mobi_use_onetrust_eu4","featured_artists_banner","v2_repost_redirect_page","v2_use_onetrust_gb","mobi_use_onetrust_user_id_global","use_onetrust_async","v2_signals_collection","v2_direct_support_link","v2_hq_file_storage_release","mobi_use_onetrust_user_id_eu2","v2_use_onetrust_eu4","v2_stories_onboarding","v2_enable_onetrust","v2_import_playlist_experiment","v2_disab
@hack0x90
hack0x90 / download_soundcloud_html.sh
Last active May 15, 2022 20:32
Download SoundCloud Track Page HTML
curl \
-A Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.4 Safari/605.1.15 \
https://soundcloud.com/rashidaliofficial/kabhi-kabhi-aditi
@hack0x90
hack0x90 / soundcloud_mp3_download_ffmpeg
Last active February 11, 2024 17:33
Using ffmpeg to download mp3 files from SoundCloud
ffmpeg -i \
https://cf-hls-media.sndcdn.com/playlist/uWlzccjYfaS3.128.mp3/playlist.m3u8?Policy=eyJTdGF0ZW1lbnQiOlt7IlJlc291cmNlIjoiKjovL2NmLWhscy1tZWRpYS5zbmRjZG4uY29tL3BsYXlsaXN0L3VXbHpjY2pZZmFTMy4xMjgubXAzL3BsYXlsaXN0Lm0zdTgqIiwiQ29uZGl0aW9uIjp7IkRhdGVMZXNzVGhhbiI6eyJBV1M6RXBvY2hUaW1lIjoxNjUyMDM1NDUzfX19XX0_&Signature=ZLM9vBNwkWm8Di~dPqTlYRK-8rVCL0xFwDThRf9Lm6NWfCEi1C4xQKBsZmZAyMZegCjd~tLB7PQhu~bndZFbg-HS5PLoFowZKvLoqdudl28S7eLWhl~F5a7V~WctrbHBBKnmbcuJgBDodOleYR4jz-kqruQm8gx9TuOrRqp6AmMAihMo53vyHXm8uU3nGhu7D35Y1faKTI5hqGuv3IdS0cxKCAcQBPriSw6cncwEo5vr8S8UCyxnhjZpMteQ16f5B73UKWKvsN9WrKIT6egKI5cg57z7jlLofw8BIUab5pmXX7xpPGAy6K3z620xw5x3nw8CvE91QVSOhkrKH2euMg__&Key-Pair-Id=APKAI6TU7MMXM5DG6EPQ&track_authorization=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJnZW8iOiJQSyIsInN1YiI6IiIsInJpZCI6ImIxMjgwMTA4LTljMmMtNDM4Mi1iNTBkLWEwNmQzYjc4NGNkNyIsImlhdCI6MTY1MjAzNTE2MX0.Orl46D2FPe7PcJcR-SGxQ5roZ6_75Ss-93PdEkUnEkw \
sc_track.mp3