Describe GL JS API
describe_gl_js_apiLook up MapLibre GL JS APIs to verify existence, signatures, parameters, defaults, documentation, and examples for classes, methods, options, events, or functions.
Instructions
Looks up a class, method, option, event or function of MapLibre GL JS, like "Map", "Map#flyTo", "MapOptions.maxPitch", "click" or "addProtocol", in the type definitions that GL JS ships. Returns its signature, documentation, parameters, default and examples, and for a class or an options type, its members. Answers for the GL JS version this server renders with, or for another version, like the one a project uses. Check here before using a method or option you are not sure exists in MapLibre, since Mapbox GL JS has some that MapLibre GL JS does not.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | The name to look up, like "Map#flyTo", "flyTo" or "MapOptions". | |
| version | No | A GL JS version or range, like "5.6.0" or "5", whose type definitions are fetched from jsDelivr. Defaults to the version this server renders with. |