Helper UI and HTTP API for Singular.live + optional TfL data
Project description
Singular Tweaks
Python tools and tweaks for controlling Singular.live with optional TfL integration
A helper UI and HTTP API that makes it easy to control Singular.live compositions via simple HTTP GET requests. Perfect for integration with automation systems, OBS, vMix, Companion, and other broadcast tools.
✨ Features
- 🎨 Web-based Control Panel - Configure and test your Singular compositions
- 🔗 Simple HTTP API - Trigger compositions with GET requests
- 🚇 TfL Integration - Fetch and display London transport statuses
- 📊 Data Stream Support - Send data to Singular's Data Stream
- 🎯 Easy Setup - No coding required for basic usage
- 🔄 Auto-discovery - Automatically finds all your Singular subcompositions
📦 Installation
Windows (Recommended)
Option 1: Installer (Easiest)
- Download
SingularTweaks-Setup-vX.X.X.exefrom Releases - Run the installer (no admin rights needed)
- Launch from Start Menu or Desktop shortcut
Option 2: Standalone Executable
- Download
SingularTweaks.exefrom Releases - Double-click to run
- Open browser to
http://localhost:3113
Python (All Platforms)
# Install via pip
pip install singular-tweaks
# Run
singular-tweaks
# Or run as module
python -m singular_tweaks.core
From Source
git clone https://github.com/BlueElliott/Singular-Tweaks.git
cd Singular-Tweaks
pip install -r requirements.txt
python singular_tweaks/core.py
🚀 Quick Start
-
Start the application
- Windows: Run
SingularTweaks.exe - Python: Run
singular-tweaks
- Windows: Run
-
Open the web interface
- Navigate to
http://localhost:3113
- Navigate to
-
Configure Singular
- Enter your Singular Control App Token
- Click "Save Token & Refresh Commands"
-
Control your compositions
- Visit the "Commands" page to see all available controls
- Use the provided URLs in your automation system
📖 Usage Examples
Trigger a Composition In/Out
# Bring composition IN
GET http://localhost:3113/lower-third/in
# Take composition OUT
GET http://localhost:3113/lower-third/out
Update Field Values
# Set a text field
GET http://localhost:3113/lower-third/set?field=Name&value=John%20Smith
# Set a number field
GET http://localhost:3113/scoreboard/set?field=Score&value=42
Use with Stream Deck / Companion
Simply use the "System: Open URL" action with any of the control URLs shown in the Commands page.
Use with OBS Browser Source
Create a browser source that opens the control URL when you need to trigger a graphic.
⚙️ Configuration
Singular Control App
- Log in to Singular.live
- Go to your Control App
- Copy the Control App Token
- Paste it into Singular Tweaks
TfL Integration (Optional)
- Register for a TfL API account
- Get your App ID and App Key
- Enter them in the Integrations page
Data Stream (Optional)
- Get your Singular Data Stream URL
- Enter it in the Integrations page
- Use
/updateendpoint to send data
🔧 API Reference
Core Endpoints
GET /- Web interface homeGET /commands- List all available commandsGET /settings- Application settingsGET /health- Health check
Control Endpoints
GET /{key}/in- Animate composition INGET /{key}/out- Animate composition OUTGET /{key}/set?field=X&value=Y- Set field valueGET /{key}/timecontrol?field=X&run=true- Control timers
Integration Endpoints
GET /status- Get TfL line statusesPOST /update- Send TfL data to Data StreamPOST /test- Send test data to Data Stream
🛠️ Development
Setup Development Environment
git clone https://github.com/BlueElliott/Singular-Tweaks.git
cd Singular-Tweaks
python -m venv .venv
.venv\Scripts\activate # Windows
source .venv/bin/activate # Mac/Linux
pip install -r requirements.txt
pip install -r requirements-dev.txt
Run Tests
pytest
pytest --cov=singular_tweaks # With coverage
Code Quality
black singular_tweaks/
ruff check singular_tweaks/
bandit -r singular_tweaks/
Build Executable
pyinstaller SingularTweaks.spec
📝 Configuration File
Settings are saved to singular_tweaks_config.json in the application directory:
{
"singular_token": "your-token",
"singular_stream_url": "https://...",
"tfl_app_id": "your-app-id",
"tfl_app_key": "your-app-key",
"enable_tfl": true,
"enable_datastream": true,
"theme": "dark",
"port": 3113
}
🐛 Troubleshooting
Port already in use?
- Change the port in Settings page
- Or set environment variable:
SINGULAR_TWEAKS_PORT=3114
Can't connect to Singular?
- Verify your Control App Token is correct
- Check your internet connection
- Try refreshing the command list
Fonts not displaying?
- Make sure the
static/folder is in the same directory as the executable
📄 License
MIT License - see LICENSE file for details
🤝 Contributing
Contributions welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
🙏 Acknowledgments
- Singular.live - Amazing broadcast graphics platform
- TfL - Transport for London API
- FastAPI - Modern web framework
- PyInstaller - Executable packaging
📧 Support
- 🐛 Issues: GitHub Issues
- 💬 Discussions: GitHub Discussions
Made with ❤️ by BlueElliott
Project details
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 singular_tweaks-1.0.9.tar.gz.
File metadata
- Download URL: singular_tweaks-1.0.9.tar.gz
- Upload date:
- Size: 362.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f45ee0c890858710a4b0679d33b14518afe2a35df769291b422d22976fe8b68d
|
|
| MD5 |
bc1069dd7acfdde0aa37b0345c45179e
|
|
| BLAKE2b-256 |
525b7d803244437a9ae13a0bda42a0c3f8e10ecce7bdf2f944ae86fb6a59852f
|
File details
Details for the file singular_tweaks-1.0.9-py3-none-any.whl.
File metadata
- Download URL: singular_tweaks-1.0.9-py3-none-any.whl
- Upload date:
- Size: 16.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f27e64fd0f2518c2a524a35950e57cacde1e6a86adcfdbb035ccaa79d12b1021
|
|
| MD5 |
358d5c011f0fc745405b72b5402ef00b
|
|
| BLAKE2b-256 |
6d2c1252257bdbd7b9493c312559440fc946af7f3a436f3ecc0d304d2e4df43a
|