Guest User

Untitled

a guest
Dec 4th, 2018
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.78 KB | None | 0 0
  1. [RoutePrefix("References")]
  2. public class ReferencesController : ApiController
  3. {
  4. [HttpPost]
  5. [Route("MyTypes")]
  6. public List<MyTypeModel> MyTypes([FromBody]string value) // value == null
  7. { /// }
  8. }
  9.  
  10. POST /References/MyTypes/ HTTP/1.1
  11. Host: localhost:59640
  12. Content-Type: application/x-www-form-urlencoded
  13. cache-control: no-cache
  14. Postman-Token: 9c44b544-53dc-43a8-8e2a-1b63fe4bf591
  15. value=testvalueundefined=undefined
  16.  
  17. [HttpPost]
  18. [Route("MyTypes")]
  19. public List<MyTypeModel> MyTypes([FromBody]MyClass value) // value != null
  20. { /// }
  21.  
  22. POST /References/MyTypes/ HTTP/1.1
  23. Host: localhost:59640
  24. Content-Type: application/x-www-form-urlencoded
  25. cache-control: no-cache
  26. Postman-Token: 29b606d4-8d42-4790-a03b-e4e170b91a9b
  27. Host=127.0.0.1UserName=wfPassword=123456undefined=undefined
Add Comment
Please, Sign In to add comment