Python SDK for building Local Apps that integrate with RealtimeX
Project description
RealtimeX Local App SDK - Python
Python SDK for building Local Apps that integrate with RealtimeX.
Installation
pip install realtimex-sdk
Prerequisites
Before using this SDK, ensure your Supabase database is set up:
- Open RealtimeX Main App → Local Apps → Your App → Configure
- Enter your Supabase URL and Anon Key
- Select Compatible Mode and click Login to Supabase
- Click Auto-Setup Schema to create required tables and functions
Note: Schema setup is handled entirely by the Main App.
Quick Start
import asyncio
from realtimex_sdk import RealtimeXSDK, SupabaseConfig, RealtimeXConfig
async def main():
# Initialize SDK
sdk = RealtimeXSDK(
supabase=SupabaseConfig(
url="https://your-project.supabase.co",
anon_key="your-anon-key"
),
realtimex=RealtimeXConfig(
url="http://localhost:3001",
app_name="My Local App"
)
)
# Insert activity
activity = await sdk.activities.insert({
"type": "new_lead",
"email": "user@example.com"
})
# Trigger agent (auto-run)
result = await sdk.webhook.trigger_agent(
raw_data=activity,
auto_run=True,
agent_name="lead-processor",
workspace_slug="sales"
)
print(f"Task created: {result['task_uuid']}")
# Or create calendar event for manual review
result = await sdk.webhook.trigger_agent(
raw_data=activity,
auto_run=False
)
asyncio.run(main())
Environment Variables
When your app is started by the Main App, these are auto-set:
| Variable | Description |
|---|---|
RTX_APP_ID |
Your app's unique ID |
RTX_APP_NAME |
Your app's display name |
API Reference
See the main TypeScript README for full API documentation.
Project details
Release history Release notifications | RSS feed
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 realtimex_sdk-1.0.0.tar.gz.
File metadata
- Download URL: realtimex_sdk-1.0.0.tar.gz
- Upload date:
- Size: 8.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e55601e695254e6477e8b907b5f81ea75a3a061b828119b2dbfcedfbd6b4771a
|
|
| MD5 |
8a64c6397db5dd5896472f640735ead6
|
|
| BLAKE2b-256 |
973537521a3c5bea0c80055728eb24f89727de5f215b987494dcadc415556c2e
|
File details
Details for the file realtimex_sdk-1.0.0-py3-none-any.whl.
File metadata
- Download URL: realtimex_sdk-1.0.0-py3-none-any.whl
- Upload date:
- Size: 5.5 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 |
6132c5950f57943a3cf9268aacb27859d1a1ecc32487e4f819cd459afdf23144
|
|
| MD5 |
bd262ecf3aebac56771373fcb2a5800d
|
|
| BLAKE2b-256 |
137cb47fed6bf5c5187cbc3b78013f8bf1e6620ae2e4cdc3101398fef7740299
|