FluxionDB Python Client
This package provides an officially supported Python interface to FluxionDB that mirrors the Node.js and Go SDKs. It wraps the WebSocket protocol (query-parameter authentication, typed message payloads, reconnect handling) and exposes the same record, collection, key/value, and API key management helpers.
Installation
cd clients/python
pip install .
For development:
pip install -e ".[dev]"
Usage
from fluxiondb_client import FluxionDBClient, ApiKeyScope
client = FluxionDBClient(
url="ws://localhost:8080",
api_key="YOUR_SECRET_KEY",
connection_name="python-sdk",
)
client.connect()
now = int(time.time())
client.insert_multiple_records([
{"ts": now, "doc": "device-1", "data": '{"temperature":22.5}', "col": "sensors"},
])
latest = client.fetch_latest_records({
"col": "sensors",
"ts": now,
"doc": "/device-[12]/",
"where": "state:flying", # Optional: keep records containing this string
"filter": "quality:bad", # Optional: drop records containing this string
})
print(latest)
client.add_api_key("sensor-reader", ApiKeyScope.READ_ONLY)
client.remove_api_key("sensor-reader")
client.close()
Refer to fluxiondb_client/client.py for the full list of helpers, all of which map directly to the operations already available in the Go and Node clients.
Tests
cd clients/python
pytest
Or run against a real FluxionDB instance via Docker Compose (builds the server and test container):
docker compose up --build python-client
The tests expect FLUXIONDB_URL and FLUXIONDB_API_KEY; when using Compose these default to ws://fluxiondb:8080 and dev-secret. Set them manually if you are running the server yourself.
Publishing
Version bumps in pyproject.toml trigger the python-client-release GitHub Actions workflow when merged to main. The workflow installs the package, builds the wheel/sdist via python -m build, and uploads the artifacts to PyPI using the PYPI_API_TOKEN secret before tagging the release.
Metadata
Release files for fluxiondb-client 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| fluxiondb_client-0.2.0.tar.gz | 8.9 kB | With provenance | Details for fluxiondb_client-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| fluxiondb_client-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for fluxiondb_client-0.2.0-py3-none-any.whl |
Total release size: 16.2 kB
Release files / fluxiondb_client-0.2.0.tar.gz
| Download URL | fluxiondb_client-0.2.0.tar.gz |
|---|---|
| Size | 8.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0f7734710150177e6cedc926a80d324fe4421bfc5d1cc8b10faccef8d0e984b8
|
|
BLAKE2b-256 checksum How to use checksums |
4d2fcc6be8d6f1f30eda503857d6503bef6f3018e4f5885dc9b9bd7fe8017458
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 8, 2026.
Transparency logRelease files / fluxiondb_client-0.2.0-py3-none-any.whl
| Download URL | fluxiondb_client-0.2.0-py3-none-any.whl |
|---|---|
| Size | 7.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
689b2192515de824d08b4ff15642ab444b1a3020cee6bf6389ca7e6540522d1b
|
|
BLAKE2b-256 checksum How to use checksums |
578b638609d7536a5889c75f7c419fb1b893f540c82158f17d6ad4349499f56f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 8, 2026.
Transparency logSecurity for fluxiondb-client 0.2.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for fluxiondb_client-0.2.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 8, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.