Automation engine for scheduling and executing Stellar and DeFi workflows.
AutomationService now supports live oracle-backed price evaluation for
automations that use type: 'price' conditions.
import { AutomationService, TriggerType } from '@galaxy-kj/core-automation';
import { OracleAggregator } from '@galaxy-kj/core-oracles';
const oracle = new OracleAggregator();
const automationService = new AutomationService({
oracle,
});await automationService.startPriceMonitoring(30_000);This polling loop:
- fetches live prices for the assets referenced by active
TriggerType.PRICErules - populates
ExecutionContext.priceContext - evaluates
PRICE_ABOVE/PRICE_BELOWstyle conditions against the live price map - executes matching rules through the normal automation pipeline
If no oracle is configured, non-price automations continue to work normally.
Price conditions simply evaluate to false unless a caller provides
ExecutionContext.priceContext explicitly.