Skip to main content

Lightweight FastAPI microservice for identity and access management, built with asyncpg and Tortoise ORM

Project description

microservice-api

Lightweight FastAPI microservice for identity and access management, built with asyncpg and Tortoise ORM.

Features

  • FastAPI endpoints for auth, users, groups, and permissions
  • Async Postgres stack with Tortoise ORM and asyncpg
  • JWT-based auth helpers and middleware
  • Background worker scaffolding

Installation

pip install microservice-api

Quickstart

uvicorn microservice.main:create_app --factory --reload

Example

Run the minimal example (no DB/auth/worker) from the repo:

make install
make run

Or run it directly:

./.venv/bin/python examples/run.py

Configuration

Set environment variables in a .env file or your shell. Common values include database connection info and JWT secrets.

Development

pip install -e .[dev]
pytest

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

microservice_api-0.3.0.tar.gz (28.2 kB view details)

Uploaded Source

Built Distribution

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

microservice_api-0.3.0-py3-none-any.whl (38.9 kB view details)

Uploaded Python 3

File details

Details for the file microservice_api-0.3.0.tar.gz.

File metadata

  • Download URL: microservice_api-0.3.0.tar.gz
  • Upload date:
  • Size: 28.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.8

File hashes

Hashes for microservice_api-0.3.0.tar.gz
Algorithm Hash digest
SHA256 b1b0da8dc4932d6c999f178fa74068c12a3ef002a420e270fb29b1d910e323b7
MD5 e17a2a2b54a15bf4b64b685d492bffc9
BLAKE2b-256 2ab31a937eb5c5ea2716a0410bb988677801f2e29779afbabaa815c70ff2bb01

See more details on using hashes here.

File details

Details for the file microservice_api-0.3.0-py3-none-any.whl.

File metadata

File hashes

Hashes for microservice_api-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6f13508ded7c703dec2e6502c1cf21dca9c0d16fc8f743ebb8be6247070c7967
MD5 169b6a26cd79b8a73c736fc0db9e08c3
BLAKE2b-256 12d99be0a3d71cc7bf590dd793d8f3e1397dc572e243927ed6553821aca6529d

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