Skip to main content

CLI tool to scaffold production-ready FastAPI projects with clean architecture and built-in logging

Project description

PolePosition

A CLI tool to quickly scaffold production-ready FastAPI projects.

Create a clean, structured API project in seconds with built-in logging, configuration, and testing.

Create a new project:

polepos start myapp --install

PyPI version Python License


Example Output

$ polepos start myapp --install
Created project: myapp

Installing project dependencies with uv...
Dependencies installed successfully.

Next steps:
  cd myapp
  cp .env.example .env
  uv run fastapi dev src/myapp/main.py

Why PolePosition?

Starting a FastAPI project should be fast, clean, and predictable.

PolePosition provides:

  • A scalable project structure
  • Environment-based configuration
  • Built-in logging
  • Testing setup
  • A ready-to-run FastAPI application

No boilerplate. No setup friction.


Why not just FastAPI?

FastAPI is excellent, but starting a new project often involves:

  • Recreating the same structure
  • Setting up logging and configuration
  • Organizing modules manually

PolePosition removes that overhead by providing a clean, production-ready starting point out of the box.


Installation

uv tool install poleposition

or

pip install poleposition

Quick Start

polepos start myapp --install
cd myapp
cp .env.example .env

uv run fastapi dev src/myapp/main.py

Open your API documentation:

http://127.0.0.1:8000/docs

Usage

Create a project

polepos start myapp --install

--install runs uv sync inside the generated project for you.

Project names:

  • Must not be empty
  • Must not contain whitespace
  • May use hyphens like my-app
  • Are normalized to a Python package name like my_app

Manual setup

polepos start myapp
cd myapp

cp .env.example .env
uv sync

uv run fastapi dev src/myapp/main.py

Help and version

polepos help
polepos version

CLI

polepos help
polepos start <name> [--install]
polepos startproject <name> [--install]
polepos version

Project Structure

myapp/
├─ pyproject.toml
├─ .env.example
├─ src/
│  └─ myapp/
│     ├─ main.py
│     ├─ app.py
│     ├─ settings.py
│     ├─ bootstrap/
│     ├─ api/
│     ├─ db/
│     ├─ domain/
│     └─ modules/
│        ├─ status/
│        └─ races/
└─ tests/
   ├─ integration/
   └─ unit/

Status Endpoint

Check if your service is running:

GET /api/v1/status
{
  "status": "ok",
  "service": "myapp",
  "environment": "development",
  "version": "0.1.0",
  "uptime_seconds": 12,
  "timestamp": "2026-04-26T12:00:00Z"
}

Philosophy

PolePosition is built around a few principles:

  • Minimal: no unnecessary abstractions
  • Opinionated: sensible defaults
  • Extensible: easy to grow into larger systems

The CLI is intentionally lightweight and avoids heavy templating engines.


Roadmap

  • Project name validation
  • poleposition add module
  • JSON logging support
  • Docker support
  • Production-ready presets

Contributing

Contributions are welcome. Feel free to open an issue or submit a pull request.


License

MIT

License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

poleposition-0.0.12.tar.gz (20.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

poleposition-0.0.12-py3-none-any.whl (34.2 kB view details)

Uploaded Python 3

File details

Details for the file poleposition-0.0.12.tar.gz.

File metadata

  • Download URL: poleposition-0.0.12.tar.gz
  • Upload date:
  • Size: 20.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.2 {"installer":{"name":"uv","version":"0.11.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for poleposition-0.0.12.tar.gz
Algorithm Hash digest
SHA256 c61f8447bbd0c75bfde6b00fc3d2f0cdac789798beff393e8a4e60e46ca020fe
MD5 d683d49e55a223ddd09e358a056e8cc1
BLAKE2b-256 6c730b2d3c751f3581234ffd8a6480e48071978d109f1901a293e25f863a5c1c

See more details on using hashes here.

File details

Details for the file poleposition-0.0.12-py3-none-any.whl.

File metadata

  • Download URL: poleposition-0.0.12-py3-none-any.whl
  • Upload date:
  • Size: 34.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.2 {"installer":{"name":"uv","version":"0.11.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for poleposition-0.0.12-py3-none-any.whl
Algorithm Hash digest
SHA256 54cc418072285a5b97956b5d6089a5f320ec6997800542fdf88d5dc12da3c4b6
MD5 f11ed3a1cf63fed7eb20221f69864bb8
BLAKE2b-256 ced71169ccbb37ccbef0142dfaa1aa77a9c3254005f8320580d68414c7589674

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page