Skip to main content

Lightweight full-stack async Python web framework built on Starlette designed for rapid development without compromising in UX

Project description

Z8ter

Z8ter is a lightweight, Laravel-inspired full-stack Python web framework built on Starlette. It’s designed for rapid development without compromising in UX.


Quickstart

z8 new myapp
cd myapp
z8 run dev

Features

  1. File-based routing – Views in views/ map to routes automatically, each paired with a Jinja template and optional API.
  2. Clear server/client split – Server-side rendering by default, with optional client-side “islands” (static/js/pages/<page_id>.js) for interactivity.
  3. Simple APIs – Define API classes with decorators; auto-mounted under /api/<name>.
  4. Auth & guards – Session middleware, Argon2 password hashing, and route decorators like @login_required.
  5. Builder setupAppBuilder manages config, templating, vite, auth, and errors in a consistent order.
  6. CLI tooling – Scaffold projects, pages, and APIs with z8 new, z8 create_page, z8 create_api; run with z8 run dev.

Installation

pip install z8ter

Authentication Example

from z8ter.endpoints.view import View
from z8ter.auth.guards import login_required

class Dashboard(View):
    @login_required
    async def get(self, request):
        return self.render(request, "dashboard.jinja")

AppBuilder Example

from z8ter.builders.app_builder import AppBuilder
from myapp.repos import MySessionRepo, MyUserRepo

builder = AppBuilder()
builder.use_config(".env")
builder.use_templating()
builder.use_vite()
builder.use_app_sessions(secret_key="supersecret")
builder.use_auth_repos(session_repo=MySessionRepo(), user_repo=MyUserRepo())
builder.use_authentication()
builder.use_errors()

app = builder.build(debug=True)

Modules Overview

  • z8ter.auth → Contracts, crypto (Argon2), guards, session middleware/manager.
  • z8ter.builders → AppBuilder + builder functions for config, templating, vite, auth, errors.
  • z8ter.cli → Project scaffolding, page/api generators, run server.
  • z8ter.endpoints → Base API and View classes, render/content helpers.
  • z8ter.route_builders → Route discovery from filesystem and static files.
  • z8ter.responses / z8ter.requests → Thin wrappers around Starlette’s core.
  • z8ter.logging_utils → Rich logging config with CancelledError suppression.
  • z8ter.errors → Centralized HTTP + 500 error handlers.
  • z8ter.vite → Dev/prod script tag helper with manifest reloads.
  • z8ter.config → Starlette config loader, prepopulated with BASE_DIR.
  • z8ter.core → The Z8ter ASGI wrapper around Starlette.

License

MIT © Ashesh Nepal

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

z8ter-0.2.5.tar.gz (190.8 kB view details)

Uploaded Source

Built Distribution

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

z8ter-0.2.5-py3-none-any.whl (220.5 kB view details)

Uploaded Python 3

File details

Details for the file z8ter-0.2.5.tar.gz.

File metadata

  • Download URL: z8ter-0.2.5.tar.gz
  • Upload date:
  • Size: 190.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for z8ter-0.2.5.tar.gz
Algorithm Hash digest
SHA256 b221c234aa66ae80c63996e0573f80361998e48bbfd258adc9b274a54a9a40ef
MD5 0692be418db9aacbd38aeed91f5c7251
BLAKE2b-256 dd09b2b2d9e27b135d8284c5a67e0ded5fa2f5f91cc2bae7926d976761e071f2

See more details on using hashes here.

File details

Details for the file z8ter-0.2.5-py3-none-any.whl.

File metadata

  • Download URL: z8ter-0.2.5-py3-none-any.whl
  • Upload date:
  • Size: 220.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for z8ter-0.2.5-py3-none-any.whl
Algorithm Hash digest
SHA256 94666cd60ed7ba1569e15c7c8e3499529d65191f6af4675647f2806d05f8cf0e
MD5 aa1bbb6a9e1a1a50ae8e38d1772d35fc
BLAKE2b-256 e8ffa9ab8970fc5d90a0d86790398cdf0b9a00001c4556141d851cb716255095

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