This repository has been archived by the owner on Nov 25, 2019. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Issue 254: HttpClient.PostAsJsonAsync and HttpClient.PostAsXmlAsync s…
…hould set matching Accept header and have overload that takes System.Uri. This commit adds missing overloads taking a System.Uri as HTTP request URI in addition to a string representation. After further consideration we choose not to add accept header fields to match the request type so that PostAsJsonAsync sends an accept header of 'application/json' and PostAsXmlAsync sends an accept header of 'application/xml'. The reason is that some servers may react differently to an accept header, for example by returning a 406 status code instead. So rather than adding it implicitly, users can add it themselves if they so desire.
- Loading branch information