https://github.com/thepmsquare/square_database
a database layer for my personal server. this service exposes database operations as a fastapi application, powered by pluggable orm models (by default from square_database_structure, but you can swap in your own).
https://github.com/thepmsquare/square_database
database
Last synced: 6 months ago
JSON representation
a database layer for my personal server. this service exposes database operations as a fastapi application, powered by pluggable orm models (by default from square_database_structure, but you can swap in your own).
- Host: GitHub
- URL: https://github.com/thepmsquare/square_database
- Owner: thepmsquare
- License: gpl-3.0
- Created: 2024-08-26T18:26:00.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2025-12-21T18:34:21.000Z (7 months ago)
- Last Synced: 2025-12-23T07:35:12.463Z (7 months ago)
- Topics: database
- Language: Python
- Homepage: https://pypi.org/project/square-database/
- Size: 188 KB
- Stars: 0
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# square_database
> 📌 versioning: see [CHANGELOG.md](./CHANGELOG.md).
## about
a database layer for my personal server. this service exposes database operations as a fastapi application, powered by
pluggable orm models (by default from square_database_structure, but you can swap in your own).
## goals
- centralized database api
- pluggable orm models
- simple crud operations
- stored procedure support
- realtime via websockets
## installation
```shell
pip install square_database[all]
```
## usage
### configuration
update the settings in `config.ini` and `config.testing.ini` to match your environment (database url, logging, etc).
### models
this service requires orm models from a pluggable module. the default is [
`square_database_structure`](https://github.com/thepmsquare/square_database_structure), but you can provide your own
module if needed.
### running the service
```shell
python square_database/main.py
```
## env
- python>=3.12.0
> feedback is appreciated. thank you!