Skip to content
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

datacite API #1

Open
blahah opened this issue Jan 16, 2016 · 3 comments
Open

datacite API #1

blahah opened this issue Jan 16, 2016 · 3 comments

Comments

@blahah
Copy link
Member

blahah commented Jan 16, 2016

The datacite API has metadata for a large number of figure-like datasets. For example, a search for files with MIMEtype image/png returns 97,991 records:

http://search.datacite.org/api?q=format:image/png

However, the records don't link directly to the data files. They provide metadata including the DOI, which can be used to resolve a landing page for each record, and in general these link directly to the data files.

@blahah
Copy link
Member Author

blahah commented Jan 16, 2016

Some success by combining curl and bo:

get the redirect url:

$ curl --silent -I http://dx.doi.org/10.5880/GFZ.LIS.2015.001 | grep 'Location' | cut -d' ' -f2
http://pmd.gfz-potsdam.de/panmetaworks/showshort.php?id=escidoc:1160009

find the pngs:

curl --silent -L http://dx.doi.org/10.5880/GFZ.LIS.2015.001 | bin/bo -a href 'a[href$="png"]'
schematic-overrview-on-permafrost-landscapes_snow.PNG
schematic-overrview-on-permafrost-landscapes_fluxes.png
schematic-overrview-on-permafrost-landscapes.png

should allow us to construct the final URLs, e.g.:

http://pmd.gfz-potsdam.de/panmetaworks/schematic-overrview-on-permafrost-landscapes_fluxes.png

@blahah
Copy link
Member Author

blahah commented Jan 16, 2016

But actually, it doesn't! those URLs don't work - there are other URLs that link to the actual PNGs but don't have .png extension. grrr....

@blahah
Copy link
Member Author

blahah commented Jan 16, 2016

So it looks like this is off the table... which is a huge shame.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant