Generic data contract or specific data contract for an endpoint input on an API?

27 Views Asked by At

Is it better to allow one generic class with properties that might not get used by the client, on a single endpoint in an API or specific types of classes with properties specific to the class on different endpoints ? E.g. A single Claim class data contract on a single endpoint or ApplianceClaim class on one endpoint and then HouseholdClaim class on another endpoint.

What would be best for maintenance?

0

There are 0 best solutions below