Files
OpenBB/cookiecutter
dlee-bq 42fc2838f1 Remove Python 3.10 tomli fallbacks
With requires-python >=3.11, tomllib is always available, so the
version-conditional tomli imports are dead code.

- import tomllib directly in the cli and core config loaders, the
  mcp_server and platform_api config validators, dev_install.py, and
  the cli and cookiecutter tests; dev_install.py no longer pip-installs
  tomli on the fly
- drop the tomli>=2.0; python_version<'3.11' dependency from cli, core,
  mcp_server, and platform_api, plus platform_api's backport comment
- raise the fake-extension fixtures in cli/conftest.py,
  core/integration/conftest.py, and the charting test metadata to
  >=3.11
- relock cli, core, mcp_server, and platform_api; only the tomli
  requires-dist entry is removed and resolution markers are reordered,
  no package versions change
2026-10-24 01:12:19 -07:00
..
2026-10-24 01:12:19 -07:00
2026-10-24 00:56:30 -07:00
2026-09-29 14:45:53 +00:00

OpenBB Extensions Cookiecutter

A Cookiecutter template that generates a new OpenBB Platform extension as an installable Python project.

Extension types

Choose one or more types, or all:

Type Generates
router Commands under obb.<router_name>
provider A data provider with an example model and an EquityHistorical standard-model implementation
charting Chart views for the router's commands, used with openbb-charting
obbject Accessors added to every command result
on_command_output A plugin that runs after a command returns

The generated project follows the same conventions as the extensions in this repository: hatchling packaging, entry points in [project.entry-points], a dev dependency group, ruff and ty configuration in pyproject.toml, and tests for every generated module.

Usage

Run it with uv without installing:

uvx openbb-cookiecutter

Or install it and run the command:

pip install openbb-cookiecutter
openbb-cookiecutter

Enter a value at each prompt or press enter to accept the default. Pass the types directly to skip that prompt:

openbb-cookiecutter -e router provider

Generate without prompts, into another directory:

openbb-cookiecutter --no-input -o ./extensions -e all

Override any template value with --extra-context KEY=VALUE, for example --extra-context provider_name=my_source.

The provider and the OBBject extension each register a credentials namespace under their name, so they need different names.

Working on the generated project

The generated README.md covers setup. In short, from the project directory:

uv sync
uv run openbb-build
uv run pytest

Developing the template

From this directory:

uv sync
uv run pytest

The tests generate a project for each extension type and check its files, its entry points, and that it passes ruff and ty.

Contacts

Questions about the template or OpenBB: support@openbb.co. Partnerships: hello@openbb.co. Social links: openbb.co/links.