I don't think I am being understood. I am not looking to create a terminal nor use a terminal to run shell scripts. I am looking to create apps that have no UI and can be run directly from a shell command/script, and outputs text to stdout and stderr. They are commands that you run within a terminal. If you are an old windows user, think commands run at the command prompt. For unix, think bash commands/scripts (its almost the same in android).
For example, if you open a terminal on an android device, there are thousands of commands you can run.
Some examples:
Will return the SELinux enforcing state
Will return a summary of your devices memory
cmd package list packages -3;
Will return a list of 3rd party packages installed on the device
Will output your devices battery stats and history.
People often confuse these with being a part of ADB, but in most cases they are simply shelling out and running the command on the device from a pc.