title: Laravel TCP Server to accept incoming data
body: <p>So basically up until now I've always used Laravel with API routes - i.e. I accept incoming data through the API and direct it to controller and service to process it and save it in my DB hosted on GoDaddy.</p>
  
  <p>Now, I've got a device which makes use of a TCP connection in order to send data and so I'd need to host a TCP Server from my Laravel project. Is this possible? I've found this <a href="https://www.techalyst.com/posts/php-and-laravel-receiving-gps-tracker-data-to-specific-tcpip-port" rel="nofollow noreferrer">guide</a> but I wouldn't want to run the script each time but rather my Laravel framework automatically sets up the TCP server and accept the incoming data which I can then process etc. Just like an API route is 'automated' i.e. directed to a controller, I'd like something similar for a TCP connection (if it is possible).</p>
  
  <p>Thanks</p>