土壌図取得API(縮尺5万分の1):GetDistance
- 公開日
- 更新日 2025-03-17
利用条件
ベーシックAPI(申込不要)
概要
API名称
5_1SoilMap
カテゴリー
説明
縮尺5万分の1農耕地包括土壌図
添付ファイル
ー
データの更新頻度
元データの更新が発生した場合
リクエスト
新URL
New!
https://api.wagri2.net/naro-api/maps/5_1SoilMap/GetDistance?Latitude={Latitude}&Longitude={Longitude}&Distance={Distance}
旧URL(2025年度末で終了予定)
https://api.wagri.net/API/Public/5_1SoilMap/GetDistance?Latitude={Latitude}&Longitude={Longitude}&Distance={Distance}
説明
指定経度緯度から、指定範囲メートル内のデータを取得する。
HTTPメソッド
GET
パラメータ
URLデータ定義
農耕地包括土壌図取得:緯度経度指定
| 名称 | 値 | 型 | 値の説明 |
|---|---|---|---|
| Distance | 距離(単位メートル) | number | |
| Latitude | 緯度 | number | Required |
| Longitude | 経度 | number | Required |
新呼出例
New!
https://api.wagri2.net/naro-api/maps/5_1SoilMap/GetDistance?Latitude=35.83764124&Longitude=139.19981619&Distance=200
旧呼出例(2025年度末で終了予定)
GET https://api.wagri.net/API/Public/5_1SoilMap/GetDistance?Latitude={Latitude}&Longitude={Longitude}&Distance={Distance}
header X-Authorization:{アクセストークン}
レスポンス
レイアウト
レスポンスデータ定義
縮尺5万分の1農耕地包括土壌図返却用
| 名称 | 値 | 型 | 値の説明 |
|---|---|---|---|
| PrefectureCode | 県コード | string | |
| MunicipalityCode | 市区町村コード | string | |
| LandUse | 地目区分 | string, null | |
| InclusivenessSoilSmallName | 包括統群土壌名 | string, null | |
| SoilLargeCode | 群コード | string, null | |
| SoilMiddleCode | 亜群コード | string, null | |
| SoilSmallCode | 統群コード | string, null | |
| Prefecture | 県 | string, null | |
| CityTown | 市町 | string, null | |
| County | 郡 | string, null | |
| Municipality | 市区町村 | string, null | |
| Polygons | ポリゴン | array of Polygons |
レスポンス例
サンプルコードでのレスポンス(抜粋)
[
{
"MunicipalityCode": "43206",
"LandUse": "田",
"InclusivenessSoilSmallName": "細粒質普通低地水田土",
"SoilLargeCode": "F1",
"SoilMiddleCode": "F1z1",
"SoilSmallCode": "F1z1t1",
"Prefecture": "熊本県",
"CityTown": null,
"County": null,
"Municipality": "玉名市",
"Polygons": [
{
"Coordinates": [
{
"Latitude": "32.873322652918226",
"Longitude": "130.55538717647718"
},
{
"Latitude": "32.872570709071042",
"Longitude": "130.55510987771882"
},
{
"Latitude": "32.8727325726502",
"Longitude": "130.55455907084468"
},
{
"Latitude": "32.873072027152489",
"Longitude": "130.55364905406071"
},
{
"Latitude": "32.873108134932636",
"Longitude": "130.55365955904159"
},
{
"Latitude": "32.873139072510284",
"Longitude": "130.55336369917558"
},
{
"Latitude": "32.873779936594929",
"Longitude": "130.55361361537615"
},
{
"Latitude": "32.873322652918226",
"Longitude": "130.55538717647718"
}
]
}
]
},
ステータスコード
| コード | 名称 | 値の説明 |
|---|---|---|
| 200 | OK | リクエストが成功しました。 |
| 400 | Bad Request | リクエストが不正です。 |
| 401 | Unauthorized | 認証情報が不正です。 |
| 403 | Forbidden | リソースのアクセスが禁止されています。 |
| 404 | Not Found | リソースが見つかりませんでした。 |
| 500 | Internal Server Error | サーバー内部でエラーが発生しました。 |
サンプルソースコード
プログラム記述例(WAGRI共通)
import requests
url = "https://api.wagri.net/API/Public/AgriculturalLand/SearchByCityCode"
payload = {
'CityCode': '432041'
}
headers = {
'X-Authorization': 'アクセストークン',
}
response = requests.get(url, headers=headers, params=payload)
print(response.text)
プログラム記述例(個別API)
Python(requestsモジュール)でのサンプルコード
パラメータ例:Latitude=32.87245 Longitude=130.55100 Distance=300
import requests
url = "https://api.wagri.net/API/Public/5_1SoilMap/GetDistance"
payload = {
'Latitude': '32.87245',
'Longitude': '130.55100',
'Distance': '300',
}
headers = {
'X-Authorization': 'アクセストークン',
}
response = requests.get(url, headers=headers, params=payload)
print(response.text)

