asp.net web api - Web Api : Sending XML request through POSTMAN always gives null object -


i using postman extension , trying send xml post request web api.

sample model:

[datacontract(namespace = "")] public class employee {          [datamember]         [range(10000, 99999)]         public int id { get; set; }          [datamember]         public string firstname { get; set; }          [datamember]         [required]         [maxlength(20)]         public string lastname { get; set; } } 

postman request: enter image description here

while executing request getting null employee object in post method of controller.

if send json request works fine.

i tried providing namespace in datacontract attribute didn't work.


Comments

Popular posts from this blog

python Tkinter Capturing keyboard events save as one single string -

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

javascript - Z-index in d3.js -