How to use iNaturalist's Search URLs - wiki part 1 of 2

Thank you jdmore. Very useful.
Re bulk editing search results, I am not sure if I understand, but in Edit my observations there are not the same filter options I think?

1 Like

Is there a way to search for an obs that has comments, or even better, comments by a particular member?

1 Like

I think I did not absorb this fully. I eill try using that url and see where I find myself. Thanks again.

1 Like

So in the case of my observations, I would go to https://www.inaturalist.org/observations/jdmore, then use Search to filter the set of observations I want to edit (including any manual additions to the filter URL, if necessary). Then when I have the desired set, I would click “Batch Edit.” Empty check boxes will appear next to each observation, along with several batch options along the top, including “Select All” which will check all the check boxes. Then click “Edit Selected.” There will be further batch options at the top, but for some kinds of edits you may have to visit each observation individually. Hope that helps…

I’m not aware of a way to filter observations by comment presence or comment author, but maybe someone above my “pay grade” is…?

3 Likes

You can search using the URL for comments on all observation like this (for “robin”): https://www.inaturalist.org/comments?commit=Search&q=robin

I feel like that’s not what you’re asking for though.

5 Likes

Good to know though, thanks

1 Like

Thank you jdmore that’s very clear. Will experiment as soon as time permits

1 Like

A most useful topic!

I am trying to see all comments for a particular taxon (species or subspecies). Is that possible? I have played around with urls for both the ~/taxa and ~/comments pages with no luck.

At present I have to go to the ~/observations page grid view and look for those with the most comments icon and open them at random. it would be also nice to on this page, only see those with comments, or order them descending with the most comments.

10 Likes

I would like to be able to find comments based on user id. E.g. I can remember that a comment was made by a particular person, but I can’t remember where. So it’ll be a parameter like the one for identification by a particular user (ident_user_id) but for comments. I tried various permutations of comment_user_id but couldn’t find the right syntax.

5 Likes

@karoopixie - there is no hack you are missing, this functionality does not exist.

2 Likes

Ah. Thanks, cmcheatle. I think I shall motivate for this under feature requests.

EDIT: Have added the feature request - https://forum.inaturalist.org/t/search-comments-by-user-id/1009/2

4 Likes

Can someone please post an example of ‘sort by’ parameters to categorize my search results alphabetically? e.g. Correa reflexa var reflexa is before Xerochrysum viscosum.
I would also appreciate categorizing my results by family names alphabetically arranged so that the species of (f)Asteraceae species = Xerochrysum would come become before (f)Stylidiaceae species = Stylidium (If that’s possible to do)

3 Likes

NOTE: this is in part cross-posted from this discussion: https://forum.inaturalist.org/t/any-way-to-bulk-edit-native-introduced-status-for-a-species/677

Here’s a bit more complicated query that I found to solve a problem I had – a query identifying all Counties within a State that have a species on their checklists. For example, this can be done for Berberis aquifolium in Idaho (place_id=22) with this:
https://www.inaturalist.org/places.json?taxon=berberis+aquifolium&per_page=200&ancestor_id=22&place_type=County
( ancestor_id is the upper-level place to search within, and per_page is needed because the default will give an incomplete list for states with many counties.)

To figure this out, I consulted the iNaturalist API docs. The newer alternative API docs are also a great source for hints.

2 Likes

I’m not sure whether I missed it, but although the programer interface (API) was mentioned, I don’t think anyone explicity pointed out that there are two URL syntaxes available.

One is the older set of parameters used by the original API and things like the export observations function, and the other is the newer set supported by the explorer filters page.

So there are alternate ways of specifying things, eg “with photos” can be “&has[ ]=photos” in the old search and “&photos” in the new. It appears that using a mixture of old and new parameters will cause it to decide to use one search mode and ignore parameters meant for the other.

Anyway I don’t know how to invoke it in the new mode, but if you want to find all the observations in your project that haven’t been ID’d by one of the project’s curators, try something like:

https://inaturalist.nz/observations/project/lichens-of-nz?pcid=false

or

https://inaturalist.nz/observations.json?projects[]=lichens-of-nz&pcid=false&page=1&per_page=200

–Tony

2 Likes

Is there a way to search for all observations that I have identified to a particular taxon (say, cyclosa, for example)?

(the results are the same in this instance, but won’t always be, if the observation ID hasn’t shifted yet)

5 Likes

Might have missed this, but is there a way to find observations I’ve identified as a certain taxon, without child taxa, e.g. observations I identified as “animal”, but not those identified as mammals, insects, or specific species?

3 Likes

Thanks for the quick reply!

I think just with the API, e.g.
https://api.inaturalist.org/v1/identifications?taxon_id=1&rank=kingdom&user_id=deboas&current=true&order=desc&order_by=created_at

Which finds:
https://www.inaturalist.org/observations/429949 and
https://www.inaturalist.org/observations/15639440

See also:
https://www.inaturalist.org/observations?ident_user_id=deboas&lrank=kingdom&place_id=any&subview=grid&taxon_id=1&verifiable=any
Which has similar, but not identical results (since the rank in this case is looking at the overall observation ID, not your identification.

4 Likes

Perfect, thank you!