Sinatra helpers for building JSON APIs.