Description
Problem
PRISM doesn't have an intuitive API. It has rainfall and other info, but he interface is an AJAX call to a PHP backend which is hidden by JavaScript here which I can't figure it out. Maybe there's a way to use the JavaScript to get the data and add it to iotools. Then the data could be used for soiling. See HSU soiling example
Solution
in iotools, get_prism_rainfall()
that uses the JavaScript https://prism.oregonstate.edu/explorer/dataexplorer/js/explorer.js to get the rainfall
Describe alternatives you've considered
Just point users to the website, it also has a bulk download tool. Maybe they don't want folks to use the site programmatically?
Additional context
JavaScript modules used:
- https://prism.oregonstate.edu/explorer/dataexplorer/js/explorer.js
- https://prism.oregonstate.edu/explorer/dataexplorer/js/data_stability.js
base URL of AJAX post call:
- https://prism.oregonstate.edu/explorer/dataexplorer/rpc.php
but it returns 500 when I post anything, since I don't know what to post
there's also a web service to download an entire monthly or daily grid:
- https://prism.oregonstate.edu/documents/PRISM_downloads_web_service.pdf
or bulk - https://prism.oregonstate.edu/documents/PRISM_downloads_FTP.pdf
maybe that's the better way to go?