title: Sending raw data in request body
body: <p>I'm facing the problem with <strong>sending request body as raw text</strong> without quotes.</p>
  
  <p>The content type of request should be <em>text/uri-list</em>.</p>
  
  <p>Sending it in Postman works correctly but when I try to implement the same operation in java it does not work.</p>
  
  <p>I'm using feign as api client.</p>
  
  <p>Client definition of endpoint looks like this</p>
  
  <pre><code>@RequestLine("PUT /someEndpointOne/{id}/someEndpointTwo")
  @Headers("Content-Type: text/uri-list")
  JSONObject addSomethingToSomething(@Param("id") String id, @RequestBody okhttp3.RequestBody uri); 
  </code></pre>
  
  <p>And I use it in test like this:</p>
  
  <pre><code>somethingClient.addSomethingToSomething("1", okhttp3.RequestBody.create(okhttp3.MediaType.parse("text/uri-list"), "http://localhost/someEndpointTwo/1"))
  </code></pre>
  
  <p>Instead of sending raw data it actually sends empty object:</p>
  
  <blockquote>
    <p>PUT <a href="http://localhost/someEndpointOne/1/someEndpointTwo" rel="nofollow noreferrer">http://localhost/someEndpointOne/1/someEndpointTwo</a> HTTP/1.1</p>
    
    <p>Content-Type: text/uri-list</p>
    
    <p>Content-Length: 2</p>
    
    <p><strong>{}</strong></p>
    
    <p>END HTTP (2-byte body)</p>
  </blockquote>
  
  <p>what causes bad respone.</p>
  
  <p>I would be grateful for help with solving this problem.</p>