Ultra-high compression data transformation API
// 1. Initialize
const fetcher = new OptimizedDataFetcher({ maxRetries: 3 });
// 2. Fetch heatmap data (type 2)
const heatmapData = await fetcher.fetchHeatmapData(url);
// 3. Fetch revenue/ecommerce data
const revenueData = await fetcher.fetchRevenueData(url);
| Environment | test |
| Lambda Function | heatmap-data-fetch-test |
| API Gateway | b3a7enbwt3 |
| Region | us-east-1 |
| Last Deployed | 2025-11-08 12:52 UTC |
# Test Lambda
aws lambda invoke \\
--function-name heatmap-data-fetch-test \\
--payload '{"selfTest":true}' \\
response.json
# View Logs
aws logs tail /aws/lambda/heatmap-data-fetch-test --follow
# Monitor Metrics
aws cloudwatch get-metric-statistics \\
--namespace HeatmapTransform \\
--metric-name Success
┌─────────────────────────────────────────────────────────────────┐
│ hm.thehaloplatform.net │
│ (CloudFront CDN) │
└──────────────────┬──────────────────────────────────────────────┘
│
┌────────┴────────┐
│ │
/demo/* /api/*
│ │
┌─────▼──────┐ ┌────▼──────────┐
│ S3 Website │ │ API Gateway │
│ │ │ │
│ - Demo │ │ /transform │
│ - Docs │ │ │ │
│ - Assets │ │ ▼ │
└────────────┘ │ Lambda │
│ │ │
│ ▼ │
│ S3 Data │
└───────────────┘
Features:
• Auto-detection (heatmap vs revenue data)
• 90%+ compression ratio
• Self-test framework
• Structured error handling
• Performance tracking
Transform heatmap or revenue data files with automatic compression
{
"s3Bucket": "your-bucket",
"s3Key": "path/to/data.txt",
"outputKey": "path/to/output.json.gz",
"fileType": "heatmap|revenue" // Optional, auto-detected
}
{
"success": true,
"processingTimeMs": 450,
"metrics": {
"outputSize": 68640,
"uniqueSelectors": 2626,
"compressionRatio": "91.90%"
}
}
POST /api/transform
{
"selfTest": true
}
// Returns: Test results for all transformers
Heatmap Transform Service
Deployed: 2025-11-08 12:52 UTC | Environment: test | Region: us-east-1