AI Agent Hub
Back to skills
Tencent Maps Mini Program Development icon

Tencent Maps Mini Program Development

Development Updated 2026.08.30

Paste the following prompt into your AI chat to install this skill:

Please follow https://skillhub.cn/install/skillhub.md and install @tencent-adm/tencentmap-miniprogram-skill.

About this skill

Problem

WeChat Mini Program map work often stalls around component attributes, MapContext behavior, location permissions, Tencent Location Services keys, and visualization layer setup. When documentation is scattered, developers may guess marker, polyline, clustering, coordinate conversion, search, or routing behavior, and miss prerequisites such as subkey, layerId, and APPID authorization.

How it works

This skill targets WeChat Mini Program maps and provides API references for map components, MapContext, location services, and LBS backend services. It routes requests to the relevant references/ documents and checks assets/examples/ projects such as minicode-location, minicode-marker, and minicode-markerCluster.

  • Map features: covers longitude, latitude, scale, rotate, skew, marker, polyline, polygon, circle, clustering, custom callouts, collision detection, and map controls.
  • MapContext: covers creating context, moving the view, reading region and scale, restricting boundaries, including points, marker animation, trajectory playback, overlays, custom layers, and coordinate conversion.
  • Location services: covers wx.getLocation, fuzzy location, chooseLocation, choosePoi, openLocation, foreground/background location updates, and error listeners.
  • LBS backend: covers POI search, input suggestions, geocoding, reverse geocoding, direction planning, distance calculation, and administrative areas.

The workflow first identifies the feature type, then decides whether Tencent Location Services APIs are needed. When backend keys are required, it handles user-provided keys, saved keys, and temporary keys in order. For visual layers, it asks for a real layerId and confirms subkey binding and Mini Program APPID authorization.

Boundaries

It fits WeChat Mini Program map display, location, markers, routing, search, and map control. Coordinates use GCJ-02, so WGS-84 points need conversion. Location APIs require permission declarations, and wx.getLocation has frequency limits. Commercial use may require authorization.

Use Cases

  • Integrate a map component in a WeChat Mini Program and configure coordinates, scale, and markers.
  • Use MapContext to move the viewport, limit boundaries, and include multiple coordinate points.
  • Call Tencent Location Services APIs for nearby POI search, direction planning, and geocoding.
  • Find examples for location, markers, and marker clustering, then handle keys and permission notes.

Best For

  • Frontend engineers owning WeChat Mini Program map pages need to verify MapContext parameters and events.
  • Client developers integrating Tencent Location Services need to handle keys, POI search, and routing.
  • Product engineers working on location features need to evaluate continuous location, fuzzy location, and permissions.
  • Engineers maintaining map sample projects need to reuse location, marker, and clustering examples.