I am using RedirectToAction in my ASP.Net WebAPI application and I tried the following one.
return RedirectToAction("AuthenticateUser", "AuthenticationServiceWebApi", new RouteValueDictionary
                                                                    {
                                                                        {"userName", model.UserName},
                                                                        {"password", model.Password}
                                                                    });
This generates the redirection as below.
127.0.0.1:81/authenticationservicewebapi/authenticateuser/admin/admin@123
But, since I am using WebAPI, I need to be the URL like below.
127.0.0.1:81/api/authenticationservicewebapi/authenticateuser/admin/admin@123
How do I do this?
 
                        
I'm not sure how your routing, Web API action signature look like so I will try to guess. A few things don't really add up here (why would you pass the password in the url?)
but...
Given your url structure I'd guess your routing is something like:
Then given that, I guess your authenticateuser must be something like:
If so, then to redirect to this from an MVC controller you need: