Files
konstruct/packages/shared/pyproject.toml
Adolfo Delorenzo 215e67a7eb feat(03-01): DB migrations, models, encryption service, and test scaffolds
- Add stripe and cryptography to shared pyproject.toml
- Add recharts, @stripe/stripe-js, stripe to portal package.json (submodule)
- Add billing fields to Tenant model (stripe_customer_id, subscription_status, agent_quota, trial_ends_at)
- Add budget_limit_usd to Agent model
- Create TenantLlmKey and StripeEvent models in billing.py (AuditBase and Base respectively)
- Create KeyEncryptionService (MultiFernet encrypt/decrypt/rotate) in crypto.py
- Create compute_budget_status helper in usage.py (threshold logic: ok/warning/exceeded)
- Add platform_encryption_key, stripe_, slack_oauth settings to config.py
- Create Alembic migration 005 with all schema changes, RLS, grants, and composite index
- All 12 tests passing (key encryption roundtrip, rotation, budget thresholds)
2026-03-23 21:19:09 -06:00

29 lines
678 B
TOML

[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "konstruct-shared"
version = "0.1.0"
description = "Shared Pydantic models, SQLAlchemy ORM, and utilities for Konstruct"
requires-python = ">=3.12"
dependencies = [
"fastapi[standard]>=0.115.0",
"pydantic[email]>=2.12.0",
"pydantic-settings>=2.8.0",
"sqlalchemy[asyncio]>=2.0.36",
"asyncpg>=0.31.0",
"alembic>=1.14.0",
"redis>=5.2.0",
"celery[redis]>=5.4.0",
"httpx>=0.28.0",
"slowapi>=0.1.9",
"bcrypt>=4.0.0",
"pgvector>=0.3.0",
"stripe>=10.0.0",
"cryptography>=42.0.0",
]
[tool.hatch.build.targets.wheel]
packages = ["shared"]