title: why use Retrofit when we have OkHttp
body: <p>with OkHttp we can make HTTP request then get response from server</p>
  
  <pre><code>OkHttpClient client = new OkHttpClient();
  Request request = new Request.Builder()
    .url(url)
    .build();
  Response response = client.newCall(request).execute();
  </code></pre>
  
  <p>then with Gson lib convert response to object we need.</p>
  
  <p>this is from Square/OkHttp doc:</p>
  
  <blockquote>
    <p>Its request/response API is designed with fluent builders and
    immutability. It supports both synchronous blocking calls and async
    calls with callbacks</p>
  </blockquote>
  
  <p>I read from <a href="https://stackoverflow.com/questions/16902716/comparison-of-android-networking-libraries-okhttp-retrofit-volley" title="stackOverFlow">stackOverFlow</a></p>
  
  <blockquote>
    <p>Retrofit uses OkHTTP automatically if available</p>
  </blockquote>
  
  <p>.</p>
  
  <p>So my question is what is exactly Retrofit for?</p>
  
  <p>what Retrofit can do that OkHttp can not?!</p>
  
  <p>I think OkHttp and Gson solve request API problem,
  so what problem Retrofit solve for us?</p>