codemeta: Context DOI redirect is failing in JSON-LD playground, JSON-LD libraries
When the JSON-LD playground and other JSON-LD libraries (ruby) see the remote context in one of our CodeMeta documents, i.e.:
"@context":"https://doi.org/10.5063/SCHEMA/CODEMETA-1.0",
They send a HTTP GET request with “Accept: application/ld+json” to read the remote context. This returns the Datacite ‘metadata’ page
http://data.datacite.org/10.5063%2FSCHEMA%2FCODEMETA-1.0
and not the DOI resolution of
https://raw.githubusercontent.com/codemeta/codemeta/1.0/codemeta.jsonld
The DOI entry is typed as ‘text/json’ at http://ezid.cdlib.org/id/doi:10.5063/SCHEMA/CODEMETA-1.0
I’m wondering if adding the type application/ld+json to the DOI entry will resolve this problem.
For more details, see https://github.com/json-ld/json-ld.org/issues/447
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 54 (20 by maintainers)
We launched our rewritten DataCte DOI content negotiation service yesterday, and the following finally works as expected:
This does not require registration of the media type with EZID, but works with it. You could for example have the DOI by default redirect to https://github.com/codemeta/codemeta, and for content type
application/ld+jsonto the json-ld file. Which would be best practice, as you don’t want to resolve DOIs directly to content by default.You can also do these requests to have the DataCite metadata returned as codemeta or schema.org/JSON-LD: