There's no way for Signal to prevent any piece of code that can make a TCP connection and speak its protocol from using the service.
There are libraries for interacting with Signal services (one from Signal themselves), here is a CLI tool that uses a patched official library: <https://github.com/AsamK/signal-cli>