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

jmespath: 500 error #324

Open
colleenXu opened this issue Apr 2, 2024 · 1 comment
Open

jmespath: 500 error #324

colleenXu opened this issue Apr 2, 2024 · 1 comment
Assignees
Labels

Comments

@colleenXu
Copy link

I get 500 errors when trying to use jmespath for the following queries.

MyChem Query for specific chembl.drug_mechanism gene, trying to keep only matching chembl.drug_mechanism info

GET version

POST version:

curl --location --globoff 'https://mychem.info/v1/query?size=1000&fields=chembl.molecule_chembl_id,chembl.drug_mechanisms&jmespath=chembl.drug_mechanisms.target_components|[?uniprot=='Q16602']' \
--header 'Content-Type: application/json' \
--data '{
  "q": ["Q16602"],
  "scopes": ["chembl.drug_mechanisms.target_components.uniprot"]
}'

Query for specific civic.evidence_items.disease, trying to keep only matching civic.evidence_items info

GET version

POST version:

curl --location --globoff 'https://myvariant.info/v1/query?size=1000&fields=civic.entrez_id,civic.evidence_items&jmespath=civic.evidence_items.disease|[?doid=='DOID:9256']' \
--header 'Content-Type: application/json' \
--data '{
    "q": "DOID:9256",
    "scopes": "civic.evidence_items.disease.doid"
}'

My guess is that this error has to do with how these fields are nested (two layers with arrays of objects?)

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

No branches or pull requests

3 participants