Add update endpoint to API

These changes are completely untested and should not be merged yet. The pull request is just FYI.
I'd add some logic in here to make sure we're not already downloading the requested version.  That way if some script accidentally does a `POST` multiple times it won't have any impact either on the agent or the master bandwidth/processing wise.