Witam,
Dostałem projekt c# do testowania WCF, jedna z metod wymaga parametru json.
[WebInvoke(
Method = "POST",
ResponseFormat = WebMessageFormat.Json,
RequestFormat = WebMessageFormat.Json,
UriTemplate = "/getRa")]
public EditRacGroup GetRa(GetRa getRaRequest)
Próbuję Embarcadero RestDebuger i podaje json jako parametr
{"getRaRequest":{
"name": "12345",
"tr": "1232222"
}}
Ustawiłem breakpoint w kodzie
EditRacGroup
Metoda startuje i kursor zatrzymuje się na linii kodu, czyli doszło do jej wywołania - sukces...
Próbuje wewnątrz metody ustalić jaki do niej trafia parametr - co zostało z json?
(GetRa getRaRequest)
Niestety parametr jest getRaRequest is null.
Co się dzieje źle?
Dziękować za pomoc...
Piotr
> System.ServiceModel.Web.WebFaultException`1
HResult=0x80131501
Message=Bad Request
Source=<Cannot evaluate the exception source>
StackTrace:
<Cannot evaluate the exception stack trace>