Remove/Add Story in Client Repository?

How’s the client repository workflow?

my client settings:
Repository: http://localhost:1880/rundowns
Port: 8250

my http-Endpoint response:


client dialog "Open Rundown from Repository"

my firstRD:

        <label>MAZ AMB</label>

my firstRD in client:

TCP-Message from Client at port 8250:
SUBSCRIBE firstRD localhost:1880

Your client-code mentions:

 * Parse incoming command, e.g:
 * ADD\r\n
 * <StoryId>\r\n
 * <xml><data></data></xml>\r\n\r\n
 * The XML format is standard XML client data
 * and must include a valid story ID.
 * REMOVE\r\n
 * <StoryId>\r\n\r\n
 * Story ID is a unique ID of some sort.

But I can’t get it to work trying:


How is it to remove the Item remotely the right way?

Where is this XML specification coming from? MOS protocoll?

My xml is just a rundown.xml built for testings where I’ve added the storyId. My repository is a Node Red Client which reads the rundown and delivers it at the http endpoint. I could now add a web-interface to edit the rundown in Node Red and communicate with the client at port 8250 by tcp. Up to the subscription everything works fine.

The code advises I’ve got from

If only the mos protocol looked this sane :wink:

1 Like

Not really sure what you are asking.

But i think the idea is that the “remove” part is something you have to implement your self.
on the repository side.
Not really sure how this work as it is a bit of a mystery part off the client :wink:

but i guess when the client send’s a “remove” it actually means unsubscribe?
again not at all sure about this

Although i probably never gona a use it my self i have always been a bit curious how it works.

As I understand the commands:

* ADD\r\n
 * <StoryId>\r\n
 * <xml><data></data></xml>\r\n\r\n

is for adding a story to the loaded rundown in the casparCG-Client

* REMOVE\r\n
 * <StoryId>\r\n\r\n

is for removing a story from the loaded rundown in the casparCG-Client

What works:
The CasparCg-Client loads a rundown from an http endpoint in my remote client.
Then the CasparCG-Client builds up a tcp connection to my remote client for sending remote commands.

What is not working:
When sending the remove command to the CasparCG client nothing happens there.

I guess my command could be wrong or there has to be a special format of the storyId or something else.

did you manage to add a item ?

i must say you shined a new light / gave me a clue on how to use this
interesting :wink:

1 Like

Found it

for REMOVE dont use XML notation


and important the item will not be removed if it has focus in the client !!
soo make 2items and try again :wink:

ow and a other thing the tag for the storyid needs to be lowercase only


it is badly commented in the code


Did I understand that right: One line in the client is a “story”, right? So not a bunch of lines making up a news story, what one would expect from the term “StoryId”.

yes Didi

it’s a bit odd indeed.
there are more things in this part that are a bit odd
i guess there is some heritage there :wink:

but a group is also a item soo put a story into a group can do the trick.

1 Like

I actually don’t care, I juast wanted to understand it. :smile:

Thanks Maurice,

With your instructions I can remove groups or items from the rundown now remotely. It is important that nested items can only be deleted with the whole group. They can’t be deleted with their own storyid. And if the item to delete is currently selected it won’t be deleted immediately. But you get a signation (coloured border) to activate “Repository Insert Changes” after going to the next item.

Where I still have problems is how to add items to the rundown. I think I will need some time with this, also.

To me the right command structure for adding an item is still unclear.
In node.js I tried something like this:

var cmdString = "ADD\r\n4\r\n<type>MOVIE</type><devicename>Local CasparCG</devicename><label>TESTPATTERNS/1080I6000_TEST_A</label><name>TESTPATTERNS/1080I6000_TEST_A</name><channel>1</channel><videolayer>10</videolayer><delay>0</delay><duration>0</duration><allowgpi>false</allowgpi><allowremotetriggering>false</allowremotetriggering><remotetriggerid></remotetriggerid><storyid>4</storyid><transition>CUT</transition><tween>Linear</tween><direction>RIGHT</direction><seek>0</seek><length>0</length><loop>false</loop><freezeonload>false</freezeonload><triggeronnext>false</triggeronnext><autoplay>false</autoplay><color>Transparent</color><timecode>00:00:01:29</timecode>\r\n\r\n"
var buffer = Buffer.from(cmdString, 'utf8');

Sending this buffer didn’t work. But it is the typical xml of a clip item in the rundown.
Perhaps I should change the entities before building my buffer from string.
But it would definetely help to know the right xml structure.

Anybody could help?


well see if i can get this going as a easter project :wink:

Hi @knoepsche

this is working on my side
behind ADD and ‘test’ <= storyid add
and end with

<?xml version="1.0" encoding="UTF-8"?><items><allowremotetriggering>false</allowremotetriggering><item><type>MOVIE</type><storyid>test</storyid><devicename>server1</devicename><label>GO1080P25</label><name>GO1080P25</name><channel>1</channel><videolayer>10</videolayer><delay>0</delay><duration>0</duration><allowgpi>false</allowgpi><allowremotetriggering>false</allowremotetriggering><remotetriggerid></remotetriggerid><storyid></storyid><transition>CUT</transition><transitionDuration>1</transitionDuration><tween>Linear</tween><direction>RIGHT</direction><seek>0</seek><length>0</length><loop>false</loop><freezeonload>true</freezeonload><triggeronnext>false</triggeronnext><autoplay>false</autoplay><color>Transparent</color><timecode></timecode></item></items>

the client can get upset when linefeeds or carriage returns are in the XML data.
when a “wrong” message is send it seems that the rundown isn’t listening any more when new requests are send.


Got it all now working!!!

Thank you for your help!