{"skill":{"slug":"amap","displayName":"amap","summary":"使用高德地图Web服务API进行地点搜索、天气查询和路线规划。","description":"---\nname: amap\ndescription: 使用高德地图Web服务API进行地点搜索、天气查询和路线规划。\nhomepage: https://lbs.amap.com/\nmetadata: {\"clawdbot\":{\"emoji\":\"🗺️\",\"requires\":{\"bins\":[\"curl\"]},\"primaryEnv\":\"AMAP_KEY\"}}\n---\n\n# 高德地图 (Amap)\n\n本技能使用高德地图 Web 服务 API 提供丰富的地理位置服务。\n\n**重要：** 使用本技能前，你必须在高德开放平台申请一个 Web 服务 API Key，并将其设置为环境变量 `AMAP_KEY`。\n\n```bash\nexport AMAP_KEY=\"你的Web服务API Key\"\n```\n\nClawdbot 会自动读取这个环境变量来调用 API。\n\n## 何时使用 (触发条件)\n\n当用户提出以下类型的请求时，应优先使用本技能：\n- \"帮我查一下[城市]的天气\"\n- \"搜索[地点]附近的[东西]\"\n- \"查找[关键词]的位置\"\n- \"从[A]到[B]怎么走？\"\n- \"查询[地址]的经纬度\"\n- \"这个坐标[经度,纬度]是哪里？\"\n\n## 核心功能与用法\n\n### 1. 天气查询\n\n用于查询指定城市的实时天气或天气预报。\n\n**注意：** API 需要城市的 `adcode`。如果不知道 adcode，可以先通过 **行政区划查询** 功能获取。\n\n#### 查询实时天气\n```bash\n# 将 [城市adcode] 替换为实际的行政区编码, 例如北京是 110000\ncurl \"https://restapi.amap.com/v3/weather/weatherInfo?key=$AMAP_KEY&city=[城市adcode]&extensions=base\"\n```\n\n#### 查询天气预报\n```bash\n# 将 [城市adcode] 替换为实际的行政区编码\ncurl \"https://restapi.amap.com/v3/weather/weatherInfo?key=$AMAP_KEY&city=[城市adcode]&extensions=all\"\n```\n\n### 2. 地点搜索 (POI)\n\n用于根据关键字在指定城市搜索地点信息。\n\n```bash\n# 将 [关键词] 和 [城市] 替换为用户提供的内容\ncurl \"https://restapi.amap.com/v3/place/text?key=$AMAP_KEY&keywords=[关键词]&city=[城市]\"\n```\n\n### 3. 驾车路径规划\n\n用于规划两个地点之间的驾车路线。\n\n**注意：** API 需要起终点的经纬度坐标。如果用户提供的是地址，需要先通过 **地理编码** 功能将地址转换为坐标。\n\n```bash\n# 将 [起点经纬度] 和 [终点经纬度] 替换为实际坐标，格式为 \"经度,纬度\"\ncurl \"https://restapi.amap.com/v3/direction/driving?key=$AMAP_KEY&origin=[起点经纬度]&destination=[终点经纬度]\"\n```\n\n### 4. 地理编码 (地址 → 坐标)\n\n将结构化的地址信息转换为经纬度坐标。\n\n```bash\n# 将 [地址] 替换为用户提供的地址\ncurl \"https://restapi.amap.com/v3/geocode/geo?key=$AMAP_KEY&address=[地址]\"\n```\n\n### 5. 逆地理编码 (坐标 → 地址)\n\n将经纬度坐标转换为结构化的地址信息。\n\n```bash\n# 将 [经纬度] 替换为实际坐标，格式为 \"经度,纬度\"\ncurl \"https://restapi.amap.com/v3/geocode/regeo?key=$AMAP_KEY&location=[经纬度]\"\n```\n\n### 6. 行政区划查询 (获取 adcode)\n\n用于查询省、市、区、街道的行政区划信息，包括 `adcode` 和边界。\n\n```bash\n# 将 [关键词] 替换为城市或区域名称，例如 \"北京市\"\ncurl \"https://restapi.amap.com/v3/config/district?key=$AMAP_KEY&keywords=[关键词]&subdistrict=0\"\n```\n","topics":["天气查询","天气"],"tags":{"latest":"1.0.0"},"stats":{"comments":0,"downloads":5440,"installsAllTime":204,"installsCurrent":68,"stars":10,"versions":1},"createdAt":1769696427545,"updatedAt":1778485868789},"latestVersion":{"version":"1.0.0","createdAt":1769696427545,"changelog":"- Initial release of the amap skill.\n- Provides location search, weather queries, and route planning using Gaode (Amap) Web Service API.\n- Requires users to set the AMAP_KEY environment variable with their API Key.\n- Supports real-time weather, weather forecast, POI search, route planning, geocoding, reverse geocoding, and administrative code lookup.","license":null},"metadata":{"setup":[],"os":null,"systems":null},"owner":{"handle":"dboy233","userId":"s1726kxwtxnd6arjmhzsf9e19n885n04","displayName":"Dboy233","image":"https://avatars.githubusercontent.com/u/37604230?v=4"},"moderation":null}