WordPress REST API - Get media of specific type only
<p>I am using WP REST API v1.2.5 (as v2 doesn't seem to work on the website I'm working on) and I want to retrieve all pdf objects from Media without getting all the other images, videos etc. How could I do this (without adding a custom endpoint if possible).</p>

<p>to get all media I use:</p>

<pre><code>/wp-json/media
</code></pre>

<p>I can't find a filter that would only return the pdfs on my site though. Any help would be appreciated. Thanks!</p>