title: Passing optional data to REST API
body: <p>We have a Desktop Client and a REST API.  For several POST REST calls, we want to pass a correlation GUID from the Client to the API that is used to correlate log entries related to the same user interaction.</p>
  
  <p>This parameter is optional and must be backwards compatible, not failing if it is omitted.  What options are there to pass this in while keeping code clean?</p>
  
  <p>I'm concerned that if I put it:</p>
  
  <ul>
  <li>In the header, it means receiving a HttpRequestMessage and manually extracting it, the URL parameters and the body content in each API call.</li>
  <li>In the URL, it may not hit the correct route if the parameter is missing (eg. backward compatibility.)</li>
  <li>In the body, it pollutes the model as the parameter is related to the system rather than the data.</li>
  </ul>
  
  <p>For example, an existing method is:</p>
  
  <pre><code>[HttpPost]
  public HttpResponseMessage SaveData([FromBody]DataModel model)
  {
      ...
  }
  </code></pre>
  
  <p>I feel like I've missed something.  Where is the best place for it?</p>