I am just getting into REST and ServiceStack and for now my GETs are returning strings which could be XML or Json.
I now need to work on the PUT or POST commands which change my domain model.
For a single resource, I could have a number of commands on my domain model (i.e for a customer resource I could have change name, change address, change billing address, etc). Each change to the domain model will consist of only one of these changes (not all).
With ServiceStack do I create ONE DTO which contains a flag/enumeration to indicate what the change is? This means I have one REST service with a case statement to indicate what I should do on the domain. This also means I have a very large DTO object which contains the data that needs to be posted to change my domain (of which a lot of the properties will be empty).
Or do I create lots of DTOs and REST services, each specific to the change on my model? In this case would I need to add ?Command=changeAddress to the URL? Not sure if this is right.