chembl / chembl_webresource_client

Official Python client for accessing ChEMBL API
https://www.ebi.ac.uk/chembl/api/data/docs
Other
360 stars 95 forks source link

Querying by inchi #121

Closed NadavQuris closed 1 year ago

NadavQuris commented 1 year ago

Hi, I'm trying to get a molecule by InChI. I can't seem to filter anything correctly and I would appreciate help. What I'm doing is:

acetaminophen_inchi = "InChI=1S/C8H9NO2/c1-6(10)9-7-2-4-8(11)5-3-7/h2-5,11H,1H3,(H,9,10)"
molecule = new_client.molecule
aceta = molecule.filter(standard_inchi__iexact=acetaminophen_inchi)

Which returns 2331700 molecules (all of them?) What am I doing wrong?