> For the complete documentation index, see [llms.txt](https://antv.gitbook.io/f2/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://antv.gitbook.io/f2/api.md).

# API

After requiring F2, The global namespace F2 can be used.

### Constants

```
F2.version // version
```

### Classes

* [F2.Chart](/f2/api/chart.md): Chart.

### Namespaces

* [F2.G](/f2/api/g.md): The renderer, based on html5 canvas.
* [F2.Shape](/f2/developer/shape.md): Interface of Shapes in F2, can be used to customize shape for various geometries.
* [F2.Global](/f2/api/global.md): Global configuration of F2, including styles of charts.
* [F2.Util](/f2/api/util.md): Some utility functions.

### Functions

```
F2.track(true);      // open version usage monitoring
F2.track(false);     // close version usage monitoring
```

This method is used for monitoring F2's version usage in H5 environment. It is opened by default. If you don't want us to know your version usage or this method is bothering you, please use `F2.track(false)` to closed it.

More API：

* [Chart](/f2/api/chart.md)
* [Geometry](/f2/api/chart/geometry.md)
* [Scale](/f2/api/chart/scale.md)
* [Coordinate](/f2/api/chart/coordinate.md)
* [Axis](/f2/api/chart/axis.md)
* [Legend](/f2/api/chart/legend.md)
* [Tooltip](/f2/api/chart/tooltip.md)
* [Guide](/f2/api/chart/guide.md)
* [Animation](/f2/api/chart/animation.md)
* [Interaction](/f2/api/chart/interaction.md)
* [Global](/f2/api/global.md)
* [Util](/f2/api/util.md)
* [G](/f2/api/g.md)
* [Canvas API in F2](/f2/api/canvas-api-in-f2.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://antv.gitbook.io/f2/api.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
