title: Empty HTTP POST request or GET request to generate a random value through an HTTP API
body: <p>In my HTTP API, one of the endpoints should return an randomly generated value and that value will be associated with the authenticated caller of the endpoint. Currently, I have the following structure:</p>
  
  <pre><code>GET http://example.com/random-ticket HTTP/1.1
  Authorization: Basic base64-encoded-basic-auth-value
  Accept: application/json
  Host: example.com
  
  HTTP/1.1 200 OK
  Cache-Control: no-cache
  Content-Type: application/json; charset=utf-8
  Date: Thu, 03 Oct 2013 07:25:56 GMT
  Content-Length: 59
  
  {"user-ticket":"Pfa42634e-1a2e-4a7d-84b9-2d5c46a8dd81"}
  </code></pre>
  
  <p>A GET request is issued to retrieve the random value. However, <a href="http://en.wikipedia.org/wiki/Idempotence#Examples">HTTP GET calls should be idempotent</a> and my above implementation is not obeying that rule. On the other hand, <strong>I'm not sure if it's OK to issue HTTP POST requests with an empty message body.</strong> </p>
  
  <p>What is the right way of performing this type of operations by the HTTP book?</p>