/elevation/at-many-points

Click to copy

Returns elevations for up to 100 input coordinates.

Returns elevations in meters at given longitudes and latitudes within the WGS84 coordinate system.

If the distance between the furthest West and furthest East coordinate exceeds 50km, the service will return a 400 HTTP response as the distance between these points is too large.

If the distance between the furthest North and furthest South coordinate exceeds 50km, the service will return a 400 HTTP response as the distance between these points is too large.

By default the elevation is measured with respect to the Earth's mean sea level. It takes into account the local variations in gravity and provides a consistent vertical reference.

If the relativeTo parameter in the body is set to ellipsoid, the elevation will be measured with respect to the ellipsoid. This is a mathematical model that approximates the shape of the Earth. It does not consider local variations in gravity and is commonly used in GPS positioning.

Note: You cannot permanently store elevations. Please see the Terms of use.

The Post Body is a JSON structure which captures all of the following parameters for fetching elevations for multiple coordinates.

coordinates

  • (Required) Array of (longitude, latitude) pairs in the WGS84 spatial reference. Maximum size of 100 coordinates.

f

  • (Optional) Case-sensitive parameter to specify the format in which responses are given. Can either be json or pjson.

relativeTo

  • (Optional) The reference position (datum) from which to measure elevation. The valid values are:

    • meanSeaLevel: The elevation above or below the WGS84 geoid reference surface, which is approximately the mean sea level. It takes into account the local variations in gravity and provides a consistent vertical reference.
    • ellipsoid: Ellipsoidal height is measured with respect to an ellipsoid, which is a mathematical model that approximates the shape of the Earth. It does not consider local variations in gravity and is commonly used in GPS positioning.

token

  • (Optional) The authentication token, used to access the elevation service. Alternatively, you can supply a token in the request header with either the Authorization or X-Esri-Authorization key, using the "Bearer" scheme.

Body parameter

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
{
  "token": "My token",
  "relativeTo": "meanSeaLevel",
  "f": "json",
  "coordinates": [
    [
      [
        31.134167,
        29.979167
      ],
      [
        31.130833,
        29.976111
      ],
      [
        31.128333,
        29.9725
      ]
    ]
  ]
}

Examples

Request

Use dark colors for code blocksCopy
1
2
3
4
5
# You can also use wget
curl -X POST https://elevation-api.arcgis.com/arcgis/rest/services/elevation-service/beta/elevation/at-many-points \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: API_KEY'

Response

Response to a request for the elevations at specified points.

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
{
  "elevationInfo": {
    "relativeTo": "meanSeaLevel"
  },
  "result": {
    "points": [
      {
        "spatialReference": {
          "wkid": 4326
        },
        "x": 31.134167,
        "y": 29.979167,
        "z": 82
      },
      {
        "spatialReference": {
          "wkid": 4326
        },
        "x": 31.130833,
        "y": 29.976111,
        "z": 90
      },
      {
        "spatialReference": {
          "wkid": 4326
        },
        "x": 31.128333,
        "y": 29.9725,
        "z": 74
      }
    ]
  }
}
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
{
  "elevationInfo": {
    "relativeTo": "ellipsoid"
  },
  "result": {
    "points": [
      {
        "spatialReference": {
          "wkid": 4326
        },
        "x": 116.5655434,
        "y": 40.4334671,
        "z": 483
      },
      {
        "spatialReference": {
          "wkid": 4326
        },
        "x": 116.5642703,
        "y": 40.4331226,
        "z": 502
      },
      {
        "spatialReference": {
          "wkid": 4326
        },
        "x": 116.5646503,
        "y": 40.4378045,
        "z": 452
      },
      {
        "spatialReference": {
          "wkid": 4326
        },
        "x": 116.5650703,
        "y": 40.4404094,
        "z": 482
      },
      {
        "spatialReference": {
          "wkid": 4326
        },
        "x": 116.5642957,
        "y": 40.4408222,
        "z": 495
      },
      {
        "spatialReference": {
          "wkid": 4326
        },
        "x": 116.5697131,
        "y": 40.4324535,
        "z": 437
      }
    ]
  }
}

400 Response

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
{
  "error": {
    "code": 400,
    "message": "string",
    "details": [
      "string"
    ],
    "restInfoUrl": "https://elevation-api.arcgis.com/arcgis/rest/info"
  }
}
StatusMeaningDescriptionSchema

200

OK

Response to a request for the elevations at specified points.

Inline

400

Bad Request

Invalid query parameters / Incorrect portal item type.

Error

401

Unauthorized

Authentication Error. The API key or token is missing, invalid or expired.

Error

403

Forbidden

The requested resource cannot be accessed because of incorrect sharing permissions.

Error

5XX

Unknown

An error occurred on the server.

Error

Response details

Status Code 200

NameTypeRequiredRestrictionsDescription

elevationInfo

object

none

A structure containing human readable metadata about the specified point.

relativeTo

string

none

The reference position (datum) from which to measure elevation. The valid values are:

  • meanSeaLevel: The elevation above or below the WGS84 geoid reference surface, which is approximately the mean sea level. It takes into account the local variations in gravity and provides a consistent vertical reference.
  • ellipsoid: Ellipsoidal height is measured with respect to an ellipsoid, which is a mathematical model that approximates the shape of the Earth. It does not consider local variations in gravity and is commonly used in GPS positioning.

result

object

none

A structure containing a collection of points which contain elevation values (defined as Z).

points

none

A geometry point referring to a location on a map.

spatialReference

object

none

The spatial reference system the point is relative to.

wkid

number

none

The Well-Known ID (WKID) value of the spatial reference.

x

number

none

The X coordinate which is measured along the east/west axis.

y

number

none

The Y coordinate which is measured along the north/south axis.

z

number

none

The Z coordinate represents the vertical position of a point above or below a reference level, such as sea level (in meters, rounded to the nearest meter).

Enumerated Values

relativeTo
meanSeaLevel
Click to copy
ellipsoid
Click to copy

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.