dronefly-garden / dronefly

Red Discord Bot V3 cogs for naturalists.
Other
16 stars 3 forks source link

obs (grammar): support web search form checkboxes #91

Open synrg opened 4 years ago

synrg commented 4 years ago

All checkboxes on the web search form should be supported in the observation search grammar. Use the preposition with and accept any number of keywords, e.g.

,obs any from maritimes with needsid sounds

Note: the new keyword any in this example is currently unimplemented & is proposed in #89

In this example, needsid and sounds are equivalent to selecting "Needs ID" and "Has Sounds" on the search form, resulting in this URL: https://www.inaturalist.org/observations?place_id=82180&quality_grade=needs_id&sounds

The API accepts the same parameters, except booleans must have a value, so this URL would do the trick: https://api.inaturalist.org/v1/observations?place_id=82180&quality_grade=needs_id&sounds=true&verifiable=any

michaelpirrello commented 4 years ago

Can we do anything about iNat's lack of iconic taxa for bacteria, viruses, and archaea? It would mean adding something beyond what's in the web search, but would allow for the simple ,obs bacteria by me (without having to remember the taxon_id's for those three (131236, 67333, 151817)).

synrg commented 4 years ago

Let's take this up further on #89 as this specific tributary issue is more related to my proposal there than the checkboxes on the search form.