NOEF Logo

NØ-Iskart API Documentation

This API uses data gathered and digitized by Nordre Øyeren Bird Observatory noef.no, and has been developed with funding from Glommen og Laagens brukseierforening GLB and Consul Haldor Virik's foundation. The data from this API is also visualized on our graphic page together with ornithological and hydrological data.

How to Cite

The data on this site is free to use under CC BY 4.0

Nordre Øyeren Bird Observatory (2024). NØ-Iskart: Ice Cover Data from Lake Øyeren, Norway (Version 1.0) [Data set]. 
Nordre Øyeren Bird Observatory (2024). NØ-Iskart API. https://noef.no/api/v1/ [API]

Usage Examples

Our server blocks requests without headers. Therefore, headers are mandatory for API access.

cURL Example (with Headers)

curl -X GET "https://noef.no/api/v1/?endpoint=ice-raw-data&startdate=2023-01-01&enddate=2023-12-31&source=satellite" \
-H "User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" \
-H "Accept: application/json" \
-H "Connection: keep-alive"

R Example (with Headers using httr)

library(httr)
library(sf)
library(jsonlite)

url <- "https://noef.no/api/v1/?endpoint=ice-raw-data&startdate=2023-01-01&enddate=2023-12-31"
headers <- add_headers(
  "User-Agent" = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36",
  "Accept" = "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9",
  "Referer" = "https://noef.no",
  "Connection" = "keep-alive"
)
response <- GET(url, headers)
data <- as.data.frame(fromJSON(content(response, "text", encoding = "UTF-8")))

# Get the polygons and merge with ice data
url <- "https://noef.no/api/v1/?endpoint=ice-polygons"
response <- GET(url, headers)
polygons <- st_read(content(response, "text", encoding = "UTF-8"))

# Merge ice data with polygons based on locality id
data_sf <- merge(data, polygons, by.x = "localityid", by.y = "id")

API Endpoints

1. Get Polygons and Locality Names

Endpoint: v1/?endpoint=ice-polygons

Description: Returns a GeoJSON object containing all locality names and their polygons.

GET v1/?endpoint=ice-polygons
{
    "type": "FeatureCollection",
    "features": [
        {
            "id": "123",
            "localityname": "Locality Name",
            "area": "50",
            "geometry": { ... }
        },
        ...
    ]
}

2. Get Total Calculated Ice Percentage

Endpoint: v1/?endpoint=total-icepercentage

Description: Returns the total ice-covered percentage for each observation date. You can filter results by startdate, enddate, and source.

Optional Filters:

Example with filters: v1/?endpoint=total-icepercentage&startdate=2023-01-01&enddate=2023-12-31&source=visual

GET v1/?endpoint=total-icepercentage&startdate=2023-01-01&enddate=2023-12-31&source=visual
[
    {
        "date": "2023-01-15",
        "time": "12:00:00",
        "source": "visual",
        "comment": "compared to satellite data",
        "total_icepercentage": "75.00"
    },
    ...
]

3. Get Raw Ice Cover Data

Endpoint: v1/?endpoint=ice-raw-data

Description: Returns the raw ice cover data from the database for each observation and locality. You can filter results by startdate, enddate, and source.

Optional Filters:

Example with filters: v1/?endpoint=ice-raw-data&startdate=2022-01-01&enddate=2023-12-31&source=satellite&localityid=7

GET v1/?endpoint=ice-raw-data&startdate=2022-01-01&enddate=2023-12-31&source=satellite&localityid=7
[
    {
        "date": "2023-01-15",
        "time": "12:00:00",
        "localityid": "123",
        "localityname": "Locality Name",
        "source": "satellite",
        "icepercentage": "75"
    },
    ...
]