Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

‘chloropleth’ API endpoint #56

Open
loarie opened this issue Jan 13, 2017 · 1 comment
Open

‘chloropleth’ API endpoint #56

loarie opened this issue Jan 13, 2017 · 1 comment
Labels

Comments

@loarie
Copy link
Member

loarie commented Jan 13, 2017

endpoint that takes taxon_id and place_id array (as well as other obs search params, e.g.
api.inaturalist.org/v1/observations/choropleth?places=14,12&taxon_id=2041&verifiable=true…
and returns observation counts by places in the array. All I need at the moment is place_id, obs_count, e.g.:

{
  "total_results": 357,
  "page": 1,
  "per_page": 357,
  "results": {
    "places": {
      "13": 7,
      "15": 30,
      "16": 41,
      "18": 52,
      "31": 97,
      "54": 90,
      ...
    }
  }
}

but it might be wise to include the place object in the response if we wanted to anticipate other uses, e.g.:

{
  "total_results": 494,
  "page": 1,
  "per_page": 494,
  "results": [
    {
      "place": {
           name: "California",
           id: 14,
           ...
      },
      "observations_count": 10,
    },
    ...
  ]
}
@JWCook
Copy link
Contributor

JWCook commented Feb 15, 2021

I would find this useful as well!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants