Mapping iNaturalist metadata to DarwinCore properites

TL;DR: How can I most easily map iNat metadata <–> DwC properites for arbitrary observations?

I’m interested in storing some iNaturalist metadata for my own observations with the corresponding photos on my local machine, probably in the form of XMP sidecar files. I’m mainly interested in the taxonomic ranks, so I can more easily sort/search my local photos by taxon the way I can on iNaturalist, among many other possible uses.

I was just about to start making a custom XMP namespace for this until I found out about the DarwinCore spec (DwC), which looks like just want I wanted and much more. I then found that iNat was a few steps ahead of me and already had a system for exporting observations into a GBIF DarwinCore Archive.

I see that this is built into the Rails app to export the entire collection of RG observations, but what I would like to be able to do is take metdata from an arbitrary subset of observations and translate that into DwC properties in XMP format.

My first attempt at this would look something like:

  • Query observations from GET /observations
  • Query taxon and its ancestors (higher ranks) from GET /taxa/{id}
  • Translate response info into DwC properties (dwc:Species, dwc:scientificName, etc.)
  • Write properties to XMP sidecar file

Alternatively I could grab the entire GBIF archive and get my own observations out of that, but that would be pretty inefficient, especially if I regularly wanted to fetch recently updated observation info.

Any suggestions on how I could do this more easily? Is there any portion of the DarwinCore functionality in the Rails app that is exposed in one of the REST endpoints? Or is there a summary somewhere of mappings between iNat metadata and DwC properties?

Also, if there is a better forum or category in which to post development-related questions, let me know.


The iNaturalist staff might be able to help. You can message them directly by clicking on their profile and there is a button on the top right corner to message them. Also they will probably see your post soon and reply. They are very helpful and informational and kind. Welcome to our community!

You could also export your observations to a file at (EDIT: Export initially gives an error, but you can get the export file if you reload the page after few minutes. Filed a bug report about this.)

/observations endpoint of the API returns the higher/ancestor taxa, so you don’t need to fetch them separately. But you do need to authenticate yourself, if you want to get private data about your own observations.

Note that if you also want to get updates of your observations using the API, you can get most of them using the updated_since filter, but not all. As far as I remember, e.g. changes to captive/cultivated status do not change the updated_at field of the observation.


Thanks, that’s helpful!

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.