Quantcast
Channel: Web API
Viewing all articles
Browse latest Browse all 4850

Basic POST doesn't work.

$
0
0

Hello.

I have started using the ASP.NET MVC API, and for some reason i cant get it to work.

I am trying to post an http.post to my default api/values (see code below), and for some reason it doesn't work when i post to it, it wont do anything.

        // POST api/values
        public void Post([FromBody]string value)
        {
            var s = value;
        }

and added a breakpoint where s = value;

still i cant see it.

I am trying to post a json if it makes more sense now.

Thanks for reading.


Viewing all articles
Browse latest Browse all 4850

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>