Key / Description / Example
?select_attr_of_collection=attr1,attr2,… / Comma (“,”) separated list for the attribute names of the resources in the collection to return. See Section 7.3.1, “Selecting Attributes on a GET”. / If /paas/assembly/8675309/compsis the components resource URI of assembly/8675309, then GET /paas/assembly/8675309/comps?select_attr_of_collection =name%2Cdescription%2Ctags would access only “name”, “description”, “tags” attributes of the components of assembly/8675309.

7.3.1 Selecting Attributes on a GET

To retrieve a subset of the attributes in a resource, the Consumer MAY use the ‘select_attr’ query parameter in conjunction with the HTTP GET method. [PR-08] A Provider SHALL return only those attributes of the queried resource whose name occurs in the list specified by the value of ‘select_attr’. [PR-47] If an attribute listed in the value of the ‘select_attr’ query parameter is not part of the resource, a “400 Bad Request” status code SHALL be returned. [PR-09] The “select_attr” query parameter MAY appear more than once (separated by an “&”). [PR-10]

To retrieve a subset of the attributes of the resources in a collection, the Consumer MAY use the ‘select_attr_of_collection’ query parameter in conjunction with the HTTP GET method. [PR-08] A Provider SHALL return only those attributes of the resources in the collection whose name occurs in the list specified by the value of ‘select_attr_of_collection’. [PR-XX] If an attribute listed in the value of the ‘select_att_of_collection’ query parameter is not part of the resource, the provider shall return null for that attribute [PR-XX] The “select_attr_of_collection” query parameter MAY appear more than once (separated by an “&”). [PR-XX]

7.3.X Uniqueness of resources in a collection

In the case where no select_attr_of_collection parameter is specified, all elements of the collection are unique by virtue of them having unique URIs. However when the select_attr_of_collection query parameter is applied to the attributes of these resources, the resulting collection may contain duplicate attribute sets. The provider shall remove all duplicates from the collection and return a unique collection of sets of attributes [PR-XX]. I.e.If /paas/assembly/8675309/compsis the components resource URI of assembly/8675309 then GET /paas/assembly/8675309/comps?select_attr_of_collection =description will return a collection resource whose links contain the unique descriptions of the components of assembly/8675309 (including null if any component does not have a description).

Pagination or sorting are present as additional parameters in the same request, see section <appropriate-section-currently-7.3.2>for order of operations.is then applied to this set of unique names.

Name: select_collection_attr (s/select_attr_of_collection/select_collection_attr/)

address what happens when select_attr and select_collection_attr are present multiple times in the URL.

If targeted at a URL that is not a collection resource, 400 Bad Request

Don’t return nulls when attribute is not present

Add in section 6.5 that you if you sort on an attribute and you use select_collection_attr, then that attribute must be in the list of selected collection attributes.