title: Evaluate requests in the API Gateway
body: <p>Can the API Gateway evaluate requests and route or return errors (not 200 statuses) on specific parameters?</p>
  
  <p>What I want to achieve here is to NOT have millions of requests hitting our backend API since we already know (by evaluating the parameters) that we are not interested in returning responses on all requests but only a few percent. </p>
  
  <p>I gave set up an API Proxy in the API Gateway with a complete set of requests, responses and backend. </p>
  
  <p>The proxy is fully operational and up and running with throttling etc. What I would like is for the API Gateway to evaluate the requests querystring and depending on the values of certain parameters take different actions?</p>
  
  <p>Let's say the complete URL and querystring is:</p>
  
  <p><a href="https://abc123.execute-api.eu-central-1.amazonaws.com/prod?param1=a&amp;param2=b&amp;param3=c" rel="nofollow noreferrer">https://abc123.execute-api.eu-central-1.amazonaws.com/prod?param1=a&amp;param2=b&amp;param3=c</a></p>
  
  <p>Now depending on the values of param1, param2 and param3 I might want to:</p>
  
  <ul>
  <li>Forward the request to my actual API and return a response back to the client. </li>
  <li>Drop the request OR return an empty (or templated) response with a specific HTTP-status (404, 503 etc - exact value not that important).</li>
  </ul>
  
  <p>Is this achievable with the API Gateway or do I need to actually set up a host with a reverse proxy and let that handle this logic?</p>