Skip to main content

flyfun-common

Shared user management and authentication library for flyfun services.

Provides OAuth login (Google, Apple), JWT session management, user database models, and API token administration — all as reusable FastAPI components.

Installation

pip install flyfun-common

Usage

from fastapi import FastAPI
from flyfun_common.auth import create_auth_router
from flyfun_common.db import init_db

app = FastAPI()

# Initialize database
init_db()

# Mount the auth router
app.include_router(create_auth_router())

Configuration

All configuration is via environment variables:

Variable Required Description
JWT_SECRET Production Secret key for signing JWT tokens
DATABASE_URL No SQLAlchemy database URL (defaults to local SQLite)
ENVIRONMENT No production or development (default)
COOKIE_DOMAIN No Cookie domain for cross-subdomain SSO
GOOGLE_CLIENT_ID No Google OAuth client ID
GOOGLE_CLIENT_SECRET No Google OAuth client secret
APPLE_CLIENT_ID No Apple Sign In service ID
APPLE_TEAM_ID No Apple Developer Team ID
APPLE_KEY_ID No Apple Sign In key ID
APPLE_PRIVATE_KEY No Apple Sign In private key (PEM)
CREDENTIAL_ENCRYPTION_KEY Production Fernet key for encrypting stored credentials

License

MIT

Download files

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

Source Distribution

flyfun_common-0.6.4.tar.gz (46.9 kB view details)

Uploaded Source

Built Distribution

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

flyfun_common-0.6.4-py3-none-any.whl (60.3 kB view details)

Uploaded Python 3

File details

Details for the file flyfun_common-0.6.4.tar.gz.

File metadata

  • Download URL: flyfun_common-0.6.4.tar.gz
  • Upload date:
  • Size: 46.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.11

File hashes

Hashes for flyfun_common-0.6.4.tar.gz
Algorithm Hash digest
SHA256 0919d485dc316c227c817579a896d15963130947623e4e385debc3db3935c9a7
MD5 95e4ac1932210a4a70976c652eb72c4b
BLAKE2b-256 c5a8425231072e66d6b36a67844a0bef10e9662435c648469e68e8cd451e6e56

See more details on using hashes here.

File details

Details for the file flyfun_common-0.6.4-py3-none-any.whl.

File metadata

  • Download URL: flyfun_common-0.6.4-py3-none-any.whl
  • Upload date:
  • Size: 60.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.11

File hashes

Hashes for flyfun_common-0.6.4-py3-none-any.whl
Algorithm Hash digest
SHA256 5edfcd38f3e0f971eb1d943d8f1ceaf6fe30ae87ba1cc7c50349ed3ebf423114
MD5 850bdbf5987f9d6e1261078d753a711e
BLAKE2b-256 5674fbba88f482577d76e64226ab69453b7f7f7dfa9e392c4df74a835f3c1fe4

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.6.4 This release

2 files

0.6.3

2 files

0.6.2

2 files

0.6.1

2 files

0.6.0

2 files

0.5.3

2 files

0.5.0

2 files

0.4.2

2 files

0.4.1

2 files

0.4.0

2 files

0.3.12

2 files

0.3.11

2 files

0.3.10

2 files

0.3.9

2 files

0.3.8

2 files

0.3.7

2 files

0.3.6

2 files

0.3.5

2 files

0.3.4

2 files

0.3.3

2 files

0.3.2

2 files

0.3.1

2 files

0.3.0

2 files

0.2.0

2 files

0.1.2

2 files

0.1.1

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page