Commit eacd6af
feat: add API endpoint explorer tool (#71)
Add explore_mapbox_api_tool to provide structured, queryable information
about Mapbox API endpoints, operations, parameters, and authentication.
Features:
- List all available Mapbox APIs (7 APIs with 24 operations total)
- View operations for specific APIs
- Get detailed endpoint information with parameters, scopes, rate limits
- Optional detailed mode includes example requests/responses
- Proper MCP structured content support with separate text and data
Coverage:
- Geocoding API (forward/reverse geocoding)
- Styles API (CRUD operations)
- Tokens API (token management)
- Static Images API (map image generation)
- Directions API (route calculation)
- Tilequery API (vector tile queries)
- Feedback API (user feedback events)
Implementation:
- Created mapboxApiEndpoints.ts with curated API definitions
- Implemented BaseTool with input/output schemas
- Returns both markdown content and structured data
- 21 comprehensive test cases, all passing
- Updated tool registry and documentation
Complements get_latest_mapbox_docs_tool by providing structured API
reference data instead of prose documentation.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>1 parent 0646781 commit eacd6af
9 files changed
Lines changed: 2009 additions & 0 deletions
File tree
- src
- constants
- tools
- explore-mapbox-api-tool
- test/tools
- __snapshots__
- explore-mapbox-api-tool
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
3 | 13 | | |
4 | 14 | | |
5 | 15 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
131 | 131 | | |
132 | 132 | | |
133 | 133 | | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
134 | 151 | | |
135 | 152 | | |
136 | 153 | | |
| |||
0 commit comments