EventHorizon is a decentralized "If-This-Then-That" (IFTTT) platform that listens for specific events emitted by Stellar Soroban smart contracts and triggers real-world Web2 actions like webhooks, Discord notifications, or emails.
- If This: A Soroban smart contract emits an event (e.g.,
SwapExecuted,LiquidityAdded). - Then That: EventHorizon's worker detects the event and triggers a configured action (e.g., POST to a webhook).
/backend: Node.js/Express server and Soroban event poller worker./frontend: Vite/React dashboard for managing triggers./contracts: Boilerplate Soroban Rust contract for testing.
- Node.js (v18+)
- MongoDB
- Rust & Soroban CLI (for contracts)
- Copy
.env.exampleto.envin both root and subdirectories. - Update
SOROBAN_RPC_URL(e.g.,https://soroban-testnet.stellar.org). - Update
MONGO_URI.
# Install dependencies
npm run install:all
# Start backend
npm run dev:backend
# Start frontend
npm run dev:frontend- Interactive Swagger UI is available at
/api/docswhen the backend is running. - Raw OpenAPI JSON is available at
/api/docs/openapi.json.
- Deploy the contract in
/contracts. - Copy the Contract ID.
- Add a new trigger in the dashboard using the Contract ID and event name
test_event. - Invoke the
trigger_eventfunction on the contract. - Watch the backend logs/webhook for the triggered action!