Elevation API の概要
コレクションでコンテンツを整理
必要に応じて、コンテンツの保存と分類を行います。
Elevation API は、Google による調査で
地球上の場所、パスに沿ってサンプリングされた高度データなどです。
Elevation API を使用する理由
Elevation API を使用すると、
高度に敏感なアクティビティ、ポジショニング アプリケーション、低測量のお客様に利用
ルートに沿った高度および高度の変化を含むアプリケーションを開発できます。たとえば
標高差のデータを提供して、スポーツ アプリケーションの機能を強化して、
ハイキング、サイクリング、スキューバダイビングなど、
Elevation API でできること
Elevation API を使用すると、高度データを
使用できます。例:
- 特定の場所の高度を取得する。
- ルート沿いまたは 2 つの地点の標高の差を計算する
あります。
Elevation API の仕組み
Elevation API は、緯度と経度の座標を含むエンコードされた URL としてリクエストを受け入れます。
個別の場所として指定することも、経路上の一連の場所として指定することもできます。このリクエスト
たとえば、コロラド州デンバーの中心部の高度をクエリし、JSON 形式で戻り値を指定します。
https://maps.googleapis.com/maps/api/elevation/json
?locations=39.7391536%2C-104.9847034
&key=YOUR_API_KEY
このサービスでは、指定された座標の高度が取得されます。また、
各地点の標高に基づいて、各地点の 4 つの地点の平均
高度データを提供している最寄りの場所はありませんそして最後に、
決定します。
リソース
次の表に、
Elevation API で返されるデータを表示します。
データリソース |
返されるデータ |
戻り値の形式 |
緯度と経度の座標
データは、1 つ以上の場所のセットとして、または経路上の一連のデータとして指定できます。マイページ
エンコードされた座標も指定できます。最大 512 個の座標を渡します。
|
Elevation API は、相対値メートル単位の高度を提供します。
ローカル平均海面(LMSL)に換算します。高度は正の値で返すことができます
または負の値になります。
- 正の値は LMSL より上の位置を示します。
たとえば地表や高地の湖の底などです
- 負の値は LMSL を下回っていることを示します。
海底や海底に位置しています
- [解像度] は、データポイントと対象物の間の距離を示します。
高度(メートル単位)
|
|
Elevation API の使用方法
1 |
設定する。 |
まずは
Google Cloud プロジェクト
設定を完了します。
説明します。 |
2 |
高度リクエストを試す |
API キーを取得したら、
ダウンロードします。リクエストの例をご覧ください。
をご覧ください。
|
3 |
より複雑なリクエストを作成する |
プロジェクトを設定したら、住所とともに位置情報を提供するリクエストをお試しください。
あります。パスの指定をご覧ください。
をご覧ください。
|
4 |
回答の基本を理解する |
高度データのレスポンスを確認して、アプリで高度データを使用する準備をします。詳しくは、
高度リクエストのレスポンス
をご覧ください。
|
5 |
高度データを独自のアプリに組み込む |
高度データを使用して、スポーツ用のアプリなど、位置情報を利用したアプリの機能を強化できます
使用したりできます
|
利用可能なクライアント ライブラリ
この API を
次のいずれかのクライアント ライブラリを使用できます。
Google マップ用の Java クライアント、Python クライアント、Go クライアント、Node.js クライアント
サービスはコミュニティでサポートされているクライアント ライブラリで、
Apache 2.0 ライセンス。
GitHub からダウンロードしてください。GitHub には、インストール手順やサンプルコードも用意されています。
次のステップ
特に記載のない限り、このページのコンテンツはクリエイティブ・コモンズの表示 4.0 ライセンスにより使用許諾されます。コードサンプルは Apache 2.0 ライセンスにより使用許諾されます。詳しくは、Google Developers サイトのポリシーをご覧ください。Java は Oracle および関連会社の登録商標です。
最終更新日 2025-08-31 UTC。
[null,null,["最終更新日 2025-08-31 UTC。"],[[["\u003cp\u003eThe Elevation API provides elevation data for locations on Earth, enabling applications with elevation-sensitive features.\u003c/p\u003e\n"],["\u003cp\u003eYou can retrieve elevation for single points or calculate elevation differences along paths, useful for activities like hiking or biking.\u003c/p\u003e\n"],["\u003cp\u003eThe API accepts latitude/longitude coordinates and returns elevation data in meters relative to local mean sea level, with resolution information.\u003c/p\u003e\n"],["\u003cp\u003eDevelopers can access the Elevation API through various client libraries (Java, Python, Go, Node.js) and integrate it into their applications.\u003c/p\u003e\n"],["\u003cp\u003eTo get started, set up a Google Cloud project, try sample requests, and explore the documentation for detailed usage instructions.\u003c/p\u003e\n"]]],[],null,["The Elevation API is a service that returns elevation data for\na location on the earth, or sampled elevation data along paths.\n\nWhy use the Elevation API\n\nWith the Elevation API, you can develop applications to support your\ncustomers with elevation-sensitive activities, positioning applications, or low-surveying\napplications that include elevations and elevation changes along routes. For example,\nyou can provide elevation gain and loss data to enhance a sports application for activities such\nas hiking, biking, or scuba diving.\n\nWhat you can do with the Elevation API\n\nWith the Elevation API, you can include elevation data in your\napplications or on a map. For example:\n\n- Get the **elevation** for a particular place.\n- Calculate the **differences** in elevation along a route or between two points.\n\nHow the Elevation API works The Elevation API accepts a request as an encoded URL with latitude/longitude coordinates provided as either discrete locations, or as a series of locations along a path. This request, for example, queries elevation for the center of Denver, Colorado, specifying a return in JSON format. \n\n```scdoc\n https://maps.googleapis.com/maps/api/elevation/json\n ?locations=39.7391536%2C-104.9847034\n &key=YOUR_API_KEY\n```\n\nThe service derives the elevation for the provided coordinates. It also interpolates\nelevation for a location without elevation, providing an average returned from the four\nnearest locations that do provide elevation data. Finally, it determines the overall\nresolution for the location.\n\nResources\n\nThe following table summarizes the resources available through the\nElevation API along with the data it returns.\n\n| Data resources | Data returned | Return format |\n|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------|\n| **Latitude/longitude coordinates** You can provide data as a set of one or more locations, or as a series along a path. You can also provide encoded coordinates. Pass up to 512 coordinates. | The Elevation API provides **elevation in meters** relative to the **local mean sea level** (LMSL). Elevation can be returned as positive or negative values as indicated below: - **Positive values** indicate locations above LMSL, including surface locations or the bottom of high-altitude lakes. - **Negative values** indicate locations that are below LMSL, including locations on the surface or the ocean floor. - **Resolution** indicates the distance between the data point and the elevation, in meters. | - JSON - XML |\n\nHow to use the Elevation API\n\n|---|---------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| 1 | **Get set up.** | Start with [Set up your Google Cloud project](/maps/documentation/elevation/cloud-setup) and complete the setup instructions that follow. |\n| 2 | **Try an elevation request** | Once you have an API key, you can start testing out the Elevation API directly from your browser. See [Sample requests](/maps/documentation/elevation/start#sample-request) in the *Getting started* guide for details. |\n| 3 | **Compose a more complex request** | Once you are set up with a project, try a request that supplies a location data along a path. See [Specifying paths](/maps/documentation/elevation/requests-elevation#Paths) for details. |\n| 4 | **Understand response basics** | Explore the elevation data responses to prepare to use elevation data for your app. See [Elevation responses](/maps/documentation/elevation/requests-elevation#ElevationResponses) for details. |\n| 5 | **Incorporate elevation data into your own app!** | You can use elevation data to enhance location-based apps, such as apps for sports activities or for survey data. |\n\nAvailable client libraries\n\nCall this API in the language of\nyour choice through one of the following client libraries:\n\n- [Java\n Client for Google Maps Services](https://github.com/googlemaps/google-maps-services-java)\n- [Python\n Client for Google Maps Services](https://github.com/googlemaps/google-maps-services-python)\n- [Go Client\n for Google Maps Services](https://github.com/googlemaps/google-maps-services-go)\n- [Node.js\n Client for Google Maps Services](https://github.com/googlemaps/google-maps-services-js)\n\nThe Java Client, Python Client, Go Client and Node.js Client for Google Maps\nServices are community-supported client libraries, open sourced under the\n[Apache 2.0 License](http://www.apache.org/licenses/LICENSE-2.0).\nDownload them from GitHub, where you can also find installation instructions and sample code.\n\nWhat's next\n\n- **Start using the Elevation API** : Go to [Set up your\n Google Cloud project](/maps/documentation/elevation/cloud-setup).\n- **Try getting path-based elevation data** : Go to [Specifying paths](/maps/documentation/elevation/requests-elevation#Paths)\n- **Follow best practices** : Go to [Web Service\n Best Practices](/maps/documentation/elevation/web-service-best-practices)."]]