I have the following routes set up in a user controller:
[EnableCors("*", "*", "*")] [RoutePrefix("api/users")] [Authorize] public class UserController : ApiController { [Route("")] public IHttpActionResult Get() { } [HttpGet] [Route("{id:int}")] public IHttpActionResult Get(int id) } [HttpPost] [Route("validateUser")] public IHttpActionResult ValidateUser() { } [HttpPost] [Route("verify/{identityId}/{emailAddress}")] public void VerifyUserEmailAddress(string identityId, string emailAddress) { } } The first three routes work just fine. But the fourth fails with a 404. I'm using fiddler to make the call:
http://localhost:39897/api/users/verify/asldkfj/[email protected] (post is selected)
Does post require data sent in the body? Can anyone see what I'm doing wrong and why the verify route is not being found?
.comis the issue. if you add a trailing slash/it should work. iehttp://localhost:39897/api/users/verify/asldkfj/[email protected]/