Click here to Skip to main content
15,903,030 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have this web api controller:

[Authorize(Users = "ABC")]
public IHttpActionResult GetCCUserPermission(string ccUserGuid, string ccInstance)
{
//codes
}

How can I call this API controller from Postman?

What I have tried:

I am able to call this if I don't write Authorize filter.
Posted
Comments
Afzaal Ahmad Zeeshan 30-May-18 17:47pm    
You need to pass the credentials for the users, so that the authorize filter can work. In postman you can add a header for the authentication or pass the credentials.

This depends on the design of the API, perhaps API can accept the information with which it can authorize the user to make a request.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900