feat: add get_mapbox_docs_index_tool#30
Merged
mattpodwysocki merged 2 commits intofeat/sublevel-llms-txt-resourcesfrom Apr 14, 2026
Merged
feat: add get_mapbox_docs_index_tool#30mattpodwysocki merged 2 commits intofeat/sublevel-llms-txt-resourcesfrom
mattpodwysocki merged 2 commits intofeat/sublevel-llms-txt-resourcesfrom
Conversation
New tool that fetches the llms.txt documentation index for any Mapbox product — model can autonomously pull the right index without the user manually attaching a resource. Supports 13 product keys, results cached via docCache. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
The custom 'Accept: text/markdown, text/plain;q=0.9, */*;q=0.8' header was triggering a 403 Forbidden from the docs.mapbox.com CDN. Removing it (and the equivalent in fetchDocContent's fallback path) fixes the issue — the CDN serves the file correctly without an explicit Accept header. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
eaa138c
into
feat/sublevel-llms-txt-resources
1 check passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
get_mapbox_docs_index_tool— the model can now autonomously fetch a product'sllms.txtdocumentation index without the user manually attaching a resourceapi-reference,mapbox-gl-js,help-guides,style-spec,studio-manual,search-js,ios-maps,android-maps,ios-navigation,android-navigation,tiling-service,tilesets,catalogdocCache— first fetch hits the network, subsequent calls are instantfetchCachedTextfromdocFetcher)Motivation
Resources in the Claude Desktop / Claude Code chat UI require the user to manually attach them. That defeats the purpose of a docs server — the model should be able to pull the right index on its own. This tool makes the same content accessible as a callable tool.
Test plan
GetDocsIndexTool.test.ts)npm run build)get_mapbox_docs_index_toolwithmapbox-gl-jswithout prompting🤖 Generated with Claude Code