Closed alee closed 1 year ago
One challenge with a multipolygon study area is that our current time series tool pulls data from the minimal bounding rectangle for the geometry, and that rectangle is size limited. For example, a multiple polygon geojson of Cochiti and Santa Clara Pueblos works (c. 1,900 km^2), but one with Hopi and Zuni doesn't (c. 55,000 km^2). Perhaps break up the geometry to make multiple requests, or change the time series tool to select only pixels it needs. You can test with the attached geojsons. multipolygon.zip
curl command to test geojson POST requests on staging.openskope.org
curl -X POST --data "studyArea={\"type\":\"Feature\",\"properties\":{},\"geometry\":{\"type\":\"Point\",\"coordinates\":[-107.971802,36.048799]}}" http://staging.openskope.org/dataset/paleocar_v3 --header "Content-Type: application/json"
This is working for me (I'm getting a 200 response) but just sends me to a page that says "Loading map, please wait..." but doesn't proceed past that. I'm probably doing something wrong, but how are you performing this in browser?
This should be working now as of 9f3e33fe11a54ecc6d1849fc7542cff47676ffbe (apologies for the delay, travel and other work prevented me from getting to take a closer look at this).
I'm using a basic form to POST to staging.openskope.org like this example:
We'll try to add POST support to the select study area URL:
(will be live on staging first, sometime the week of June 1st or so)
https://staging.openskope.org/dataset/paleocar_v3
And in production: https://app.openskope.org/dataset/paleocar_v3
and in the form data stick it in an attribute like
selectedArea
orgeoJson
or something similarcould also use it in a GET request if it's embedded in
request.body
I believe...multiple disparate areas are likely problematic for our current timeseries backend API as @bocinsky indicated below as the API finds the minimum bounding box that encompasses all of the geojson areas, new issue in skope-api for that at https://github.com/openskope/skope-api/issues/40
Nuxt implementation
https://stackoverflow.com/questions/54289615/how-to-read-post-request-parameters-in-nuxtjs
https://stackoverflow.com/questions/59478989/vue-nuxt-js-how-to-read-post-request-parameters-received-from-an-external-re
from chatgpt: