Hello all,
does anyone have experience with querying OpenAIRE using PIDs either using the SPARQL or HTTP API?
For example using a Grid-ID to get an Organization and its linked projects?
Or using an ORCID to get Publications and their related projects or funding?
Would appreciate some help on how to query the knowledge research graph for these connections!
Iâve used the search API to search for datasets by ORCIDs. I havenât used it to link to projects or funding, but the data was in the resulting JSON under oaf:result[ârelsâ]. You can find my code for this here:
This code takes a relatively long time to run depending on the size of the ORCID list. It sends out one request per ORCID and there is a default sleep time between requests of 2 seconds in order to respect rate limiting.
As my use case did not involve large results sets, I didnât bother implementing paging of the results. I just set the number of results per page relatively high. If you expect a large number of results per page, I recommend lowering the default and implementing paging.
Also bear in mind that the API I used (https://services.openaire.eu/search/v2/api/resources2) does not seem to be documented on the OpenAIRE developer site. I would be hesitant to use it in integrations without further inquiring about the stability of the API.
There is undoubtedly a better way to do the same thing in SPARQL, but as Iâm not overly familiar with it or the OpenAIRE ontologies, this worked best for me. Maybe someone more knowledgeable will post a SPARQL solution.
Hello Maarten,
thank you for the provided code snippet. It seems I get the same results for an ORCID as via the OpenAire EXPLORE service, which is what Iâm looking for!
I tried using the API to query organizations as well and found some organizations with a ROR which I havenât seen in other APIs or even in the data dumps. But here the results seem to differ from the EXPLORE service: when I query for organizations like https://services.openaire.eu/search/v2/api/resources2/?format=json&type=organizations I get a list of organizations, but when I use their name to query them in the EXPLORE service, they are not included, e.g. âTanger Computersystemsâ
Unfortunately I havenât heard from OpenAire (sent a mail + support request) so I canât explain the differences
The explore form seems to add some additional filters. If I interpret them correctly, there should either be a link to a project, or related datasources must have a certain the relateddatasourcecompatibilityid. This does not seem to be the case for Tanger computersystems, which seems to have no related projects or outputs:
Hello all,
itâs been a while, but I recently documented my findings about querying the OpenAIRE HTTP API using PIDs and wanted to share it with you. Also: thanks a lot to you, Maarten and Andreas, both your programs were really helpful in exploring the data and the data model further!
â Connections between entities are made via the ârelsâ (=relations) or âcontextâ property of an entity
PIDs in the HTTP API
The HTTP API describes the following identifiers that can be used to query research products or projects:
research product
ORCID
DOI
openairePublicationID
originalId
openaireProviderID
openaireProjectID
projectID
FP7ProjectID
projects
callID - call identifier
grantID
openaireProjectID
openaireParticipantID â this is an organization identifier, e.g. "openorgs____::8e609ea7e0fe26c86a3dea31a2ef2ce2" for TIB â OpenOrgs is the mapping tool for organizational IDs developed by OpenAIRE â is not yet released, so queries using an organizational identifier like ROR ID might be possible at a later stage
Supported PID-queries in the HTTP API
We can query the following two connections from OpenAIRE using an ORCID iD or a DOI as input:
Person-Publication (ORCID â DOI)
OpenAIRE lets you query different research products (publication, data, software, other) via an ORCID iD
Each research product may be identified by its DOI
Note: the API has several different endpoints for research products: they are divided into publications, research data, software metadata and other research products, so to get a full picture about a personâs output, you would have to query all of these endpoints with an ORCID iD and union all results
Publication-Project (DOI â OpenAIRE project ID)
OpenAIRE lets you query different research results (publication, data, software, other) via a DOI
Each research result may be connected to a project identified by its âOpenAIRE project IDâ, that we can use to query the projectâs metadata
Both queries are also available and documented in the pidgraph-notebooks, our collection of Jupyter notebooks with examples of querying different PID providers like ORCID, ROR, Crossref and PID graphs like the FREYA PID Graph, OpenAlex and OpenAIRE for connected objects:
Manghi, Paolo. (2021, June 25). The OpenAIRE Research Graph: Science as a public good - Keynote at VIVO Conference 2021. Zenodo. https://doi.org/10.5281/zenodo.5032327