Starky (Youtube demo)
A CLI tool for monitoring Starknet smart contracts and streaming events to Datadog dashboards. Starky automatically parses contract ABIs, extracts events and function calls, and creates real-time dashboards.
- π Automatic ABI Parsing: Supports both Dojo manifests and Scarb contract classes
- π Real-time Dashboards: Creates and manages Datadog dashboards automatically
- π Event Monitoring: Tracks contract events with human-readable names
- β‘ Function Call Detection: Monitors contract function invocations
- π§ Multi-Contract Support: Monitor multiple contracts simultaneously
# Clone the repository
git clone https://github.com/dubzn/starky.git
cd starky
# Install dependencies
npm install
# Build the project
npm run build
# Link globally
npm link
# Set up environment variables
cp .env.example .env
export $(grep -v '^#' .env | xargs)Create a .env file with your Datadog credentials:
# Datadog Configuration
DD_API_KEY=your_datadog_api_key
DD_APP_KEY=your_datadog_app_key
DD_SITE=us5.datadoghq.com # or your Datadog site
# Starknet RPC (optional, defaults to Alchemy)
# Supports any RPC included Katana
STARKNET_RPC_URL=rpc_urlstarky board create "my-starknet-monitor"For Dojo projects (automatic contract detection):
starky setup ./manifest.jsonFor Scarb contracts (manual setup):
# Edit starky.config.json manually
{
"activeBoardId": "your-board-id",
"abiFile": "./contract_class.json",
"contracts": ["0x1234...", "0x5678..."]
}# Monitor from latest block
starky ingest --from-block latest
# Monitor from specific block
starky ingest --from-block 1000000
# Monitor with custom interval
starky ingest --from-block latest --interval-ms 2000# Create a new dashboard
starky board create "dashboard-name"# Auto-setup for Dojo projects
starky setup ./manifest.json# Basic monitoring
starky ingest
# Advanced options
starky ingest --from-block latest --lookback-blocks 10 --interval-ms 1500 --verbose{
"activeBoardId": "your-datadog-board-id",
"abiFile": "./contract_class.json",
"contracts": [
"0x1234567890abcdef...",
"0xabcdef1234567890..."
],
"eventNames": []
}| Option | Description | Default |
|---|---|---|
--from-block |
Start monitoring from block number or 'latest' | latest |
--lookback-blocks |
Number of blocks to look back when starting from latest | 500 |
--interval-ms |
Polling interval between cycles (milliseconds) | 1500 |
--verbose |
Enable verbose logging | false |
Starky automatically creates dashboards with:
- π Event Counts: Real-time event occurrence statistics
- π§ Function Calls: Contract function invocation tracking
- π Time Series: Historical event and function call trends
- π― Contract Filtering: Filter by specific contracts
- π Event Details: Detailed event data and parameters
- π Live Logs: Real-time log stream from Datadog
Starky automatically detects and processes:
- β Contract events with human-readable names
- β Event selectors and parameters
- β Block numbers and transaction hashes
- β Timestamps and contract addresses
- β Function names and selectors
- β Target contract addresses
- β Transaction details
- β Call parameters and results
- π Smart Block Skipping: Only processes new blocks using
starknet_blockNumber - β‘ Efficient RPC Usage: Minimal API calls for maximum performance
- π Automatic Retry: Handles RPC errors gracefully
- π Memory Efficient: Optimized data structures for large-scale monitoring
Missing Events
- Verify contract addresses in
starky.config.json - Check ABI file path and format
- Ensure contracts are deployed and active
Apache License 2.0 - see LICENSE file for details.
Starky - Making Starknet monitoring simple and powerful! π

