Class AuthorityResource
java.lang.Object
io.goobi.viewer.api.rest.v1.authorities.AuthorityResource
REST resource for resolving authority records and retrieving metadata from linked data sources.
- Author:
- Florian Alpers
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetIdentity(String inUrl, String template, String lang) Resolves an authority (normdata) record identified by the given URL and returns its metadata as JSON.
-
Constructor Details
-
AuthorityResource
public AuthorityResource()
-
-
Method Details
-
getIdentity
@GET @Path("/resolver") @Produces("application/json") public String getIdentity(@QueryParam("id") String inUrl, @QueryParam("template") String template, @QueryParam("lang") String lang) throws de.unigoettingen.sub.commons.contentlib.exceptions.ContentNotFoundException, PresentationException Resolves an authority (normdata) record identified by the given URL and returns its metadata as JSON.The url may append a second,
$-separated segment. Whenever the first url points to viaf.org, the authority record resolved from it is added as a cross-reference entry; a second segment additionally contributes the VIAF cluster url. Depending ontemplate, either every available field is returned (no template,_DEFAULT,_ALL, or an unconfigured template name), or only the fields configured for that template, always excluding the raw GND URI field from the templated output.- Parameters:
inUrl- identifier url of the resourcetemplate- metadata template to uselang- language to use for metadata fields- Returns:
- the resolved normdata as a JSON array string
- Throws:
de.unigoettingen.sub.commons.contentlib.exceptions.ContentNotFoundException- if no authority record is found for the given urlPresentationException- if a class-linkage error (NoSuchMethodError) prevents building the JSON response
-