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...
Resolved 47 packages in 40ms
Installed 47 packages in 52ms

Project ready.

Next steps:
  cd myapp
  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 example

polepos start myapp --install
cd myapp

uv run fastapi dev src/myapp/main.py

Open your API documentation:

http://127.0.0.1:8000/docs

Quickstart

One-command setup (recommended)

polepos start myapp --install
cd myapp

uv run fastapi dev src/myapp/main.py

Manual setup

polepos start myapp
cd myapp

cp .env.example .env
uv sync

uv run fastapi dev src/myapp/main.py

CLI

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

Project Structure

myapp/
├─ pyproject.toml
├─ .env.example
├─ src/
│  └─ myapp/
│     ├─ main.py
│     ├─ app.py
│     ├─ api/
│     │  └─ routes/
│     │     └─ status.py
│     └─ core/
│        ├─ config.py
│        └─ logging.py
└─ tests/

Status Endpoint

Check if your service is running:

GET /api/v1/status
{
  "status": "ok",
  "service": "myapp",
  "environment": "development",
  "version": "0.1.0"
}

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.11.tar.gz (11.0 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.11-py3-none-any.whl (15.3 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: poleposition-0.0.11.tar.gz
  • Upload date:
  • Size: 11.0 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.11.tar.gz
Algorithm Hash digest
SHA256 6b81062dcc50d0c79fb5cfa90f91e951d4049914cc67bb52d07638feeba7a29a
MD5 f039e850291088bd7a23015714ef6c36
BLAKE2b-256 9972571efd561625a59d1480108f5a23aacb7165014253e7031823d24c087362

See more details on using hashes here.

File details

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

File metadata

  • Download URL: poleposition-0.0.11-py3-none-any.whl
  • Upload date:
  • Size: 15.3 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.11-py3-none-any.whl
Algorithm Hash digest
SHA256 bafa818194bffec241af39971443a4f7c6d3e96a8094ba04aa6088a6529f025c
MD5 e6fec526f238c49dbdaaccef0fe7b255
BLAKE2b-256 84dfa686b8af183e3bf3bb6ee44dd42d5797e20798382e064db4672c085ed8ca

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