Today, I learned that the POST /metadata/json:submit endpoint could be used to update documents (by their id), not just insert documents. Given that the endpoint lacks documentation, I didn't learn this until I read this comment and then tried it out locally (I was able to update an existing document).
To do: