Interfacing with duet over network?

Is there anyway, or what is the best way of interfacing with Duet board over the network, but not through Web Control?
I play a bit with simple projects around IOT/Home Automation and I have few ideas I would like to implement:

I am using MotionEye network camera server. It has an ability to add buttons on the overlay of a video stream which then executes a custom script on server side. I would like to add buttons to for example pause print, or turn on LED strips.

Create simple RGB led ring project, controlled by esp8266/32 which would show the progress of the print.

Add ability to my Home Assistant server to display some basic stats of current print, plus make some basic controls like pause, cancel the print. Through it I could make my Google Home speakers announce that the print is completed Or create different automation interactions.

I have quickly tested telnet connection using M408, and it seems to be working fine, but I am unsure about using telnet for such tasks. Is there another way? HTTP GET, POST? Some WebSockets maybe?
Mind you, I am unsure what I am talking here about, as I used HTTP GET in maybe two projects, mainly with some online tutorial. But need some recommendations so I can start googling like a crazy

This is exactly the article that prompted my question It says that DWC uses HTTP requests to communicate with the firmware, so I wasn't sure it is not only for internal communication between chips on the board (although I was surprised that HTTP protocol is used but, I know that I do know nothing).
So if I am able to control printer form any device able to send HTTP requests, this is really interesting.

@hedeon Yes, HTTP from anything that can generate it. You can play around by typing the requests into your browser, or using 'curl' from the command line, or 'curl' from simple scripts in any scripting language.

@hedeon Yes, HTTP from anything that can generate it. You can play around by typing the requests into your browser, or using 'curl' from the command line, or 'curl' from simple scripts in any scripting language.

Sending commands seems to be working fine, but when trying to get some info back....
Using rr_gcode?gcode=M408 it does not return any information. Not to curl, but it instead responds in the open browser window....
Same as in this topic.

Any way around that?

Edit: Sorry, got excited, hyperactivity kicked in, and I missed the part about rr_status?type=XXX. This should be enough