Answer for Need Help With Creating .NET C# Middleware
Hi Bonnie, Yes it is just a http requests. Sorry, but I also see things from a PHP perspective. So, I cannot give you an example code on how EMS can connect using C#. The EvoStream Web UI and the Web Services just use the Evostream CLI commands to connect to it via an HTTP Requests. So if you click the Connect button on Web UI, it actually sends a url with the following syntax:http://localhost:7777/version
and it will reply back with a JSON formatted data:
{"data":{"banner":"EvoStream Media Server (www.evostream.com) version 1.6.5 build 2959 - Gladiator - (built for Windows-7-x86_64 on 2014-04-24T00:17:45.000)","buildDate":1398298665,"buildNumber":"2959","codeName":"Gladiator","releaseNumber":"1.6.5"},"description":"Version","status":"SUCCESS"}
Just as long as the "status":"SUCCESS" is parsed that means the command was executed successfully on EMS
The format: http://localhost:7777/version has the following parameters
http:// {IP Address where EMS is currently in } : {port of EMS cli - see config.lua CLI aceptors} / {CLI command} ?params= {base64 encoded parameters }
So in C# you just have to create a class that builds the http request in these format and then parse the returning JSON result.
For more information you can just study how the Web UI sends cli commands to EMS.
Hope this helps.
Regards,
Toni
toni
Evostream Staff