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

# qrforge Reference

All available references for our qrforge package.

## Available imports

* qrforge: `import` **`qrforge`**
* Presets: `from qrforge import presets`
* Shapes: `from qrforge import shapes`
* Shaders: `from qrforge import shaders`
* Verification/decoder: `from qrforge import verify`
* Style options: `from qrforge import style`
* Colours: `from qrforge import color`
* Gradients: `from qrforge import gradient`
* Images: `from qrforge import image`
* Encoder internals: `from qrforge import encoder`, `from qrforge import matrix`, `from qrforge import tables`, `from qrforge import gf`
* Command line: `python -m qrforge` or the `qrforge` console script

## Available classes

* [`QR`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-api-functions.md#qr) (alias `QRCode`) — a QR code plus its rendering style.
* [`Artwork`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-api-functions.md#artwork) — a rendered symbol (pixel buffer or vector markup).
* [`Style`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-style-options.md) — the dataclass holding every styling option.
* [`Color`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-presets-and-outputs.md#color) — an RGBA colour with parsing helpers.
* [`Gradient`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-presets-and-outputs.md#gradient) and `SolidFill` — colour sources for modules, eyes and background.
* [`Pixmap`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-presets-and-outputs.md#pixmap) — qrforge's own image buffer (and PNG codec).
* `QRMatrix` — the encoded module matrix.
* `Shape` and `Shader` — registries for custom geometry and effects.

## Available functions

* [`make`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-api-functions.md#make), [`save`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-api-functions.md#save), [`svg`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-api-functions.md#svg), [`png`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-api-functions.md#png), [`terminal`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-api-functions.md#terminal) — one-line shortcuts.
* [`preset`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-api-functions.md#preset) — shortcut for `qrforge.presets.get()`.
* [`shape`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-shapes-and-shaders.md#custom-shapes), [`register_shape`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-shapes-and-shaders.md#shape-registry), [`shader`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-shapes-and-shaders.md#custom-shaders) and [`expression`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-shapes-and-shaders.md#expression-shaders) — custom geometry and effects.
* [`build_matrix`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-api-functions.md#low-level-encoding) — encode text into a `QRMatrix` without rendering.
* [`verify.decode`](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-api-functions.md#verification) — decode a module matrix (used by `QR.verify()`).

## Available modules & registries

* Presets: `presets.get`, `presets.names`, `presets.register`
* Shapes: `shapes.get`, `shapes.names`, `shapes.register`, `shapes.SHAPES`, `shapes.ALIASES`
* Shaders: `shaders.build`, `shaders.names`, `shaders.FACTORIES`

## Available exceptions

* `QRForgeError` — base class for every error.
* `DataTooLong` — the payload does not fit the requested QR settings.
* `UnsupportedFeature` — an optional dependency is missing.
* `StyleError` — an invalid style or shader option.

## Reference pages

* [Gallery](/documentation/package-documentation/qrforge-package-documentation/qrforge-gallery.md) — every preset and feature rendered as a real, scannable PNG.
* [API & Functions](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-api-functions.md) — `QR`, `Artwork`, shortcut functions, verification and the low-level encoder.
* [Style Options](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-style-options.md) — every `Style` field with default values.
* [Shapes & Shaders](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-shapes-and-shaders.md) — built-in shapes, shader parameters and custom effects.
* [Presets & Outputs](/documentation/package-documentation/qrforge-package-documentation/qrforge-reference/qrforge-presets-and-outputs.md) — the 22 presets, file formats, CLI and helper classes.


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://infinitode-docs.gitbook.io/documentation/package-documentation/qrforge-package-documentation/qrforge-reference.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
