Skip to content

Endpoints

All url requests listed should be be made to a Hakai API server (https://hecate.hakai.org/api). Each of the listed endpoints in this documentation is a location on this website that provides a specific kind of dataset. For example, if you would like chlorophyll data you would make a request to https://hecate.hakai.org/api/eims/views/output/chlorophyll since the listed endpoint is /eims/views/output/chlorophyll.

These URLs are all paths that exist on the API server https://hecate.hakai.org/api. As such, if the given URL is /eims/views/output/akan_cat_ph, make your request to https://hecate.hakai.org/api/eims/views/output/akan_cat_ph.

EIMS data

URL Purpose
/eims/views/output/akan_cat_ph Get json data equivalent to the portal downloaded spreadsheet for akan_cat_ph
/eims/views/output/c13incubations Get json data equivalent to the portal downloaded spreadsheet for c13incubations
/eims/views/output/chlorophyll Get json data equivalent to the portal downloaded spreadsheet for chlorophyll
/eims/views/output/chlorophyll_blanks Get json data equivalent to the portal downloaded spreadsheet for chlorophyll_blanks
/eims/views/output/chlorophyll_solid_standards Get json data equivalent to the portal downloaded spreadsheet for chlorophyll_solid_standards
/eims/views/output/ctd_all Get json data equivalent to the portal downloaded spreadsheet for ctd_all
/eims/views/output/ctd_drops Get json data equivalent to the portal downloaded spreadsheet for ctd_drops
/eims/views/output/do13c Get json data equivalent to the portal downloaded spreadsheet for do13c
/eims/views/output/doc Get json data equivalent to the portal downloaded spreadsheet for doc
/eims/views/output/fgs Get json data equivalent to the portal downloaded spreadsheet for fgs
/eims/views/output/fgs_samples Get json data equivalent to the portal downloaded spreadsheet for fgs_samples
/eims/views/output/fgs_w_poms Get json data equivalent to the portal downloaded spreadsheet for fgs_w_poms
/eims/views/output/filters Get json data equivalent to the portal downloaded spreadsheet for filters
/eims/views/output/hplc Get json data equivalent to the portal downloaded spreadsheet for hplc
/eims/views/output/metadata_all Get json data equivalent to the portal downloaded spreadsheet for metadata_all
/eims/views/output/mg_clams Get json data equivalent to the portal downloaded spreadsheet for mg_clams
/eims/views/output/mg_epiphytes Get json data equivalent to the portal downloaded spreadsheet for mg_epiphytes
/eims/views/output/mg_filtered_epiphytes Get json data equivalent to the portal downloaded spreadsheet for mg_filtered_epiphytes
/eims/views/output/mg_fish Get json data equivalent to the portal downloaded spreadsheet for mg_fish
/eims/views/output/mg_inverts Get json data equivalent to the portal downloaded spreadsheet for mg_inverts
/eims/views/output/mg_macroalgae Get json data equivalent to the portal downloaded spreadsheet for mg_macroalgae
/eims/views/output/mg_mesograzers Get json data equivalent to the portal downloaded spreadsheet for mg_mesograzers
/eims/views/output/mg_seagrass_biomass Get json data equivalent to the portal downloaded spreadsheet for mg_seagrass_biomass
/eims/views/output/mg_seagrass_density Get json data equivalent to the portal downloaded spreadsheet for mg_seagrass_density
/eims/views/output/mg_seagrass_habitat Get json data equivalent to the portal downloaded spreadsheet for mg_seagrass_habitat
/eims/views/output/microbial Get json data equivalent to the portal downloaded spreadsheet for microbial
/eims/views/output/mussels Get json data equivalent to the portal downloaded spreadsheet for mussels
/eims/views/output/nitrates Get json data equivalent to the portal downloaded spreadsheet for nitrates
/eims/views/output/nutrients Get json data equivalent to the portal downloaded spreadsheet for nutrients
/eims/views/output/nutrients_qc Get json data equivalent to the portal downloaded spreadsheet for nutrients_qc
/eims/views/output/o18 Get json data equivalent to the portal downloaded spreadsheet for o18
/eims/views/output/phytoplankton Get json data equivalent to the portal downloaded spreadsheet for phytoplankton
/eims/views/output/pomfas Get json data equivalent to the portal downloaded spreadsheet for pomfas
/eims/views/output/poms Get json data equivalent to the portal downloaded spreadsheet for poms
/eims/views/output/poms_chlorophyll Get json data equivalent to the portal downloaded spreadsheet for poms_chlorophyll
/eims/views/output/poms_doc_do13c_nut_suva_chlorophyll_ysi_ctd Get json data equivalent to the portal downloaded spreadsheet for poms_doc_do13c_nut_suva_chlorophyll_ysi_ctd
/eims/views/output/pon_poc Get json data equivalent to the portal downloaded spreadsheet for pon_poc
/eims/views/output/pop Get json data equivalent to the portal downloaded spreadsheet for pop
/eims/views/output/samples_by_category Get json data equivalent to the portal downloaded spreadsheet for samples_by_category
/eims/views/output/secchi Get json data equivalent to the portal downloaded spreadsheet for secchi
/eims/views/output/soms Get json data equivalent to the portal downloaded spreadsheet for soms
/eims/views/output/staff_gauge Get json data equivalent to the portal downloaded spreadsheet for staff_gauge
/eims/views/output/suva Get json data equivalent to the portal downloaded spreadsheet for suva
/eims/views/output/ysi Get json data equivalent to the portal downloaded spreadsheet for ysi
/eims/views/output/zooplankton_biomass Get json data equivalent to the portal downloaded spreadsheet for zooplankton_biomass
/eims/views/output/zooplankton_isotope Get json data equivalent to the portal downloaded spreadsheet for zooplankton_isotope
/eims/views/output/zooplankton_microscopy Get json data equivalent to the portal downloaded spreadsheet for zooplankton_microscopy
/eims/views/output/zooplankton_total_biomass Get json data equivalent to the portal downloaded spreadsheet for zooplankton_total_biomass
/eims/views/output/zooplankton_tow Get json data equivalent to the portal downloaded spreadsheet for zooplankton_tow

SN data (Sensor Network)

HTTP Verb URL Purpose
GET /sn/views/list Retrieve the list of all the sn views available
GET /sn/views/:viewName Get json data of a sensor network view
GET /sn/tables/list Retrieve the list of all the sn tables available
GET /sn/tables/:tableName Get json data of a sensor network data table
GET /sn/qc/:tableName Get json data of the manual qc data available for this table in sn_qc schema
POST /sn/qc/:tableName Post manual qc flags and data to the given table
PUT /sn/qc/:tableName/:pk Update a specific Manual QC Flag
GET /sn/sa/tables/list Retrieve the list of all the sn_sa schema tables available
GET /sn/sa/tables/:tableName Get json data of a sn_sa schema specific table

CTD data

URL Purpose
/ctd/views/file/cast Get a list of all ctd casts joined with metadata from the file it was pulled from
/ctd/views/file/cast/data (filtered) Get a list of all processed ctd data joined with metadata from the cast and file it was pulled from
/ctd/views/file/cast/raw_data (filtered) Get a list of all unprocessed ctd data joined with metadata from the cast and file it was pulled from
/ctd/views/file/cast/raw_buffered (filtered) Get a list of all unprocessed ctd data joined with metadata from the cast and file it was pulled from

Filtered Endpoints

Marked endpoints above are filtered to exclude large data fields - see details here.

If you need the full data row, define the desired fields in the fields query parameter.

Solo data

URL Purpose
/solo/views/file/cast Get a list of all solo casts joined with metadata from the file it was pulled from

Copyright (c) 2017 Hakai Institute and individual contributors. All Rights Reserved.

ACO data

HTTP Verb URL Function
GET /aco/aois Get a list of AOIS in GeoJSON format.
GET /aco/aois/:aoi_id(\d+) Get a specific AOI using it's unique id.
POST /aco/aois Add a new AOI by submitting a "FeatureCollection" or "MultiPolygon" GeoJSON polygon.
GET /aco/camera_calibration Get a list of camera calibration parameters.
GET /aco/camera_calibration/:pk(\d+) Get a specific camera calibration parameter object using it's unique id.
POST /aco/camera_calibration Add new camera calibration data by posting a JSON object with all the required db keys as the object keys.
GET /aco/dces Get a list of all the data collection events (i.e. field report jobs).
GET /aco/dces/:data_collection_event_id(\d+) Get a specific data collection event using an integer unique id.
GET /aco/flights/:flight_id(\d+)/dces Get a list of all data collection events for a specific flight with unique integer flight_id.
POST /aco/flights/:flight_id(\d+)/dces Add a new data collection event with parent flight that has unique id flight_id.
PUT /aco/dces/:data_collection_event_id(\d+) Update an existing data collection event with the specified unique id.
DELETE /aco/dces/:data_collection_event_id(\d+) Delete the data collection event with with specified unique id.
GET /aco/flights Get a list of flights.
GET /aco/flights/:flight_id(\d+) Get a specific flight object with the specified unique id.
POST /aco/flights Add a new flight.
PUT /aco/flights/:flight_id(\d+) Update the flight with the specified unique id.
GET /aco/lever_arm_calibration Get a list of lever arm calibration parameters.
GET /aco/lever_arm_calibration/:lever_arm_calibrations_id(\d+) Get a specific lever arm calibration with the specified unique id.
POST /aco/lever_arm_calibration Add a new lever arm calibration.
GET /aco/persons Get a list of persons.
GET /aco/persons/:person_id(\d+) Get the person with the specified unique id.
POST /aco/persons Add a new person.
GET /aco/phases Get a list of project phases.
GET /aco/phases/:projectphase_id(\d+) Get a project phase object with the specified unique id.
PUT /aco/phases/:projectphase_id(\d+) Update the project phase with the specified unique id.
GET /aco/projects/:project_id(\d+)/phases Get a list of project phases for the project with the specified project_id.
POST /aco/projects/:project_id(\d+)/phases Add a new project phase with parent being the project with project_id.
GET /aco/projects Get a list of projects.
GET /aco/projects/:project_id(\d+) Get a specific project with the specified unique id.
PUT /aco/projects/:project_id(\d+) Update a project with the specified unique id.
POST /aco/projects Add a new project.

Views

The following are provided for convenience and allow accessing multiple database tables at once, after they are joined in the database.

HTTP Verb URL Function
GET /aco/views/flight_time Get a summary of time spent flying, broken down by date.
GET /aco/views/flights Get a list of flights, with some additional columns like pilot name and operator name.
GET /aco/views/flights/:flight_id(\d+) Same as /views/flights, but get a specific flight by id.
GET /aco/views/flights/dces Get a list of flights joined with the associated data collection events.
GET /aco/views/flights/:flight_id(\d+)/dces Get a list of all data collection events for a specific flight and include the flight information.
GET /aco/views/flights/dces/:data_collection_event_id(\d+) Same as /views/flights/:flight_id(\d+)/dces, but get a specific data collection event by id.
GET /aco/views/operators Get a list of operators with name info from associated persons table.
GET /aco/views/operators/:operator_id(\d+) Get the info for a specific operator by id.
GET /aco/views/pilots Get a list of pilots with name info from the associated persons table.
GET /aco/views/pilots/:pilot_id(\d+) Get the info for a specific pilot by id.
GET /aco/views/projects/phases Get a list of projects phases joined with the higher level project details.
GET /aco/views/projects/phases/:projectphase_id(\d+) Same as /views/projects/phases, but get just the info for the project phase with the specified id.
GET /aco/views/projects/:project_id(\d+)/phases Same as /views/projects/phases, but just get project phases where the project id .
GET /aco/views/projects/:project_num(\d{2}_\d{4})/phases/:phase_num(\d+) Get info for project with project_num (eg. 21_3008) and phase_num (e.g. 1). The parameter values are not to be confused with the database id fields.
GET /aco/views/projects/phases/:projectphase_num(\d{2}\d{4}\d{2}) Get info for project with projectphase_num (eg. 21_3008_01).
POST /aco/views/projects/phases Add a new project and phase, simultaneously. Must submit JSON containing all the fields that the POST /projects and POST /projects/:project_id(\d+)/phases expect.
GET /aco/views/projects/phases/aois Get a list of project, project phase, and aoi data joined together.
GET /aco/views/projects/:project_id(\d+)/phases/aoi Same as /views/projects/phases/aois, but restrict so only the rows where project with project_id are returned.
GET /aco/views/projects/:project_num(\d{2}_\d{4})/phases Get info for project joined to project phase data, where the project_num (eg. 21_3008) is equal to the specified project_num parameter.
GET /aco/views/projects/:project_num(\d{2}_\d{4})/phases/aois Same as /views/projects/phases/aois, but restrict so only the rows where project num (e.g. 20_3038) are returned.
GET /aco/views/projects/:project_num(\d{2}_\d{4})/phases/:phase_num(\d+)/aois Get info for project with project_num (eg. 21_3008) and phase_num (e.g. 1), along with aoi data. The parameter values are not to be confused with the database id fields.
GET /aco/views/projects/phases/aois/:projectphase_num(\d{2}\d{4}\d{2}) Get info for project with projectphase_num (eg. 21_3008_01), along with aoi data.
GET /aco/views/projects/phases/:projectphase_id(\d+)/aois Same as /views/projects/phases/aois, but restrict so only the rows where project phase with projectphase_id are returned.
PUT /aco/views/projects/phases/:projectphase_id(\d+)/aois Insert a new AOI into the database (like POST /aois), and update the project phase with projectphase_id to point to this new AOI database record.
GET /aco/views/projects/phases/:projectphase_id(\d+)/aois/dces Get a list of joined project, project phase, aoi, and data collection event data, where the project phase id is equal to the specified projectphase_id param.
GET /aco/views/projects/phases/aois/dces/:data_collection_event_id(\d+) Get a list of joined project, project phase, aoi, and data collection event data, where the data collection event id is equal to the specified data_collection_event_id param.
GET /aco/views/projects/phases/:projectphase_id(\d+)/aois/dces/:data_collection_event_id(\d+) Get a list of joined project, project phase, aoi, and data collection event data, where the data collection event id is equal to the specified data_collection_event_id param and where the project phase id is equal to the specified projectphase_id param.
GET /aco/views/projects/phases/:projectphase_id(\d+)/dces Get a list of joined project, project phase, and data collection event data, where the project phase id is equal to the specified projectphase_id param.
GET /aco/views/projects/phases/dces/:data_collection_event_id(\d+) Get a list of joined project, project phase, and data collection event data, where the data collection event id is equal to the specified data_collection_event_id param.
GET /aco/views/projects/phases/:projectphase_id(\d+)/dces/:data_collection_event_id(\d+) Get a list of joined project, project phase, and data collection event data, where the data collection event id is equal to the specified data_collection_event_id param and where the project phase id is equal to the specified projectphase_id param.
GET /aco/views/projects Get a list of projects, with a nicely formatted project number like e.g. 20_3008.
GET /aco/views/projects/:project_num(\d{2}_\d{4}) Get the data for a specific project with the specified project number like e.g. 21_4016.
GET /aco/views/projects/:project_id(\d+) Get the data for a specific project with the specific project_id unique identifier.