Terrain Elevation Data API
The Terrain Elevation Data API (TED API) provides terrain elevation data for geographic locations specified by latitude and longitude coordinates. Elevation values are retrieved from NASA's ASTER Global Digital Elevation Model (GDEM), Version 3, which provides global land elevation data at a spatial resolution of 1 arc-second (approximately 30 meters). The API supports multiple coordinate input formats and response formats, making it easy to integrate elevation data into applications written in different programming languages. Elevation values are referenced to the EGM96 geoid. The dataset covers latitudes between 83° S and 83° N.
API Endpoint
Endpoint URL:
https://ted-api.larionov.site/HTTP method: GET
The API accepts the following query parameters:
| Parameter | Required | Description | Accepted value | Default |
|---|---|---|---|---|
| lon | Yes | Longitude of the requested location. | Integer or floating-point number | — |
| lat | Yes | Latitude of the requested location. | Integer or floating-point number | — |
| cfm | No | Input coordinate format. | degree, arcsec | degree |
| ofm | No | Response format. | json, xml, csv, binary, html, text | json |
Request URL syntax:
https://ted-api.larionov.site/?lon={longitude}&lat={latitude}&cfm={coordinate_format}&ofm={output_format}The parameters can be specified in any order. The cfm and ofm parameters are optional and can be omitted when their default values are suitable.
Response examples
{
"elevation": {
"feet": 20,
"meters": 6
},
"latitude": {
"arcsec": 200171,
"degree": 55.60305555555556,
"string": "55° 36' 11\" N"
},
"longitude": {
"arcsec": 44521,
"degree": 12.366944444444444,
"string": "12° 22' 1\" E"
}
}<?xml version="1.0" encoding="utf-8"?>
<ted>
<elevation>
<feet>20</feet>
<meters>6</meters>
</elevation>
<latitude>
<arcsec>200171</arcsec>
<degree>55.60305555555556</degree>
<string>55° 36' 11" N</string>
</latitude>
<longitude>
<arcsec>44521</arcsec>
<degree>12.366944444444444</degree>
<string>12° 22' 1" E</string>
</longitude>
</ted>12.366944444444,55.603055555556,6 // longitude,latitude,elevation01 DF 45 41 // longitude as 32-bit float (LE)
87 69 5E 42 // latitude as 32-bit float (LE)
06 00 // elevation as signed 16-bit integer (LE)Longitude 12° 22' 1" E
Latitude 55° 36' 11" N
Elevation 20 m / 6 ft