# Mapsgl

> Mapsgl is an open-source agent skill for maps and travel. Guides an agent through building Xweather MapsGL weather map layers in web apps. It is available on Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose.

- **Kind:** Skill
- **Pricing:** Open source
- **Platforms:** Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf, Goose
- **Website:** https://github.com/vaisala-xweather/xweather-agent-skills/tree/main/plugins/xweather/skills/mapsgl
- **Repository:** https://github.com/vaisala-xweather/xweather-agent-skills
- **GitHub stars:** 8
- **License:** MIT
- **Skill name:** mapsgl
- **Collection:** https://github.com/vaisala-xweather/xweather-agent-skills
- **Categories:** [maps and travel](https://ai-powered.com/categories/maps-and-travel), [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-12-01

## About

This skill covers the Xweather MapsGL JavaScript SDK, which renders weather and custom map data in WebGL on top of Mapbox GL, MapLibre GL, Google Maps or Leaflet. It walks the agent through initializing a map controller, adding, styling, filtering, masking and animating built-in weather layers, and attaching custom vector, raster, GeoJSON or encoded sources.

The guidance also covers how usage is metered in five-minute clock-aligned sessions, so the agent can explain costs and avoid needless layer teardown. It includes rules for Xweather attribution and for version selection, pointing the agent at the official releases endpoint rather than a pinned or npm-reported version.

Using the skill requires an Xweather account with Weather API and Maps access, plus a client id and secret, and a key or token for the chosen map provider. Example code defaults to a single HTML file with CDN includes, and npm or framework code is produced only when requested.

## When your agent uses it

> This skill should be used when working with the Xweather MapsGL JavaScript SDK for the web (@xweather/mapsgl) — setting up a MapsGL map controller for Mapbox GL, MapLibre GL, Google Maps, or Leaflet, and adding, removing, styling, filtering, masking, or animating MapsGL weather layers and custom data layers. Use it whenever a task mentions MapsGL, aerisweather.mapsgl, addWeatherLayer, weather map layers, or client-side WebGL weather rendering. Also use it for questions about how MapsGL usage or cost is measured — sessions, the 5-minute clock intervals, the 150x access multiplier, or how many accesses a MapsGL map consumes. Also covers Xweather's attribution requirement — the 'Powered by Vaisala Xweather' credit and logo rules that apply wherever Xweather data or imagery is displayed.

## What it can access

From a static check of the files on GitHub; nothing was run.

- [Instructions only, no scripts](https://github.com/vaisala-xweather/xweather-agent-skills/tree/HEAD/plugins/xweather/skills/mapsgl)
- [License: MIT](https://github.com/vaisala-xweather/xweather-agent-skills/tree/HEAD/plugins/xweather/skills/mapsgl)

## Features

- **Map controller setup:** Covers creating a controller for Mapbox GL, MapLibre GL, Google Maps or Leaflet and waiting for load before adding layers.
- **Built-in weather layers:** Explains adding, removing, hiding and inspecting weather layers by their built-in codes and their composite sub-layers.
- **Styling and expressions:** Provides paint objects, color scales, data-driven expressions and filters for weather and custom layers.
- **Timeline animation:** Describes driving time-based playback across animated layers and seeking to specific timestamps within a range.
- **Legends and data inspection:** Shows how to add legend controls and click or hover inspectors, and keep legends consistent with custom colors.
- **Layer ordering:** Describes opt-in slots and stack ranks for controlling where weather layers sit relative to basemap labels.
- **Session-based usage model:** Explains how MapsGL usage is counted in five-minute sessions and how to reason about access costs.

## Good for

- Build a single-file HTML page that shows a radar layer over a Mapbox map
- Add a temperature layer with a custom color scale and a matching legend
- Animate wind particles over the last three hours on a map
- Jump the timeline to a specific timestamp on an existing weather map
- Estimate how many accesses a short map visit will consume
- Place weather layers beneath road labels using slot ordering

## Install

### Claude Code

This skill ships in the `xweather` plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

```sh
/plugin marketplace add vaisala-xweather/xweather-agent-skills
/plugin install xweather@vaisala-xweather
```

Or copy only this skill to `~/.claude/skills/mapsgl`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/vaisala-xweather/xweather-agent-skills.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/mapsgl &&
cp -R "$tmp/plugins/xweather/skills/mapsgl" ~/.claude/skills/mapsgl &&
rm -rf "$tmp"
```

For one project only, put the folder in `.claude/skills/mapsgl` inside it instead.

### Codex

Copy the skill folder to `~/.agents/skills/mapsgl` to use it in every repository:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/vaisala-xweather/xweather-agent-skills.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/mapsgl &&
cp -R "$tmp/plugins/xweather/skills/mapsgl" ~/.agents/skills/mapsgl &&
rm -rf "$tmp"
```

For one repository only, put the folder in `.agents/skills/mapsgl` inside it instead.

### Cursor

Copy the skill folder to `~/.cursor/skills/mapsgl` to use it in every project:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/vaisala-xweather/xweather-agent-skills.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/mapsgl &&
cp -R "$tmp/plugins/xweather/skills/mapsgl" ~/.cursor/skills/mapsgl &&
rm -rf "$tmp"
```

For one project only, put the folder in `.cursor/skills/mapsgl` inside it instead.

### Gemini CLI

Run in a terminal (add `--scope workspace` to install it for the current workspace only):

```sh
gemini skills install https://github.com/vaisala-xweather/xweather-agent-skills.git --path plugins/xweather/skills/mapsgl
```

Or copy the folder to `~/.gemini/skills/mapsgl` yourself.

### VS Code

For GitHub Copilot in VS Code, copy the skill folder to `~/.copilot/skills/mapsgl`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/vaisala-xweather/xweather-agent-skills.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/mapsgl &&
cp -R "$tmp/plugins/xweather/skills/mapsgl" ~/.copilot/skills/mapsgl &&
rm -rf "$tmp"
```

For one project only, put the folder in `.github/skills/mapsgl` inside it instead.

### Other agents

Get the folder:

```sh
git clone --depth 1 https://github.com/vaisala-xweather/xweather-agent-skills.git
```

Then copy `xweather-agent-skills/plugins/xweather/skills/mapsgl` into your agent's skills folder as `mapsgl`. Agents that support SKILL.md read one folder per skill.

## FAQ

### What credentials does the MapsGL JavaScript SDK need?

It needs Xweather account keys (client id and secret) with Weather API and Maps access, plus the map provider's own key or token, such as a Mapbox access token or a Google Maps API key.

### How is MapsGL usage measured?

Usage is counted in sessions of up to five minutes aligned to the wall clock. One session equals 150 accesses on a Weather API and Maps subscription, and adding or toggling layers inside a session costs nothing extra.

### Why might a timeline date not display?

The timeline's goToDate only seeks within the current startDate to endDate range and does not widen it, so the range must be set to include the target date first.

### Can I use the SDK in a React or npm project?

Yes. The skill describes an npm and ES module translation, which is used when the user asks for it or is already working in a bundled project.

### How do I install Mapsgl in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/mapsgl to use it in all your projects, or to .claude/skills/mapsgl in one project. Or install the xweather plugin, which includes it: /plugin marketplace add vaisala-xweather/xweather-agent-skills, then /plugin install xweather@vaisala-xweather.

### Does Mapsgl run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

### Which AI agents can use Mapsgl?

Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose. Each reads skills in the SKILL.md format from its own folder; the install steps on this page list them.

### What are the best alternatives to Mapsgl?

The closest alternatives to Mapsgl are Mapsgl android, Mapsgl apple, Raster maps, Axiom location and Game engine.

## Where this comes from

- Description: from the skill's own SKILL.md.

## Alternatives

- [Mapsgl android](https://ai-powered.com/skills/mapsgl-android): Mapsgl android is an open-source agent skill for maps and travel.
- [Mapsgl apple](https://ai-powered.com/skills/mapsgl-apple): Mapsgl apple is an open-source agent skill for maps and travel.
- [Raster maps](https://ai-powered.com/skills/raster-maps): Raster maps is an open-source agent skill for maps and travel.
- [Axiom location](https://ai-powered.com/skills/axiom-location-charleswiltgen): Axiom location is an open-source agent skill for maps and travel.
- [Game engine](https://ai-powered.com/skills/game-engine): Game engine is an open-source agent skill for design and media.
- [Globestudio](https://ai-powered.com/skills/globestudio-github): Globestudio is an open-source agent skill for design and media.
- [Threejs scene setup](https://ai-powered.com/skills/threejs-scene-setup): Threejs scene setup is an open-source agent skill for developer tools.
- [Threejs](https://ai-powered.com/skills/threejs): Threejs is an open-source agent skill for design and media.

---
Source: https://ai-powered.com/skills/mapsgl
