The following links are some examples of using the properties Discovery Service.  The token refers to your Web Services API token, which you can find in the Web Services API tab of your Ocean Networks Canada profile.

DescriptionURL

Return a list of All Properties (no filters)

https://data.oceannetworks.ca/api/properties?method=get&token=YOUR_TOKEN_HERE
Return the Property with the Property Code 'seawatertemperature'https://data.oceannetworks.ca/api/properties?method=get&token=YOUR_TOKEN_HERE&propertyCode=seawatertemperature

Return a list of all Properties with a Name containing 'pressure'

https://data.oceannetworks.ca/api/properties?method=get&token=YOUR_TOKEN_HERE&propertyName=pressure
Return a list of all Properties available at a location with the Location Code 'BACAX'https://data.oceannetworks.ca/api/properties?method=get&token=YOUR_TOKEN_HERE&locationCode=BACAX

Return a list of all Properties available for a device with the Device Code 'NORTEKAQDPRO8398'

https://data.oceannetworks.ca/api/properties?method=get&token=YOUR_TOKEN_HERE&deviceCode=NORTEKAQDPRO8398

Return a list of all Properties that available for instruments with the Device Category 'ADCP2MHZ'

https://data.oceannetworks.ca/api/properties?method=get&token=YOUR_TOKEN_HERE&deviceCategoryCode=ADCP2MHZ

The https://data.oceannetworks.ca/apiproxy/properties URL link in the above examples can be used in a browser for sharing or testing purposes; however, it can not be accessed from code. Calls to the apiproxy server are redirected to a login screen to capture your user id. Accessing the apiproxy URL from code will return html in the payload, which may cause errors or unexpected behaviour. In order to use the properties endpoint from code, you must use the https://data.oceannetworks.ca/api/properties URL along with a valid token.

  • No labels