imls-dmt / imls-dmt-api

imls-dmt-api
Apache License 2.0
1 stars 1 forks source link

Update to access all resources #15

Closed karlbenedict closed 4 years ago

karlbenedict commented 4 years ago

In trying to pull large sets of resources (e.g. "https://esip-dev-02.edacnm.org/api/resources/?limit=400") I'm running into a limit to the maximum number of records that can be retrieved. When trying to drop the "limit" argument I get a default of 10, and when trying larger numbers (probably beyond the defined range) I get a 500 server error. In looking through the API documentation pages I could not find pagination arguments that would allow for setting a start in conjunction a limit to pull a subset for a query starting beyond the beginning of the collection. Please increase the maximum number of records that can be retrieved (a short-term solution) to 500+, and add a "start" parameter to the API to allow for retrieval of blocks of results that start beyond the first record. .

hbarrett commented 4 years ago

I was (and still am) in the process of resolving #17. This is why you were having problems as I was in the process of building new functions to render results. I am still working on the GET method, but you should be able to get results from the POST method. curl 'https://esip-dev-02.edacnm.org/api/resources/' -H 'Content-Type: application/json' --data '{"limit":10000,"search":[]}'

hbarrett commented 4 years ago

Closing for now. Please create a new issue if you want to show just published.