title: How to get bundling version token programmatically?
body: <p>We are developing a Main WebApp with angularJS as a Single Page application for a Cordova mobile App.</p>
  
  <p>We have moved part of the static resources into a couple of bundles that will be served from a  different CDN WebApp from another domain.</p>
  
  <p>We are not using the <code>@Scripts.Render</code> <code>@Styles.Render</code> razor helper because bundles are directly referenced from the embedded static index.html inside the mobile app like this (Appended via AngularJS):</p>
  
  <pre><code>&lt;script src="https://service.foo.it/CDN/cdnFooJs"&gt;&lt;/script&gt;
  &lt;script src="https://service.foo.it/CDN/cdnFooCss"&gt;&lt;/script&gt;
  </code></pre>
  
  <p>As we are not using razor, we are not appending any cache token to the src and that's not what we want;
  we need a version token to force the client to download the updated version of the bundle.<br>
  I've read in <a href="https://stackoverflow.com/a/19115304/130929">some previous</a> post that the <code>v</code> token is calculated every time Scripts.Render is used.</p>
  
  <p>Now, the question is:<br>
  is it possible, to access the value of this token programmatically ?</p>
  
  <p>We would like to create a service controller that, given a bundles route, returns the SHA256 token of the bundle.<br>
  Once received,it will be used to build the script tags that will be appended dinamically to the DOM.</p>
  
  <pre><code>&lt;script src="https://service.foo.it/CDN/cdnFooJs?vtoken=asd3...."&gt;&lt;/script&gt;
  &lt;script src="https://service.foo.it/CDN/cdnFooCss?vtoken=dasdasrq..."&gt;&lt;/script&gt;
  </code></pre>
  
  <p><strong>Note</strong>:<br>
  We already know that we can create our token by ourselves (for example using the build number), but it would nice to have something with less effort and more tied to the bundle mechanism.</p>