Page tree
Skip to end of metadata
Go to start of metadata

Use Case - Obtain ONC Data

 

A scientific modeller needs to be able to obtain data through the API, as well as Matlab, Python, and R, to provide input into and validation of climate models for climate change forecasting. The data includes weather (wind speed, direction, temperature, etc.), water temperature, salinity, wave heights, and sea ice thickness.

The following link returns a list of shore stations locations; their locationCode values are BFSS, CRSS, DISS, KVSS, RISS.

https://data.oceannetworks.ca/api/locations?method=get&token=YOUR_TOKEN_HERE&locationName=shore

The following links return the device information for those locationCode values. For CRSS the deviceCode values are AXISQ6044PTZACCC8E334FCD, LUFFTWS501-14110141009039, LUFFTWS501-19212161009223, SHINEMICRORADARPLUSAIS151.

https://data.oceannetworks.ca/api/devices?method=get&token=YOUR_TOKEN_HERE&locationCode=CRSS

The following link returns the device categories available at those location Code values. For CRSS the deviceCategoryCode values are AISRECEIVER, METSTN, VIDEOCAM.

https://data.oceannetworks.ca/api/deviceCategories?method=get&token=YOUR_TOKEN_HERE&locationCode=CRSS

The following link returns weather data (limited to 100 entries) at CRSS, beginning at 2018-04-01T00:00:00.000Z.

https://data.oceannetworks.ca/api/scalardata?method=getByLocation&token=YOUR_TOKEN_HERE&locationCode=CRSS&deviceCategoryCode=METSTN&outputFormat=Object&dateFrom=2018-04-01T00:00:00.000Z&rowLimit=100

The following link returns raw data (limited to 100 entries) for the LUFFTWS501-19212161009223 device at CRSS, beginning at 2018-04-01T00:00:00.000Z.

https://data.oceannetworks.ca/api/rawdata?method=getByDevice&token=YOUR_TOKEN_HERE&deviceCode=LUFFTWS501-19212161009223&outputFormat=Object&convertHexToDecimal=false&dateFrom=2018-04-01T00:00:00.000Z&rowLimit=100


Sea ice thickness can be obtained with an Ice Mass Balance Buoy (SIMBA).

The following link returns a list of devices with "balance" in the name; the list is the same if "mass" is used instead of "balance". The deviceCode is SRSLSIMBA1516027.

https://data.oceannetworks.ca/api/devices?method=get&token=YOUR_TOKEN_HERE&deviceName=balance

The following link returns raw data (limited to 100 entries) for the SRSLSIMBA1516027 device, beginning at 2018-04-01T00:00:00.000Z.

https://data.oceannetworks.ca/api/rawdata?method=getByDevice&token=YOUR_TOKEN_HERE&deviceCode=SRSLSIMBA1516027&outputFormat=Object&convertHexToDecimal=false&dateFrom=2018-04-01T00:00:00.000Z&rowLimit=100



Additional links for other locations, types of data, or time ranges of data can be similarly constructed programmatically.


 

 

Please report all issues with the web services, documentation, samples and client libraries to the Oceans 2.0 Help Centre