Bulko Python
Dependency-free Python SDK and CLI for the Bulko API.
Install
pip install bulko
SDK
import os
from bulko import Bulko
client = Bulko(os.environ["BULKO_API_KEY"])
print(client.account.balance())
campaign = client.campaigns.launch(
name="Product update",
subject="A useful update for your team",
body="<p>Hello, here is the update you requested.</p>",
recipients=["alex@example.com", {"email": "sam@example.com", "name": "Sam"}],
reply_to="replies@example.com",
)
print(client.campaigns.stats(campaign["id"]))
Available resources are campaigns, subscribers, replies, account, and smtp_accesses. AsyncBulko provides async helpers for read operations. API keys must remain server-side.
CLI
export BULKO_API_KEY=bulko_live_...
bulko balance
bulko campaign-stats 42
bulko replies --status positive --limit 25
bulko smtp-accesses
bulko import-subscribers contacts.txt --list-name "Webinar attendees"
Campaign launch is intentionally protected by an explicit flag:
bulko launch-campaign \
--name "Product update" \
--subject "A useful update" \
--html-file message.html \
--recipients-file recipients.txt \
--confirm-send
Only send permission-based email that complies with the Bulko Acceptable Use Policy and applicable law.
Errors
HTTP failures map to typed exceptions: ValidationError, AuthenticationError, InsufficientCreditsError, ContentBlockedError, NotFoundError, and RateLimitError. Each API exception exposes status_code, response, and request_id.
Development
python -m pip install -e . ruff build
ruff check .
python -m unittest discover -s tests -v
python -m build
License
MIT
Metadata
Release files for bulko 0.1.1
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 |
|---|---|---|---|---|
| bulko-0.1.1.tar.gz | 9.2 kB | Without provenance | Details for bulko-0.1.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| bulko-0.1.1-py3-none-any.whl | Python 3 | none | any | Details for bulko-0.1.1-py3-none-any.whl |
Total release size: 18.0 kB
Release files / bulko-0.1.1.tar.gz
| Download URL | bulko-0.1.1.tar.gz |
|---|---|
| Size | 9.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d710fefffdb1f0a58ae300a9be19e4179bd7e3124e3897fccd738e04500188f7
|
|
BLAKE2b-256 checksum How to use checksums |
f32726e2cdd413f6ad5304421d2ba4a760d86dd6748a6319daae127e440a90bd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.3
|
Release files / bulko-0.1.1-py3-none-any.whl
| Download URL | bulko-0.1.1-py3-none-any.whl |
|---|---|
| Size | 8.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
72f80c04bbcb68cc936cb751d0a0148c8c15099950d269fac98c4c2adc8a1935
|
|
BLAKE2b-256 checksum How to use checksums |
af14f2b641cfa6da1180c011c25fa712df55ba01e2b5fdb90783feeff68813f3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.3
|
Security for bulko 0.1.1
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A 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.