The SILO Web Application Programming Interface (API) allows you to query point datasets, as well as a range of metadata, in real time.
The SILO API has the following base URL:
https://www.longpaddock.qld.gov.au/cgi-bin/silo
For example, a request for point data might look like:
https://www.longpaddock.qld.gov.au/cgi-bin/silo/PatchedPointDataset.php?station=1018&start=20170101&finish=20170228&format=alldata&username=<email_address>
For detailed information about request parameters please consult the reference.
The following data are available through the SILO API:
The following metadata are available:
Data requests must be accompanied by your email address. We need your email address in case we need to contact you about the service.
Point data are available in CSV and JSON, as well as a number of predefined formats, all of which are returned as plain ASCII text.
Metadata are provided in plain ASCII text.
You can specify your desired format using the format
query parameter. For example:
https://www.longpaddock.qld.gov.au/cgi-bin/silo/DataDrillDataset.php?format=json
API requests are standard HTTP calls. The SILO API allows for retrieval of data only, so the API only supports HTTP GET methods. It's possible to use the API simply by typing the URL into your browser. The API can also be queried by a program. Here is a simple example in Python:
import urllib.request
r = urllib.request.urlopen('https://www.longpaddock.qld.gov.au/cgi-bin/silo/PatchedPointDataset.php?format=name&nameFrag=Cairns
')
data = r.read()
print(data)
The API can also be queried by command line tools. Here is a simple example using wget:
wget -O Cairns_stations 'https://www.longpaddock.qld.gov.au/cgi-bin/silo/PatchedPointDataset.php?format=name&nameFrag=Cairns'
# NOTE: you may need to set proxy environment variables to pass through your local firewall
Data are returned in the format requested. However users should note the following: