-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to access SPARQL endpoint? #333
Comments
Hi Vladimir, the SPARQL endpoint is documented at https://docs.datacommons.org/api/rest/v1/query |
Thanks @shifucun ! Also, please document the variant of pseudo-SPARQL that you support. Here are examples of valid SPARQL queries that are rejected by your API.
It is also worth noting that one can use GET to make queries, although not in full compliance with https://www.w3.org/TR/sparql11-protocol/#query-via-get :
I escaped the brackets because by default
It is strange that the same query but with
The first hit is geoId/2634860 Greendale Township vs wikidataId/Q1377518 Highgate. Cheers! |
Hello Vladimir, As you note, SPARQL support is limited. GET requests have character limits and so are not recommended. The requirement for a WHERE clause is actually a bug, which we plan on fixing. Hope this helps, |
https://docs.datacommons.org/api/ says
But where can I make SPARQL queries?
Looking at https://github.com/datacommonsorg/api-python/blob/master/datacommons/sparql.py#L77, I guessed that's at
/query
.But https://www.datacommons.org/query?sparql=foo says
The text was updated successfully, but these errors were encountered: