Skosmos icon indicating copy to clipboard operation
Skosmos copied to clipboard

Supported MIME-types - no MARCXML support on concept level

Open joelit opened this issue 1 month ago • 0 comments

URL address of the page where you encountered the problem

http://localhost/Skosmos/rest/v1/yso/data?format=application%2Fmarcxml%2Bxml&uri=http%3A%2F%2Fwww.yso.fi%2Fonto%2Fyso%2Fp8627&lang=fi (You can substitute http://localhost/Skosmos/ with https://test.dev.finto.fi/ )

Description of the problem

We support certain MIME-types, and otherwise an error message is displayed, e.g. http://localhost/Skosmos/rest/v1/yso/data?format=foo&uri=http%3A%2F%2Fwww.yso.fi%2Fonto%2Fyso%2Fp8627&lang=fi to see the error message for an unsopported MIME-type.

If you use parameter format=application%2Fmarcxml%2Bxml on a concept level, the system does not return MARCXML data, as it's not actually supported on a concept level. Instead, RDF/XML is returned.

Behaviour similar to the format=foo case is expected in the concept-level MARCXML (Error message and error code 406 should be given instead of data). The support for MARCXML should only be offered on the vocabulaty level.

joelit avatar Nov 27 '25 11:11 joelit