I am currently looking to design some WCF services and wanted to get the community's opinion on the best way to handle operation / data contracts.
I have 2 basic operation contracts, the first creates a quote and the second adds an item to a quote (and calculates totals behind the scene).
The first takes in customer information and store information and returns a quote.
The second takes in a quote and an item object, calculates totals and returns a quote with the item.
My question is about how to design the data contracts in this scenario?
For the CreateQuote, should a quote object be passed in with a customer property and a store property set or should there be some kind of QuoteRequest object which contains a customer & store object but with no quote object passed in?
For the AddQuoteItem, should a QuoteItem object be passed in with required properties set including a Quote object or should there be a QuoteItemRequest object that has a Quote object and an item object (with no relation) and then a recalculated Quote with a QuoteItem object is returned?
In other words should they look something like this?
Quote CreateQuote(Quote quote);
Quote AddQuoteItem(QuoteItem quoteItem);
Or should they look something like this?
Quote CreateQuote(QuoteRequest quoteRequest);
Quote AddQuoteItem(QuoteItemRequest quoteItemRequest);