title: Retrofit: 500 internal server error
body: <p>I have 500 internal server error, every time when i try to send POST request via Retrofit. When i sending GET request, it sending correctly. I'm sure that with serverside everyting is ok. What's wrong with my code ?</p>
  
  <pre><code>    String ENDPOINT = "http://52.88.40.210";
      //model for request
          FriendModel ff = new FriendModel();
          ff.setFriendNumber("380935275259");
          ff.setId(516);
          ff.setNumber("380936831127");
  
          RestAdapter adapter = new RestAdapter.Builder()
                  .setEndpoint(ENDPOINT)
                  .build();
          WayfAPI api = adapter.create(WayfAPI.class);
          api.getFriendsLocation(ff, new Callback&lt;List&lt;FriendLocationModel&gt;&gt;() {
              @Override
              public void success(List&lt;FriendLocationModel&gt; friendLocationModels, Response response) {
                  for (FriendLocationModel ff : friendLocationModels) {
                      Log.d("myLogs", "===========Successful==========");
                      Log.d("myLogs", "Id: " + ff.getId());
                      Log.d("myLogs", "Number: " + ff.getNumber());
                      Log.d("myLogs", "GeoLocation: : " + ff.getGeoLocation());
                  }
              }
  
              @Override
              public void failure(RetrofitError error) {
                  Log.d("myLogs", "-------ERROR-------");
                  Log.d("myLogs", Log.getStackTraceString(error));
              }
          });
      }
  </code></pre>
  
  <p>Declaration of request:</p>
  
  <pre><code>@Headers({
          "Accept: application/json",
          "Content-type: application/json"
  })
  @POST("/api/geo/getLoc")
  public void getFriendsLocation(@Body FriendModel friendModel, Callback&lt;List&lt;FriendLocationModel&gt;&gt; response);
  </code></pre>
  
  <p>Exampe of request and response from Postman: 
  <a href="https://i.stack.imgur.com/uIzm4.png" rel="noreferrer"><img src="https://i.stack.imgur.com/uIzm4.png" alt="enter image description here"></a></p>