How do we determine whether we are using Web API 1 or Web API 2?

Shaun Luttin picture Shaun Luttin · May 6, 2014 · Viewed 21.3k times · Source

Introduce the problem

I would like to know whether we are using Web API 1 or 2. My own packages.config indicates version 5.0.0. Is that Web API 1 or 2?

Search, and research

I have tried Googling the following:

"web api 1" "web api 2"

and

ASP.NET Web API release history

and

ASP.NET Web API nuget

The best references seem to be these two nuget pages:

Is that right? How would I know for sure?

Answer

John picture John · Sep 18, 2014

I think what you found seems correct. I had the same question then I had a look under my installed packages when you go "Manage Nuget packages". There was an item installed with the name "Microsoft ASP.NET WEB API 2.2". So I was able to determine my own version from there.