Docs home

Calibration API reference

This is a documentation for the HTTP API for configuring the calibration information used in Cloudnet data processing.

Routes

GET /api/calibration

This route takes the following URL parameters:

NOTE: For dates that do not have calibration data set, the previous calibration data are returned. For example, given that there are calibration data for date 2021-01-01, querying the data for 2021-01-02 will return the calibration data of 2021-01-01.

PUT /api/calibration

The route takes the following URL parameters:

Request body must contain calibration data as JSON.

Examples

Fetching the most recent value

Example query:

GET https://cloudnet.fmi.fi/api/calibration?instrumentPid=https://hdl.handle.net/21.12132/3.cdf99c536bd04146&date=2021-01-01

Response body:

{
  "data": {
    "range_corrected": true,
    "calibration_factor": 4e-12
  }
}

Setting new value

curl -u username:password \
     -X PUT \
     -H "Content-Type: application/json" \
     -d '{"range_corrected": true, "calibration_factor": 5e-9}' \
     'https://cloudnet.fmi.fi/api/calibration?instrumentPid=https://hdl.handle.net/21.12132/3.cdf99c536bd04146&date=2021-01-01'

Note: Updating the calibration database is currently done by the CLU personnel only.