Extinction status and the species API routes

A taxize user asked about extinction status and the species API. In taxize we have a function that iteratively gets taxa downstream from a target taxon, and uses the /species/{id}/children/ route to do that.

The user wants to limit to extant taxa. However, the /species/{id}/children/ route doesn’t allow filtering by extinction status AND doesn’t return extinction status data. The /species/search/ route does allow that, and returns extinction status data.

Any guidance on how one would get taxonomic children while simultaneously filtering out extinct taxa - OR - would it be possible to return the extinct field on the /species/{id}/children/ route?

One could use the /species/{id}/children/ route, then call another route for each of those taxa to get extinction status but that’s potentially a lot of extra http requests.

1 Like

Yes, thats a good idea but needs an API change. Currently this is not possible. Maybe sth I should earmark for the new CoL API: https://github.com/CatalogueOfLife/backend/issues/837

Okay, thanks very much, i’ll watch that issue