PutPlace FastAPI server for file metadata storage
Project description
PutPlace Server
A FastAPI-based file metadata storage service using MongoDB.
Installation
pip install putplace-server
Quick Start
# Start MongoDB (using Docker)
docker run -d --name mongodb -p 27017:27017 mongo:latest
# Configure the server (creates admin user, tests connections)
putplace_configure
# Start the server
ppserver start
# Check server status
ppserver status
# View logs
ppserver logs
Features
- REST API for storing and retrieving file metadata
- MongoDB backend with async support
- JWT and API key authentication
- User registration with email confirmation
- Admin dashboard for user management
- S3 storage backend support (optional)
- Google OAuth integration (optional)
API Endpoints
GET /- Root endpointGET /health- Health checkPOST /put_file- Store file metadataGET /get_file/{sha256}- Retrieve file by SHA256 hashGET /docs- Interactive API documentation (Swagger UI)GET /redoc- Alternative API documentation
Configuration
Configuration via environment variables or .env file:
MONGODB_URL=mongodb://localhost:27017
MONGODB_DATABASE=putplace
API_TITLE=PutPlace API
API_VERSION=0.8.1
# Admin user (created on first startup)
PUTPLACE_ADMIN_EMAIL=admin@example.com
PUTPLACE_ADMIN_PASSWORD=your-secure-password
Or via ppserver.toml:
[server]
host = "0.0.0.0"
port = 8000
[mongodb]
url = "mongodb://localhost:27017"
database = "putplace"
Server Management
# Start server (background)
ppserver start
# Start with custom options
ppserver start --host 0.0.0.0 --port 8080
# Stop server
ppserver stop
# Restart server
ppserver restart
# Check status
ppserver status
# View logs
ppserver logs
ppserver logs --follow
User Management
# List all users
pp_manage_users list
# Add a new user
pp_manage_users add --email user@example.com
# Delete a user
pp_manage_users delete --email user@example.com
# Reset password
pp_manage_users reset-password --email user@example.com
# Set/unset admin privileges
pp_manage_users setadmin --email user@example.com
pp_manage_users unsetadmin --email user@example.com
# List pending registrations
pp_manage_users pending
# Approve pending user
pp_manage_users approve --email user@example.com
Related
- putplace-client - CLI tool for scanning directories and uploading file metadata
License
Apache-2.0
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file putplace_server-0.10.1.tar.gz.
File metadata
- Download URL: putplace_server-0.10.1.tar.gz
- Upload date:
- Size: 141.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
496a50e2e2d366539e31fcfd51ff8663cc28f67485e0f252782350c1c2a72a8c
|
|
| MD5 |
103dcfa3a8eec646989926231918d387
|
|
| BLAKE2b-256 |
634f649d5f4e9c38f2d93ade14ff5e499c05e7c4a544b8aba97eb92d98af2ed7
|
Provenance
The following attestation bundles were made for putplace_server-0.10.1.tar.gz:
Publisher:
publish-pypi.yml on jdrumgoole/putplace
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
putplace_server-0.10.1.tar.gz -
Subject digest:
496a50e2e2d366539e31fcfd51ff8663cc28f67485e0f252782350c1c2a72a8c - Sigstore transparency entry: 802649740
- Sigstore integration time:
-
Permalink:
jdrumgoole/putplace@78d5133d9db6cc0d51c930849d7ae7e6f5957c4f -
Branch / Tag:
refs/tags/v0.10.1 - Owner: https://github.com/jdrumgoole
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@78d5133d9db6cc0d51c930849d7ae7e6f5957c4f -
Trigger Event:
push
-
Statement type:
File details
Details for the file putplace_server-0.10.1-py3-none-any.whl.
File metadata
- Download URL: putplace_server-0.10.1-py3-none-any.whl
- Upload date:
- Size: 128.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7d5db4a77c6060cc17e599b70e67b4b9bf078e50adad2576601e3a936c8bf43b
|
|
| MD5 |
068649b8b018e1068bc59630861d8255
|
|
| BLAKE2b-256 |
d25050042f0deaabcf1d94c28440927965257d811ca581ee003a5319d23262f7
|
Provenance
The following attestation bundles were made for putplace_server-0.10.1-py3-none-any.whl:
Publisher:
publish-pypi.yml on jdrumgoole/putplace
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
putplace_server-0.10.1-py3-none-any.whl -
Subject digest:
7d5db4a77c6060cc17e599b70e67b4b9bf078e50adad2576601e3a936c8bf43b - Sigstore transparency entry: 802649778
- Sigstore integration time:
-
Permalink:
jdrumgoole/putplace@78d5133d9db6cc0d51c930849d7ae7e6f5957c4f -
Branch / Tag:
refs/tags/v0.10.1 - Owner: https://github.com/jdrumgoole
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@78d5133d9db6cc0d51c930849d7ae7e6f5957c4f -
Trigger Event:
push
-
Statement type: