Co-Pilot
Updated a month ago

mcp-devkit-server

Mmapbox
0.0k
mapbox/mcp-devkit-server
78
Agent Score

💡 Summary

A server that connects AI assistants to Mapbox APIs for efficient application development.

🎯 Target Audience

AI developersMapbox application developersData scientists using MapboxProduct managers in techDevOps engineers managing API integrations

🤖 AI Roast:Powerful, but the setup might scare off the impatient.

Security AnalysisMedium Risk

Risk: Medium. Review: shell/CLI command execution; outbound network access (SSRF, data egress); API keys/tokens handling and storage; filesystem read/write scope and path traversal; dependency pinning and supply-chain risk. Run with least privilege and audit before enabling in production.

Mapbox Developer MCP Server

A Model Context Protocol (MCP) server that provides AI assistants with direct access to Mapbox developer APIs. This server enables AI models to interact with Mapbox services, helping developers build Mapbox applications more efficiently.

https://github.com/user-attachments/assets/8b1b8ef2-9fba-4951-bc9a-beaed4f6aff6

Table of Contents

Quick Start

Integration with Developer Tools

Get started by integrating with your preferred AI development environment:

DXT Package Distribution

This MCP server can be packaged as a DXT (Desktop Extension) file for easy distribution and installation. DXT is a standardized format for distributing local MCP servers, similar to browser extensions.

Creating the DXT Package

To create a DXT package:

# Install the DXT CLI tool npm install -g @anthropic-ai/dxt # Build the server first npm run build # Create the DXT package npx @anthropic-ai/dxt pack

This will generate mcp-devkit-server.dxt using the configuration in manifest.json.

The DXT package includes:

  • Pre-built server code (dist/esm/index.js)
  • Server metadata and configuration
  • User configuration schema for the Mapbox access token
  • Automatic environment variable setup

Hosted MCP Endpoint

For quick access, you can use our hosted MCP endpoint:

Endpoint: https://mcp-devkit.mapbox.com/mcp

For detailed setup instructions for different clients and API usage, see the Hosted MCP Server Guide. Note: This guide references the standard MCP endpoint - you'll need to update the endpoint URL to use the devkit endpoint above.

Getting Your Mapbox Access Token

A Mapbox access token is required to use this MCP server.

  1. Sign up for a free Mapbox account at mapbox.com/signup
  2. Navigate to your Account page
  3. Create a new token with the required scopes for your use case

For more information about Mapbox access tokens, see the Mapbox documentation on access tokens.

⚠️ IMPORTANT: Token Privileges Required

The MAPBOX_ACCESS_TOKEN environment variable is required. Each tool requires specific token scopes/privileges to function properly. For example:

  • Reading styles requires styles:read scope
  • Creating styles requires styles:write scope
  • Managing tokens requires tokens:read and tokens:write scopes
  • Accessing feedback requires user-feedback:read scope

Tools

Documentation Tools

get_latest_mapbox_docs_tool - Access the latest official Mapbox documentation directly from the source. This tool fetches comprehensive, up-to-date information about all Mapbox APIs, SDKs, and developer resources from docs.mapbox.com/llms.txt.

Example prompts:

  • "What are the latest Mapbox APIs available for developers?"
  • "Show me all current Mapbox services and SDKs"
  • "I need up-to-date Mapbox documentation for my project"
  • "What mapping solutions does Mapbox offer for my tech stack?"
  • "Give me an overview of Mapbox's navigation and routing capabilities"
  • "Compare Mapbox web SDKs versus mobile SDKs"
  • "What's new in the Mapbox ecosystem?"

📖 See more examples and interactive demo →

Reference Tools

get_reference_tool - Access static Mapbox reference documentation and schemas. This tool provides essential reference information that helps AI assistants understand Mapbox concepts and build correct styles and tokens.

Note: This tool exists as a workaround for Claude Desktop's current limitation with MCP resources. Claude Desktop can see resources (via resources/list) but doesn't automatically call resources/read to fetch their content. This tool provides the same reference data through the tool interface, which Claude Desktop does support. Other MCP clients that fully support the resources protocol can access this data directly as MCP Resources (see Resources section below).

