Tek Juice Data Engine Connector
Connects a customer backend to the Tek Juice Data Engine for S2S publication, whatever the backend is written in:
- Any language or framework (Node.js, PHP, Ruby, Go, Java, .NET, ...): run
the connector as a sidecar service (
tekjuice serve, Docker image). It owns the receiver secret, endpoint, registration, verification and readiness, and hands content to four small JSON endpoints your backend implements. See docs/sidecar.md and the content API contract. - Python backends can also embed it (
pip install tekjuice-connector) and mount the receiver in FastAPI, Flask or Django (docs/setup.md).
Connect a server in one command (0.8.0+)
Put the three values from the Tek Juice setup page in the backend's .env, then on the server:
pip install tekjuice-connector
tekjuice connect
It authenticates, detects the server, asks only for what it cannot discover, creates the publication endpoint beside your application (any language; no code changes) and waits until the website is READY. See docs/connect.md.
Receiving publications (0.2.0+)
Mount a PublicationReceiver over your own content model with the adapter for
your framework (FastAPI, Flask, Django, or any WSGI/ASGI app) and register it
through the handshake. The Data Engine verifies the endpoint with a dry run
before it publishes anything. See docs/publication.md
and the wire contract in docs/publication-contract.md.
Setup: secret, endpoint, registration, readiness (0.7.0+)
TekJuiceConnector().setup(receiver=..., app=..., secret_store=...) (or
tekjuice setup --env-file .env ...) does the S2S integration itself:
- it generates
TEKJUICE_RECEIVER_SECRETon your server withsecrets.token_urlsafe(48), only when none is stored, and persists it safely; - it builds
TEKJUICE_PUBLICATION_ENDPOINT_URLfrom your API's configured host and the receiver route, mounting the route on FastAPI/Flask when needed; - it proves through the public URL, with a dry run, that the endpoint reaches your receiver;
- it registers both values with the Data Engine, confirms the Data Engine stored them, and waits for the Data Engine's verification;
- it reports readiness stage by stage, publishes nothing, and supports coordinated secret rotation.
See docs/setup.md.
What it does
- Authenticates your backend with the Tek Juice Data Engine via an E2E handshake.
- Reports
READYstate when the Data Engine confirms the backend is connected. - Provides bounded retry with exponential backoff for transient failures.
- Sanitises all log output and diagnostic reports — secrets never leak.
- Provides a CLI for configuration verification and connectivity testing.
What it does NOT do
This package does not implement content generation, SEO, or any Data
Engine internal logic, and it never stores content itself: publications are
persisted by a ContentStore you implement over your own content model.
Quick start
1. Install
pip install tekjuice-connector
2. Configure
Set the three required environment variables:
export TEKJUICE_WEBSITE_ID=your-website-id
export TEKJUICE_CONNECTOR_KEY=your-connector-key
export TEKJUICE_DATA_ENGINE_URL=https://engine.tekjuice.io
3. Connect
from tekjuice_connector import TekJuiceConnector
connector = TekJuiceConnector()
result = connector.connect()
if result.ready:
print("Tek Juice Data Engine connected")
print("Domain:", result.domain)
4. Test the connection
tekjuice test-connection
5. Run diagnostics
tekjuice diagnostics
Requirements
- Python 3.11+
requests>= 2.28
No web framework required.
Configuration
| Variable | Description |
|---|---|
TEKJUICE_WEBSITE_ID |
Your Tek Juice website identifier |
TEKJUICE_CONNECTOR_KEY |
Your connector key (treat as a secret) |
TEKJUICE_DATA_ENGINE_URL |
Base URL of the Tek Juice Data Engine API |
See docs/configuration.md for full details.
CLI commands
tekjuice status # Print current connection state
tekjuice test-connection # Live E2E handshake test
tekjuice diagnostics # Full diagnostic report
tekjuice --version # Print package version
Security
The connector key is never logged, never included in exception messages, and never appears in diagnostic output. See docs/security.md.
Two credentials
- The connector key (issued by the Data Engine) authenticates this backend's handshake with the Data Engine.
- The receiver secret (generated on your server by
setup(), or by you) authenticates the Data Engine's S2S publication requests to your receiver.
They are never interchangeable. S2S through this package is the only publication transport the Data Engine supports; the earlier M2M transport is retired. See docs/authentication.md.
Performance controls
Optional middleware lets the Data Engine apply approved, reversible delivery settings (static-asset caching, compression) without code changes; see docs/performance.md.
Documentation
- Installation
- Sidecar for any language and its content API
- Setup (secret, endpoint, registration, rotation)
- Configuration
- Authentication
- Connection lifecycle
- Integration
- Security
- Troubleshooting
Development
git clone https://github.com/tekjuice/tekjuice-connector.git
cd tekjuice-connector
pip install -e ".[dev]"
pytest
License
MIT License. See LICENSE.
Metadata
Release files for tekjuice-connector 0.9.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 | |
|---|---|---|---|---|
| tekjuice_connector-0.9.0.tar.gz | 135.2 kB | With provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| tekjuice_connector-0.9.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 308.3 kB
Release files / tekjuice_connector-0.9.0.tar.gz
| Download URL | tekjuice_connector-0.9.0.tar.gz |
|---|---|
| Size | 135.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
09042bf1782b943cf07b43865c6ca18907b9471c50437442ec6c80b25c45a515
|
|
BLAKE2b-256 checksum How to use checksums |
4a98780ada7dc66074ac7411f75a147924b4513afe4f7b5dc9f54fd5a06618d8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Oct 20, 2026.
Transparency logRelease files / tekjuice_connector-0.9.0-py3-none-any.whl
| Download URL | tekjuice_connector-0.9.0-py3-none-any.whl |
|---|---|
| Size | 173.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6ee02961ea46351091c2c022d0a1da2177e9a4e822afdf5ba6034eaa5edc3d6b
|
|
BLAKE2b-256 checksum How to use checksums |
ab5f4dc145a5be6d43611aab6a9f7b2797540380f22a262a0aad0a760c66110a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Oct 20, 2026.
Transparency logSecurity for tekjuice-connector 0.9.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
All 2 files in this release have been uploaded with provenance metadata.
Attestation for tekjuice_connector-0.9.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 Oct 20, 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.