Fedex XML Non-Soap Webservice 405 Error RRS feed

  • Question

  • User409317770 posted

    I am getting the following error message "The remote server returned an error: (405) Method Not Allowed." when I send the below request below to Fedex. Does anyone one know what I am doing wrong? Thanks.

     Dim xmlRequest = <ns:TrackRequest xmlns:ns="http://fedex.com/ws/track/v2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://fedex.com/ws/track/v3 TrackService_v2.xsd ">
                                         <ns:Key><%= key %></ns:Key>
                                         <ns:Password><%= password %></ns:Password>
                                     <ns:AccountNumber><%= accountNumber %></ns:AccountNumber>
                                     <ns:MeterNumber><%= meterNumber %></ns:MeterNumber>
                                     <ns:CustomerTransactionId>User Customizable Field</ns:CustomerTransactionId>
                                     <ns:Value><%= trackingNumber %></ns:Value>
            Dim uri As New UriBuilder()
            With uri
                .Host = "gatewaybeta.fedex.com"
                .Port = 443
                .Scheme = "https"
            End With
            Dim request As New XmlSend(uri.ToString())
            Dim xml As String = xmlRequest.ToString()
            With request.Request
                .Referer = "My Company"
                .Accept = "image/gif, image/jpeg, image/pjpeg, text/plain, text/html, */*"
                .ContentType = "image/gif"
                .ContentLength = xml.Length
                .Timeout = ConstantsCommon.XML_QUERY_TIMEOUT
                .KeepAlive = True
            End With
                Dim xmlResponse As XDocument = request.SendToXml(xml)
            Catch ex As Exception
                Me._xmlFail = True
            End Try

    Monday, February 15, 2010 7:37 PM

All replies

  • User-1659704165 posted



    have seen the abov elink

    Monday, February 15, 2010 11:55 PM