Available References:

  • resource://mapbox-style-layers - Mapbox GL JS style specification reference guide covering all layer types (fill, line, symbol, circle, fill-extrusion) and their properties
  • resource://mapbox-streets-v8-fields - Complete field definitions for all Mapbox Streets v8 source layers, including enumerated values for each field (useful for building filters)
  • resource://mapbox-token-scopes - Comprehensive token scope reference explaining what each scope allows and which scopes are needed for different operations
  • resource://mapbox-layer-type-mapping - Mapping of Mapbox Streets v8 source layers to compatible GL JS layer types, with common usage patterns

Example prompts:

  • "What fields are available for the landuse layer?"
  • "Show me the token scopes reference"
  • "What layer type should I use for roads?"
  • "Get the Streets v8 fields reference"
  • "What scopes do I need to display a map?"

Style Management Tools

Complete set of tools for managing Mapbox styles via the Styles API:

Style Builder Tool - Create and modify Mapbox styles programmatically through conversational prompts

📖 See the Style Builder documentation for detailed usage and examples →

ListStylesTool - List all styles for a Mapbox account

  • Input: limit (optional - max number of styles), start (optional - pagination token)
  • Returns: Array of style metadata with optional pagination info

CreateStyleTool - Create a new Mapbox style

  • Input: name, style (Mapbox style specification)
  • Returns: Created style details with ID

RetrieveStyleTool - Retrieve a specific style by ID

  • Input: styleId
  • Returns: Complete style specification

UpdateStyleTool - Update an existing style

  • Input: styleId, name (optional), style (optional)
  • Returns: Updated style details

DeleteStyleTool - Delete a style by ID

  • Input: styleId
  • Returns: Success confirmation

PreviewStyleTool - Generate preview URL for a Mapbox style using an existing public token

  • Input: styleId, title (optional), zoomwheel (optional), zoom (optional), center (optional), bearing (optional), pitch (optional)
  • Returns: URL to open the style preview in browser
  • Note: This tool automatically fetches the first available public token from your account for the preview URL. Requires at least one public token with styles:read scope.

ValidateStyleTool - Validate Mapbox style JSON against the Mapbox Style Specification

  • Input: style (Mapbox style JSON object or JSON string)
  • Returns: Validation results including errors, warnings, info messages, and style summary
  • Performs comprehensive offline validation checking:
    • Required fields (version, sources, layers)
    • Valid layer and source types
    • Source references and layer IDs
    • Common configuration issues
  • Note: This is an offline validation tool that doesn't require API access or token scopes

⚠️ Required Token Scopes:

All style tools require a valid Mapbox access token with specific scopes. Using a token without the correct scope will result in authentication errors.

  • ListStylesTool: Requires styles:list scope
  • CreateStyleTool: Requires styles:write scope
  • RetrieveStyleTool: Requires styles:download scope
  • UpdateStyleTool: Requires styles:write scope
  • DeleteStyleTool: Requires styles:write scope
  • PreviewStyleTool: Requires tokens:read scope (to list tokens) and at least one public token with styles:read scope

Note: The username is automatically

5-Dim Analysis
Clarity8/10
Novelty7/10
Utility9/10
Completeness8/10
Maintainability7/10
Pros & Cons

Pros

  • Direct access to Mapbox APIs
  • Supports multiple development environments
  • Facilitates efficient application building

Cons

  • Requires Mapbox access token
  • Complex setup for beginners
  • Dependency on external services

Related Skills

useful-ai-prompts

A
toolCo-Pilot
88/ 100

“A treasure trove of prompts, but don’t expect them to write your novel for you.”

mcpspy

A
toolCo-Pilot
86/ 100

“MCPSpy: because who doesn't want to spy on their AI's secrets?”

fastmcp

A
toolCo-Pilot
86/ 100

“FastMCP: because who doesn't love a little complexity with their AI?”

Disclaimer: This content is sourced from GitHub open source projects for display and rating purposes only.

Copyright belongs to the original author mapbox.