Online APIs for 3D printing services
There are a few methods to simplify your workflow.  Two solutions are outlined below and both feature a documented API you can use to further customize your workflow.

OctoPrint was mentioned by other users.  OctoPrint will allow you to configure your printer, print profiles and upload STLs for printing from a web interface.  You can configure profiles, slicers and slicer profiles for OctoPrint to use to complete your workflow.

Astroprint offers cloud slicing services in addition to features allowing you to manage printers and print profiles.