How It Works

Dialect continuously monitors token prices and analyzes percentage changes over sliding time windows. When a token’s price change exceeds the configured threshold within a time window, a webhook is triggered with detailed information about the price movement.

Sliding Window Analysis

Price changes are calculated using a sliding window approach:
  • Window Duration: Configurable time periods (1h, 3h, 6h, 12h, 24h, 7d)
  • Threshold: Percentage change required to trigger an event
  • Direction: Both upward and downward movements are detected

Supported Time Windows

WindowBeta StatusUse Case
1hAvailableMomentum detection, immediate market shifts
3hPlannedShort-term trend confirmation
6hPlannedIntraday trend identification
12hFutureHalf-day trend analysis
24hFutureDaily price movement tracking
7dFutureWeekly trend detection

Webhook Payload

When a price change event is detected, you’ll receive a webhook with this structure:
{
  "event": "token_price_change",
  "timestamp": "2025-07-04T14:30:00Z",
  "token": {
    "symbol": "SOL",
    "address": "So11111111111111111111111111111111111111112"
  },
  "trigger": {
    "type": "sliding_window_percentage_change",
    "window": {
      "duration": "24h"
    },
    "threshold_percentage": 10.0
  },
  "change": {
    "direction": "up",
    "from": {
      "timestamp": "2025-07-03T14:30:00Z",
      "value": 154.25
    },
    "to": {
      "timestamp": "2025-07-04T14:30:00Z",
      "value": 171.85
    },
    "absolute_change": 17.6,
    "percentage_change": 11.42
  }
}

Field Details

  • direction: "up" for price increases, "down" for decreases
  • from: Price and timestamp at the start of the window
  • to: Price and timestamp at the end of the window
  • absolute_change: Raw price difference (to.value - from.value)
  • percentage_change: Percentage change over the window

Use Cases

Mobile Wallet Integration

// Example webhook handler
app.post('/webhook/price-events', (req, res) => {
  const event = req.body;
  
  if (event.event === 'token_price_change') {
    // Send push notification to users holding this token
    sendPushNotification({
      title: `${event.token.symbol} ${event.change.direction === 'up' ? 'πŸ“ˆ' : 'πŸ“‰'} ${event.change.percentage_change.toFixed(1)}%`,
      body: `${event.token.symbol} moved ${event.change.percentage_change.toFixed(1)}% in the last ${event.trigger.window.duration}`,
      data: {
        tokenAddress: event.token.address,
        priceChange: event.change.percentage_change
      }
    });
  }
  
  res.status(200).send('OK');
});

Portfolio Tracker Alerts

  • Alert users when portfolio holdings have significant price movements
  • Provide context about the magnitude and timeframe of changes
  • Enable users to take action based on price movements

Trading Platform Integration

  • Notify traders about tokens meeting their criteria
  • Provide entry points for momentum-based trading strategies
  • Support risk management through downside alerts