Audio/video stream recording forums (http://stream-recorder.com/forum/index.php)
-   Audio stream recording (http://stream-recorder.com/forum/forumdisplay.php?f=5)
-   -  

Record Clear Channel radio stations (iheartradio.com)

(http://stream-recorder.com/forum/showthread.php?t=6306)

Schadenfreude 09-05-2010 05:30 PM

Re: Record Clear Channel radio stations (iheartradio.com)


 
any updates on this? I'm looking to record a live iheartradio stream at a certain time, rtmpdump cannot find a playpath.

jason331 11-18-2010 02:04 PM

Re: Record Clear Channel radio stations (iheartradio.com)


 
I got command line recording working from a batch file using rtmpdump in Windows. Here's how I did it:

I've been wanting to record Coast To Coast AM since it comes on well after I've gone to sleep but have never been able to do it reliably. Here in Houston it comes on KTRH-AM and is also available via iheartradio, so I created a batch file that contains the following:

REM Download the XML file containing the unique auth code
wget "http://p2.ktrh-am.ccomrcdn.com/player/player_dispatcher.html?section=radio&action=listen _live"
REM delete the existing XML file from the previous recording
del ktrh-am.xml
REM rename the newly-downloaded XML file from above to a usable format
ren "player_dispatcher.html@section=radio&action=liste n_live" ktrh-am.xml
REM Get the unique auth code from the XML file (the dots in the line below are used to get all 68 characters of the unique auth code)
for /f "delims=" %%a in ('sed -n "s/.*\(auth=......................................... ...........................\).*/\1/p" ktrh-am.xml') do @set ccam=%%a
REM Build the URL that will be passed to rtmpdump
set ktrh="rtmp://cp20100.live.edgefcs.net/live/Hou_TX_KTRH-AM_OR@s7890?%ccam%&aifp=1234&CHANNELID=2285&CPROG= _&MARKET=HOUSTON-TX&REQUESTOR=KTRH-AM&SERVER_NAME=p2.ktrh-am.ccomrcdn.com&SITE_ID=700&STATION_ID=KTRH-AM&MNM=1&TYPEOFPLAY=0"
REM Record the audio
rtmpdump.exe -v -r %ktrh% -o d:\recordings\coasttocoastam.flv

I had to use two Unix commands (ported to Windows): sed and wget to make everything work correctly. I noticed that each time I refreshed the XML page only the auth code changed. This allowed me to script the process using the batch commands above.

This is by no means perfect but it can be run as a scheduled task and works for what I need.

jason331 11-20-2010 11:04 PM

Re: Record Clear Channel radio stations (iheartradio.com)


 
1 Attachment(s)
OK, so here's a better version of my batch file that records Coast To Coast AM on 740 KTRH here in Houston from iheartradio. You can modify the URL below to fit your own station preferences:

REM Downloads the XML file from iheartradio
REM
wget "http://p2.ktrh-am.ccomrcdn.com/player/player_dispatcher.html?section=radio&action=listen _live"
REM
REM Deletes the existing XML file
del ktrh-am.xml
REM
REM Renames the downloaded file to the correct format
ren "player_dispatcher.html@section=radio&action=liste n_live" ktrh-am.xml
REM
REM Gets the unique 68-character auth key from the XML file and sets it to a variable
for /f "delims=" %%a in ('sed -n "s/.*\(auth=......................................... ...........................\).*/\1/p" ktrh-am.xml') do @set ccam=%%a
REM
REM Builds the RTMP URL that gets passed to RTMPdump later below
set ktrh="rtmp://cp20100.live.edgefcs.net/live/Hou_TX_KTRH-AM_OR@s7890?%ccam%&aifp=1234&CHANNELID=2285&CPROG= _&MARKET=HOUSTON-TX&REQUESTOR=KTRH-AM&SERVER_NAME=p2.ktrh-am.ccomrcdn.com&SITE_ID=700&STATION_ID=KTRH-AM&MNM=1&TYPEOFPLAY=0"
REM
REM Downloads the show to an FLV file for 7200 seconds (two hours) and then stops
rtmpdump.exe -v -B 7200 -r %ktrh% -o D:\MP3\CoastToCoastAM\coasttocoastam.flv
REM
REM Part one of the MP3 conversion process; converts the FLV file to an AAC file
FLVExtractCL.exe -a -o D:\MP3\CoastToCoastAM\coasttocoastam.flv
REM
REM Part two of the MP3 conversion process; converts the AAC file to an MP3 file
ffmpeg -y -i D:\MP3\CoastToCoastAM\coasttocoastam.aac -ar 22050 -ab 32 -map_meta_data D:\MP3\CoastToCoastAM\coasttocoastam.mp3:D:\MP3\Co astToCoastAM\coasttocoastam.aac D:\MP3\CoastToCoastAM\coasttocoastam.mp3
REM
REM Deletes the leftover AAC and FLV files
del D:\MP3\CoastToCoastAM\coasttocoastam.aac
del D:\MP3\CoastToCoastAM\coasttocoastam.flv
REM
REM Builds the current date and time so the MP3 can be renamed with the unique date and time.
FOR /F "TOKENS=1,2*" %%A IN ('DATE/T') DO SET DATE=%%B
REM
REM This changes the "/" to a "-" ---
SET DATE=%DATE:/=%
REM This grabs the time and sets it as a variable ---
FOR /F "TOKENS=*" %%A IN ('TIME/T') DO SET TIME=%%A
REM
REM This removes the ":" from the time stamp variable ---
SET TIME=%TIME::=%
SET TIME=%TIME: =%
REM
REM This sets concatenates both variables ---
set TODAY=%date%-%TIME%
REM
REM Renames the final MP3 file to an easily-recognizable format with the date appended to the filename
ren "D:\MP3\CoastToCoastAM\coasttocoastam.mp3" "coasttocoastam-%TODAY%.mp3"

A text copy of the batch file is also attached for convenience. Again, this method only works in Windows and is not the definitive perfect way to record iheartradio, but it works for what I need and I can schedule it to run automatically. You're all welcome to modify, improve, etc as needed.

Thanks!

LReyomeXX 04-16-2011 10:50 PM

Re: Record Clear Channel radio stations (iheartradio.com)


 
I need something like this for WKSS 95.7 to record The Buzz with Randy Boyer from 12am-4am on Sundays, however it looks like some of those lines at the beginning of the file do not coincide with existing site address portions.

njl433 06-15-2011 12:04 AM

Re: Record Clear Channel radio stations (iheartradio.com)


 
Quote:

Originally Posted by LReyomeXX (Post 27609)
I need something like this for WKSS 95.7 to record The Buzz with Randy Boyer from 12am-4am on Sundays, however it looks like some of those lines at the beginning of the file do not coincide with existing site address portions.

try this link for WKSS:

_http://wkss-fm.akacast.akamaistream.net/7/692/19819/v1/auth.akacast.akamaistream.net/wkss-fm

it looks like most of the Clear Channel stations have been solved because there is a format like this:

_http://www.surfmusic.de/media/kiis-fm.m3u (KIIS-FM-102.7 Los Angeles)
_http://www.surfmusic.de/media/whtz-fm.m3u (WHTZ-FM-100.3 Z100 New York)
_http://www.surfmusic.de/media/kfi-am.m3u (KFI-AM-640 Los Angeles)


put your station call letters in the appropriate place and run thru VLC Player and then go to "Media Information" tab and it will give you the akamai stream...
==========================

for people trying to record Dave Ramsey or Coast to Coast, maybe i'm missing something but just go to StreamingRadioGuide.com or a similar site that will list the many stations that carry and stream those shows and find a station that freely gives out their URL location - for Coast to Coast there's KSFO 560 AM just off the top of my head but many more i'm sure and then use something like Tapin Radio to schedule recording...idk, maybe i'm not seeing what the problem is...

ComputerChris 07-19-2011 10:07 AM

Re: Record Clear Channel radio stations (iheartradio.com)


 
I've been trying to use the akamai stream url to download the stream but it doesn't seem to be working. I'm not sure if I'm using it in the right format or what. Can anyone provide an example of there rtmpdump command?

njl433 07-20-2011 10:56 PM

Re: Record Clear Channel radio stations (iheartradio.com)


 
Quote:

Originally Posted by ComputerChris (Post 31035)
I've been trying to use the akamai stream url to download the stream but it doesn't seem to be working. I'm not sure if I'm using it in the right format or what. Can anyone provide an example of there rtmpdump command?


try Tapin Radio...recording or just listening works easy for me with that little app...i tested an Clear Channel station with the akamai stream and it worked fine...

KSV 07-21-2011 12:46 AM

Re: Record Clear Channel radio stations (iheartradio.com)


 
Code:

rtmpdump.exe -r "rtmp://cp19972.live.edgefcs.net/live/Nyo_NY_WHTZ-FM_OR@s7762?auth=daEdyaRdhaXafbkb6bCbCdhducha.brcCdp-boj8ga-4q-PL0Y7_anqEAou2KBvmCuwr&aifp=1234&CHANNELID=1469&CPROG=_&MARKET=NEWYORK-NY&REQUESTOR=WHTZ-FM&SERVER_NAME=p2.whtz-fm.ccomrcdn.com&SITE_ID=1793&STATION_ID=WHTZ-FM&MNM=2&TYPEOFPLAY=0" --live --verbose -o Test.flv
Code:

RTMPDump v2.4 GIT-2011-07-11 (Compiled by KSV)
(c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
Connecting ...
INFO: Connected...
Starting Live Stream
INFO: Metadata:
INFO:  audiodatarate        64.00
INFO:  audiosamplerate      44100.00
INFO:  audiocodecid          10.00
INFO:  canSeekToEnd          FALSE
INFO:  audiodevice          Orban Optimod 1100 (224001018)
INFO:  metadatacreator      Orban Opticodec-PC PE 3.6.87 (os=Windows NT 5.1 Se
rvice Pack 3)
INFO:  description          Hi-Fi Internet Audio Stream
INFO:  name                  Z100 - WHTZ-FM - New York's Hit Music Station
INFO:  website              http://www.z100.com
INFO:  creationdate          Saturday, July 16, 2011 12:19:04 UTC
INFO:  artist                Britney Spears
INFO:  title                Till The World Ends
INFO:  url                  song_spot="M" MediaBaseId="1700342" itunesTrackId=
"431378501" amgTrackId="T 23123649" amgArtistId="0" TAID="33206" TPID="12747322"
 cartcutId="0101204001" amgArtworkURL="/us/r1000/023/Music/06/6c/f0/mzi.wrpwecrg
.170x170-75.jpg" length="00:03:55" unsID="13
430.256 kB / 52.52 sec


ComputerChris 08-04-2011 11:12 AM

Re: Record Clear Channel radio stations (iheartradio.com)


 
Quote:

Originally Posted by KSV (Post 31094)
Code:

rtmpdump.exe -r "rtmp://cp19972.live.edgefcs.net/live/Nyo_NY_WHTZ-FM_OR@s7762?auth=daEdyaRdhaXafbkb6bCbCdhducha.brcCdp-boj8ga-4q-PL0Y7_anqEAou2KBvmCuwr&aifp=1234&CHANNELID=1469&CPROG=_&MARKET=NEWYORK-NY&REQUESTOR=WHTZ-FM&SERVER_NAME=p2.whtz-fm.ccomrcdn.com&SITE_ID=1793&STATION_ID=WHTZ-FM&MNM=2&TYPEOFPLAY=0" --live --verbose -o Test.flv
Code:

RTMPDump v2.4 GIT-2011-07-11 (Compiled by KSV)
(c) 2010 Andrej Stepanchuk, Howard Chu, The Flvstreamer Team; license: GPL
Connecting ...
INFO: Connected...
Starting Live Stream
INFO: Metadata:
INFO:  audiodatarate        64.00
INFO:  audiosamplerate      44100.00
INFO:  audiocodecid          10.00
INFO:  canSeekToEnd          FALSE
INFO:  audiodevice          Orban Optimod 1100 (224001018)
INFO:  metadatacreator      Orban Opticodec-PC PE 3.6.87 (os=Windows NT 5.1 Se
rvice Pack 3)
INFO:  description          Hi-Fi Internet Audio Stream
INFO:  name                  Z100 - WHTZ-FM - New York's Hit Music Station
INFO:  website              http://www.z100.com
INFO:  creationdate          Saturday, July 16, 2011 12:19:04 UTC
INFO:  artist                Britney Spears
INFO:  title                Till The World Ends
INFO:  url                  song_spot="M" MediaBaseId="1700342" itunesTrackId=
"431378501" amgTrackId="T 23123649" amgArtistId="0" TAID="33206" TPID="12747322"
 cartcutId="0101204001" amgArtworkURL="/us/r1000/023/Music/06/6c/f0/mzi.wrpwecrg
.170x170-75.jpg" length="00:03:55" unsID="13
430.256 kB / 52.52 sec


I'm just curious how you found the rtmp link?

nullacht 08-18-2011 11:48 AM

Re: Record Clear Channel radio stations (iheartradio.com)


 
Quote:

Originally Posted by ComputerChris (Post 31420)
I'm just curious how you found the rtmp link?

Take a look at the XML configuration files:

Code:

http://www.z100.com/mediaplayer/configuration/webservices.xml
Code:

<listenlive>
<![CDATA[http://p2.{{stationName}}.ccomrcdn.com/player/player_dispatcher.html?section=radio&action=listen_live]]>
</listenlive>

{{stationName}} = whtz-fm

Code:

http://p2.whtz-fm.ccomrcdn.com/player/player_dispatcher.html?section=radio&action=listen_live
Code:

PlayerContent>
<ListenLiveInitialize xmlns="">
<StreamInfo xmlns="">
<stream xmlns="" id="1469" primary_location="rtmp://cp19972.live.edgefcs.net/live/Nyo_NY_WHTZ-FM_OR@s7762?auth=daEdwbOaGaLbjd_bhcLdadWbFdUdZc7axdd-botu5G-4q-NMXV2_8ouGDot3JDnmDsxs&aifp=1234&CHANNELID=1469&CPROG=_&MARKET=NEWYORK-NY&REQUESTOR=WHTZ-FM&SERVER_NAME=p2.whtz-fm.ccomrcdn.com&SITE_ID=1793&STATION_ID=WHTZ-FM&MNM=2&TYPEOFPLAY=0"

RTMP LINK:

Code:

rtmp://cp19972.live.edgefcs.net/live/Nyo_NY_WHTZ-FM_OR@s7762?auth=daEdwbOaGaLbjd_bhcLdadWbFdUdZc7axdd-botu5G-4q-NMXV2_8ouGDot3JDnmDsxs&aifp=1234&CHANNELID=1469&CPROG=_&MARKET=NEWYORK-NY&REQUESTOR=WHTZ-FM&SERVER_NAME=p2.whtz-fm.ccomrcdn.com&SITE_ID=1793&STATION_ID=WHTZ-FM&MNM=2&TYPEOFPLAY=0


All times are GMT -6. The time now is 10:28 AM.