DSpace / RestContract

REST Contract for DSpace 7-8
https://wiki.lyrasis.org/display/DSDOC8x/
38 stars 48 forks source link

Add search exposed config endpoint #240

Open J4bbi opened 1 year ago

J4bbi commented 1 year ago

Fixes https://github.com/DSpace/DSpace/issues/9056 as discussed in DevMtgs 14th and 21st September 2023.

This PR adds an endpoint to the configuration endpoint to more efficiently share configuration with the frontend.

Current approach

Add the /api/config/properties/search/exposed endpoint, as per the top communities search endpoint.

Pros API endpoint url is clear.

Cons Endpoint url is not consistent with the single case, /api/config/properties/<:property>.

Alternative approach

I am a little undecided about whether I feel /api/config/properties would be a better solution and just implementing the missing findAll method.

Pros There is consistency in the naming of the endpoints. /api/config/properties/<:property> for a single configuration and /api/config/properties/ for every single one.

Cons It might not be apparent that this endpoint is limited to whitelisted, exposed configuration.

tdonohue commented 1 year ago

@abollini : Adding you as a reviewer of this REST Contract update, since you had recommended this approach in a Dev Mtg.