C# connect to worldserver console and send commands

Hello guys, I’m trying to create a GUI app for trinitycore written in C# with some features helpful for server administrators.

I just don’t know how to connect to the worldserver console and execute a command / get response if successfull?

I heard there is a telnet option to connect to it ra/soap.

Can anybody help me with the code? Thank you