title: Consuming ASP.NET Web API from ASP.NET MVC and mobile devices
body: <p>After alot of in vain search on this topic, I need to ask the question here.</p>
  
  <p>I am planning on creating an online multiplayer cards game. Initially, the game is only going to played via Android phones (as clients). But later, I would also like to make it accessible to iPhone users as well as make it web-browser based.</p>
  
  <p>All these three types of clients (Android, iPhone and web browser) should be able to connect to the same server (where game engine is implemented) and therefore use the same logic and game-rules - their client-side appearance is whats going to be different.</p>
  
  <p>I have programmed in ASP.NET and that is what I am planning to use here as the server-side infrastructure. Specifically, I have looked the ASP.NET Web API and it looks great: my three types of clients would <em>simply</em> need to get game data from the Web API as json and render it. </p>
  
  <p>Here is my question:
  Its clear to me how iPhone and Android will get and use that json-formatted game data from the Web API. But I am very unclear on how the website version (which I think is going to be ASP.NET MVC) would consume the Web API? Is it wise to simply make http requests to Web API from MVC - if yes, would it not make it slow?</p>
  
  <p>Essentially, I want to write the game logic once, expose it through Web APi to many different kinds of clients that consume it. This architecture, that I have in mind, is beautifully depicted in diagram #3 <a href="http://odetocode.com/blogs/scott/archive/2013/07/01/on-the-coexistence-of-asp-net-mvc-and-webapi.aspx" rel="nofollow">here</a> - cant post images here.</p>
  
  <p>So <em>Others</em> on the diagram there, represent my iPhone and Android users.</p>
  
  <p>Any pointers in other directions are also welcome. :)
  Thank you</p>