Wanted to canvass some opinion on how you guys go about designing the contracts of your services and in particular how you tradeoff the advantages of very specific constraints in your contract against the problems this could cause in the future if/when things change.
The topic interests me becaus we're doing an integration thats going to use a standard schema to communicate with a 3rd party, however most of the integration is going to be done using our own custom schema which has a lot of our own domain terminology/structure build into it. So I'm wondering whether you would build constraints regarding things like country/address/telephone codes into the schema itself or would you just allow anything that passes a simple regular expression through and just le the client or a run-time check in the integration platform catch any violations (e.g. passing in "GPB" instead of "GBP")? In some cases the decision is easy, if the data is very dynamic then you would definitely avoid putting it into the contract. However I'm interested in how you handle things that *might* change, even if changes will happen very seldom if at all.
