none
error "400 Bad Request" (test with Fiddler) RRS feed

  • Question

  • Hi! 

    I have a problem: there is a WCF service:

    [ServiceContract]
        public interface IService1
        {

            [OperationContract]
            [WebInvoke(UriTemplate = "comment", Method = "POST",
      RequestFormat = WebMessageFormat.Xml, ResponseFormat = WebMessageFormat.Xml)]
             Comment Comment(Comment comment);
         }

        [DataContract(Namespace = "")]
        public class Comment
        {
            [DataMember]
            public string Body { get; set; }

        }

     public Comment Comment(Comment comment)
            {
                return comment;
            }

    when I tested with the WCF Test client, then it works well, but if I test it with the Fiddler, I get this response:

    "400 Bad Request".

    What's the problem?

    Thursday, May 29, 2014 1:34 PM

Answers