Retrieving a collection of IDs instead of the full representation of a resource in REST
<p>I'm designing a REST API for the first time, so I have what I consider a quite basic question about its design.</p>

<p>I would like the files collection to return an ID (or a link) of all available file resources instead of retrieving the full representation because it would be too much data.</p>

<pre><code>GET /files        # return the full representation of a collection of resources
GET /files/{id}   # return the full representation of a single resource 
</code></pre>

<p>I don't know if it is better to split it in two different resources:</p>

<pre><code>GET /fileids      # return only IDs
GET /files/{id}   # return the full representation of a single resource
</code></pre>

<p>What would be your approach?</p>