-
-
Save paladin3895/51a3dbc339228b22767ba44e588caa43 to your computer and use it in GitHub Desktop.
Python method to access crossref.org DOI bibtex metadata resolver
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
def doi2bib(doi): | |
""" | |
Return a bibTeX string of metadata for a given DOI. | |
""" | |
url = "http://dx.doi.org/" + doi | |
headers = {"accept": "application/x-bibtex"} | |
r = requests.get(url, headers = headers) | |
return r.text |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment