Closed MiguelDLM closed 1 month ago
Thank you for pointing this out, @MiguelDLM! I honestly have no idea how I hadn't noticed this already, but yes, it was broken. It's fixed now!
However, I suspect to get the results you're looking for, you'll want to use something more like https://www.phenome10k.org/api/v1/scan/search?q=Panthera*
. The parameters do exact searches on the whole field, so for partial matches use *
wildcards.
Wow! that was fast, great job! Thanks
Hi,
I'm working on a project where I'm gathering different 3D databases of fossils and I want to include Phenome10k's models. I'm trying to use the API but I always got the same results it doesn't mater what I search for.
For example: Search for Panthera
https://www.phenome10k.org/api/v1/scan/search?q=Panthera
Returns:
{ "count": 20, "error": null, "exact": false, "offset": 0, "q": "Xenopus", "queried_attributes": {}, "query_success": true, "records": [ { "alt_name": "African clawed frog", "attachments": [ { "file": { "date_created": "2014-09-18T10:54:33", "filename": "screenshot_c860e5c09b7371b9a925ddb6d478420f.png", "id": 909, "mime_type": "image/png", "size": 243074 }, "id": 909, "name": "Dorsal" }, { "file": { "date_created": "2014-09-18T10:54:33", "filename": "screenshot_75086f1236a90f51a951fb04e9c54c39.png", "id": 910, "mime_type": "image/png", "size": 138158 }, "id": 910, "name": "Lateral" }, { "file": { "date_created": "2014-09-18T10:54:33", "filename": "screenshot_8d4b699b6390ce27f08f0de9dac9843b.png", "id": 911, "mime_type": "image/png", "size": 254039 }, "id": 911, "name": "Ventral" } ], "author_id": 9, "ctm_id": 907, "date_created": "2014-09-18T10:55:17", "date_modified": "2022-05-06T18:29:30", "description": "This is a CT-scan of an adult female African clawed frog", "file_id": 4603, "gbif_occurrence_id": null, "gbif_species_id": 5217334, "id": 908, "publications": [], "published": true, "scientific_name": "Xenopus laevis", "specimen_id": "XLAF_15", "specimen_link": null, "specimen_location": "Goswami lab, University College London", "url": "http://www.phenome10k.org/xenopus-laevis/", "url_slug": "xenopus-laevis" }...,
I always got the same result for any word used.
Using additional parameters gives a different error.
For example:
https://www.phenome10k.org/api/v1/scan/search?q=panthera&scientific_name=panthera
returns:
{ "count": 0, "error": null, "exact": false, "offset": 0, "q": "panthera", "queried_attributes": { "scientific_name": "panthera" }, "query_success": false, "records": [], "valid_query": true }