title: REST API design for utility calculations
body: <p>I'm trying to design an API that balances RESTful recommended practices with overall usability  and one thing that I'm struggling with is the design of utility methods for calculating things.</p>
  
  <p>Specifically, for homebrewing there are many things the brewer wants to calculate during the process: color, bitterness, ABV, etc.  I guess it's simple enough to have a <code>/calculators</code> endpoint with the resulting <code>GET</code> returning available calculators:</p>
  
  <ul>
  <li>/calculators/1</li>
  <li>/calculators/2</li>
  </ul>
  
  <p>though in this case it's certainly more user-friendly to return:</p>
  
  <ul>
  <li>/calculators/abv</li>
  <li>/calculators/ibu</li>
  </ul>
  
  <p>What should the <code>GET</code> on a calculator resource look like?  Should the values that make up the calculation be URL params (<code>/calculators/abv?og=1.050&amp;fg=1.021</code>)?  What's the appropriate response/response code when the necessary params aren't provided or an invalid combination of params is provided?  Is there a more sensible design other than the resource per calculation type that I specify above?</p>