brsx-qrx
Python client and command-line tool for BRSX Qrx QR code generation. No dependencies beyond the standard library.
pip install brsx-qrx
Get an API key
Sign in to qrx.brsxlabs.com, click your name at the top right,
open API keys and create one. The key starts with brsxq_ and is shown only once.
export BRSX_QRX_KEY=brsxq_...
Every QR code you generate counts against your daily quota.
Python
from brsx_qrx import Qrx
qrx = Qrx() # reads BRSX_QRX_KEY
qrx.create("https://brsxlabs.com", path="site.png") # writes the file
png = qrx.create("hello", size=600) # or get the bytes
print(qrx.read("site.png")) # https://brsxlabs.com
u = qrx.usage()
print(u.plan, u.remaining, "of", u.daily_limit)
Typed QR codes
types() lists what the server supports; each type takes its own fields.
print(qrx.types()) # {'text': 'Metin', 'url': ...}
qrx.create_typed("wifi", {"ssid": "BRSX", "password": "1234", "encryption": "WPA"},
path="wifi.png")
Encrypted content
qrx.create_typed("text", {"text": "secret"}, path="s.png", password="abc")
r = qrx.read("s.png")
print(r.encrypted, r.content) # True None
print(qrx.read("s.png", password="abc").content) # secret
Errors
| Exception | When |
|---|---|
AuthError |
Missing, invalid or revoked API key |
QuotaError |
Daily quota used up, or content too long |
QrxError |
Any other API error (base class) |
Command line
brsx-qrx usage
brsx-qrx types
brsx-qrx create "https://brsxlabs.com" -o site.png
brsx-qrx create "secret" -o s.png --password abc
brsx-qrx create -o wifi.png --type wifi --field ssid=BRSX --field password=1234
brsx-qrx read site.png
brsx-qrx read s.png --password abc
With no -o, the PNG goes to stdout:
brsx-qrx create "https://brsxlabs.com" > qr.png
HTTP API
All endpoints take Authorization: Bearer brsxq_....
| Method | Path | |
|---|---|---|
| GET | /api/v1/me |
plan and remaining daily quota |
| GET | /api/v1/types |
supported QR types |
| GET | /api/v1/qr?data=...&size=400 |
PNG for plain text or a URL |
| POST | /api/v1/qr |
PNG for {type, fields, size, password?} |
| POST | /api/v1/read |
read a QR image (multipart image, optional password) |
License
MIT
Release files for brsx-qrx 0.1.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 | |
|---|---|---|---|
| brsx_qrx-0.1.0.tar.gz | 7.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| brsx_qrx-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 15.5 kB
Release files / brsx_qrx-0.1.0.tar.gz
| Download URL | brsx_qrx-0.1.0.tar.gz |
|---|---|
| Size | 7.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
24b645c7185c4fa7d7df7ed299c41964886a023f052b5b067e2fceac84cf68ad
|
|
BLAKE2b-256 checksum How to use checksums |
3c1bf54dcb1f47334d81542361081c98f5d3a6396c236d85f74a83f349f1dd05
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.10
|
Release files / brsx_qrx-0.1.0-py3-none-any.whl
| Download URL | brsx_qrx-0.1.0-py3-none-any.whl |
|---|---|
| Size | 8.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
2b44570c2e108b6e45e18efe856417364a9fd1eae04f432d086c3c5cb51992b8
|
|
BLAKE2b-256 checksum How to use checksums |
fe93f75e6cc2e309592fa1d9453ffd13ee39b4461ecac746ec240564af5e8f10
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.10
|