Old 26th June 2012, 13:35   #1
methos707
Junior Member
 
Join Date: May 2012
Posts: 13
Trying to Add Relay event through the ajax api

Hi,

I am trying to use the sc_trans AJAX api "addevent" operation to add a relay event ..

here are the parameters I am passing (from an html form post):

PHP Code:
<INPUT type="hidden" name="type" value="relay">
<
INPUT type="hidden" name="url" value="**obfuscated for this forum post**">
<
INPUT type="hidden" name="starttime" value="13:29:00">
<
INPUT type="hidden" name="duration" value="0:02:00">
<
INPUT type="hidden" name="priority" value="20">
<
INPUT type="hidden" name="op" value="addevent">
<
INPUT type="hidden" name="seq" value="95"
And I am getting this response ...

PHP Code:
<response seq="95">
  <
error>Event type relay is not supported.</error>
</
response
According to the api documentation, relay events are supported here, so am I doing something wrong?

Thanks
Methos
methos707 is offline   Reply With Quote
Old 27th June 2012, 00:58   #2
methos707
Junior Member
 
Join Date: May 2012
Posts: 13
hmmm ... it seems relay events are not supported at all (or I am doing something wrong) ... having had no success adding a relay event through the api, I put one directly into the calendar.xml, per the documentation, but got the following error in the log ...

2012-06-27 00:43:37 E msg:[calendarMgr] Bad entry type (relay) for entry number 2

Are relay events no longer supported in sc_trans? or did I miss something?

Thanks
Methos
methos707 is offline   Reply With Quote
Old 27th June 2012, 01:14   #3
DrO
 
Join Date: Sep 2003
Posts: 27,873
relay events are supported in sc_trans, i just haven't had a chance to re-check what is or isn't going on when using the api interface when it comes to those events. will likely be a few days to early next week before i can properly get around to looking into it.

Quote:
Originally Posted by methos707 View Post
2012-06-27 00:43:37 E msg:[calendarMgr] Bad entry type (relay) for entry number 2
that happens if there is an issue with the event and implies that there is an issue with the calendar.xml (even though it's showing the correct event name).

-daz
DrO is offline   Reply With Quote
Old 27th June 2012, 01:33   #4
methos707
Junior Member
 
Join Date: May 2012
Posts: 13
thanks for the reply daz, I'll keep playing with it to try and get it working and report back if i get anywhere - for reference, here is my calendar.xml which gives the above error on starting sc_tans:

PHP Code:
<?xml version="1.0" encoding="UTF-8" ?>
<eventlist>
<event type="dj">
<dj archive="0">DJT</dj>
<calendar  starttime="00:00:00" />
</event>
<event type="dj">
<dj archive="0">DJD</dj>
<calendar  starttime="00:00:00" />
</event>
<event type="relay">
<relay url="http://XXXXXX.com:8312" priority="30"/>
<calendar  starttime="00:46:00" duration="00:10:00" />
</event>
</eventlist>
I used that starttime and duration for testing, since i was starting it a few minutes before 00:46

Thanks
Methos
methos707 is offline   Reply With Quote
Old 27th June 2012, 02:16   #5
methos707
Junior Member
 
Join Date: May 2012
Posts: 13
daz ... apologies, was totally my own fault .... I discovered I was running a really old build of sc_trans. I have just dl'd and run the latest build and I can add relay events in the calendar.xml, and through the api ... all is good, sorry for wasting your time .....

Methos
methos707 is offline   Reply With Quote
Old 27th June 2012, 10:59   #6
DrO
 
Join Date: Sep 2003
Posts: 27,873
rightio, that would make sense.

-daz
DrO is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Shoutcast > Shoutcast Technical Support

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump