title: Can I invalidate an arbitrary cache entry with Varnish?
body: <p>I am investigating if I can use Varnish to speed up a REST API.</p>
  
  <p>Basically, I want to cache the <code>GET</code> requests for a potentially long time. But when a <code>PUT</code>/<code>POST</code>/<code>DELETE</code> request is received, I want to parse the URL and, based on the information I find, I want to purge a cache entry.</p>
  
  <p>For example:</p>
  
  <pre><code>GET /documents/:docType // return document list for specified docType
  DELETE /document/:docType/:docId // delete a document
  
  GET /documents/A0  &lt;-- cached
  GET /documents/A1  &lt;-- cached
  DELETE /document/A0/333  &lt;-- first entry is purged
  </code></pre>
  
  <p>Can I achieve this with VCL?</p>