Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagepy
import requests

url = 'http://localhost:8080/FewsWebServices/rest/fewspiservice/v1/timeseries'

params = dict(
    documentVersion='1.23',
    documentFormat='PI_JSON'
)

response = requests.get(url=url, params=params)
data = response.json()

 

Javascript

Using popular javascript libraries like leaflet, jquery and mapbox a web application can be made using the FEWS PI-JSON REST Web Service. The following example shows how to get all locations from FEWS and plot them on a map:

...