Skip to content
Automation
Skill

/integrations

External data sources, connectors, and custom data streams

From plugin
cloddsbot
651120 skills
Install
$ npx -y skills add alsk1992/CloddsBot --skill integrations --agent claude-code

How it fires

How this skill gets triggered: by you, by Claude, or both.

  • Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition โ†’
  • You can call itInvoke it directly when you want it.
  • Slash command/integrations

Context preview

The summary Claude sees to decide when to auto-load this skill.

External data sources, connectors, and custom data streams

SKILL.md

integrations.SKILL.md
name: integrations
description: "External data sources, connectors, and custom data streams"
emoji: "๐Ÿ”—"

Integrations - Complete API Reference

Manage external data sources, add custom connectors, and plug in new data streams for trading bots.

---

Chat Commands

List Data Sources

/integrations                               List all data sources
/integrations status                        Show source health
/integrations sources                       Available source types

Manage Sources

/integrations enable fedwatch              Enable CME FedWatch
/integrations disable 538                   Disable FiveThirtyEight
/integrations add webhook "my-signals"      Add custom webhook source
/integrations add rest "my-api" <url>       Add REST API source
/integrations remove <source-id>            Remove data source

Configure Sources

/integrations config fedwatch              View source config
/integrations set fedwatch interval 60     Set refresh interval
/integrations set fedwatch key <api-key>   Set API key
/integrations test <source-id>             Test source connection

View Data

/integrations data fedwatch                Latest data from source
/integrations history <source> --hours 24  Historical data
/integrations subscribe <source>           Real-time updates

---

TypeScript API Reference

Create Integrations Manager

import { createIntegrationsManager } from 'clodds/integrations';

const integrations = createIntegrationsManager({
  // Storage
  storage: 'sqlite',
  dbPath: './integrations.db',

  // Default refresh interval
  defaultIntervalMs: 60000,

  // Retry settings
  maxRetries: 3,
  retryDelayMs: 5000,
});

Built-in Data Sources

// Enable built-in sources
await integrations.enable('fedwatch');     // CME FedWatch
await integrations.enable('538');          // FiveThirtyEight
await integrations.enable('silver');       // Silver Bulletin
await integrations.enable('rcp');          // RealClearPolitics
await integrations.enable('odds-api');     // The Odds API
await integrations.enable('polymarket');   // Polymarket prices
await integrations.enable('kalshi');       // Kalshi prices
await integrations.enable('binance');      // Binance spot prices
await integrations.enable('crypto');       // Multi-exchange crypto

Add Custom Webhook Source

// Add webhook to receive custom signals
const source = await integrations.addWebhook({
  name: 'my-signals',
  description: 'Custom trading signals',

  // Webhook config
  path: '/webhooks/my-signals',
  secret: process.env.WEBHOOK_SECRET,

  // Data schema (optional validation)
  schema: {
    type: 'object',
    properties: {
      signal: { type: 'string', enum: ['BUY', 'SELL', 'HOLD'] },
      symbol: { type: 'string' },
      confidence: { type: 'number', min: 0, max: 1 },
    },
    required: ['signal', 'symbol'],
  },

  // Transform incoming data
  transform: (payload) => ({
    signal: payload.signal,
    symbol: payload.symbol,
    confidence: payload.confidence || 0.5,
    timestamp: Date.now(),
  }),
});

console.log(`Webhook URL: ${source.url}`);
// POST to: https://your-domain.com/webhooks/my-signals

Add Custom REST Source

// Add REST API data source
const source = await integrations.addRest({
  name: 'my-api',
  description: 'Custom price API',

  // API config
  url: 'https://api.example.com/prices',
  method: 'GET',
  headers: {
    'Authorization': `Bearer ${process.env.MY_API_KEY}`,
  },

  // Polling interval
  intervalMs: 30000,

  // Transform response
  transform: (response) => ({
    price: response.data.price,
    volume: response.data.volume,
    timestamp: Date.now(),
  }),
});

Add WebSocket Source

// Add WebSocket data source
const source = await integrations.addWebSocket({
  name: 'live-prices',
  description: 'Real-time price feed',

  // WebSocket config
  url: 'wss://stream.example.com/prices',

  // Message handlers
  onMessage: (data) => ({
    type: 'price',
    symbol: data.s,
    price: parseFloat(data.p),
    timestamp: data.t,
  }),

  // Subscription message
  subscribe: {
    method: 'SUBSCRIBE',
    params: ['btcusdt@trade'],
  },

  // Reconnect settings
  reconnect: true,
  reconnectIntervalMs: 5000,
});

Subscribe to Data

// Subscribe to real-time updates
integrations.subscribe('my-signals', (data) => {
  console.log(`Signal: ${data.signal} ${data.symbol}`);
  console.log(`Confidence: ${data.confidence}`);

  if (data.signal === 'BUY' && data.confidence > 0.8) {
    // Execute trade logic
  }
});

// Subscribe to multiple sources
integrations.subscribeAll(['fedwatch', 'crypto', 'my-signals'], (source, data) => {
  console.log(`[${source}] ${JSON.stringify(data)}`);
});

Get Latest Data

// Get current data from source
const fedData = await integrations.getData('fedwatch');

console.log('Fed Rate Probabilities:');
for (const meeting of fedData.meetings) {
  console.log(`${meeting.date}: ${meeting.probabilities}`);
}

// Get with freshness check
const data = await integrations.getData('crypto', {
  maxAgeMs: 60000,  // Refetch if older than 60s
});

Check Status

// Get source status
const status = await integrations.getStatus('my-api');

console.log(`Status: ${status.status}`);  // 'healthy' | 'degraded' | 'error'
console.log(`Last fetch: ${status.lastFetch}`);
console.log(`Last error: ${status.lastError}`);
console.log(`Fetch count: ${status.fetchCount}`);
console.log(`Error count: ${status.errorCount}`);

// Get all statuses
const all = await integrations.getAllStatuses();

---

Built-in Data Sources

| Source | Type | Data | Refresh | |--------|------|------|---------| | **fedwatch** | REST | Fed rate probabilities | 5 min | | **538** | REST | Election forecasts | 1 hour | | **silver** | REST | Silver Bulletin forecasts | 1 hour | | **rcp** |

Read more
Ships withcloddsbot

Open Source AI trading agent that operates autonomously across 1000+ markets - Polymarket, Kalshi, Binance, Hyperliquid, Solana DEXs, 5 EVM chains. Scans for edge, executes instantly, manages risk while you sleep. Agent commerce protocol for machine-to-machine payments. Self-hosted. Built on Claude.

Get the whole plugin