Make code generation targets extensible

* Replace target enum with a model type and endpoint to list available targets
* Use uniform interface for all code generators and api to invoke them