
Research
/Security News
OpenAPI React Query Codegen Compromised in Mini Shai-Hulud npm Supply Chain Attack
Ten malicious OpenAPI React Query Codegen versions were published to npm in the Mini Shai-Hulud attack, all with valid provenance.
@codmir/cloudflare-workers
Advanced tools
A distributed task execution system using Cloudflare Workers as "minions" for scalable, edge-based processing of coding tasks.
Main Agent → Task Divider → Worker Orchestrator → Cloudflare Workers (Minions)
↓ ↓ ↓ ↓
Complex Task → Micro-Tasks → Load Balancing → Edge Execution
↓ ↓ ↓ ↓
Integration ← Results Aggregation ← Task Results ← Worker Results
Breaks down complex tasks into worker-sized chunks:
Manages distributed Cloudflare Workers:
Lightweight Cloudflare Workers that execute micro-tasks:
Connects with existing agent orchestration system:
import { createCloudflareIntegration } from '@codmir/cloudflare-workers';
const integration = createCloudflareIntegration({
accountId: 'your-cloudflare-account-id',
apiToken: 'your-api-token',
scriptName: 'codmir-worker-minion',
maxConcurrentTasks: 100,
loadBalancing: { type: 'least_loaded' }
});
// Execute a task with worker distribution
const result = await integration.orchestrateWithWorkers(
"Analyze all TypeScript files in the project",
{
projectId: 'proj_123',
userId: 'user_456',
files: ['src/app.ts', 'src/utils.ts', 'src/types.ts']
},
{
useWorkers: true,
workerTaskTypes: ['code_analysis', 'file_processing'],
fallbackToAgents: true
}
);
import { WorkerOrchestrator } from '@codmir/cloudflare-workers';
const orchestrator = new WorkerOrchestrator(config);
// Register workers
await orchestrator.registerWorker({
id: 'worker-us-east-1',
name: 'US East Worker',
capabilities: ['text_processing', 'code_analysis'],
region: 'us-east-1',
status: 'idle'
});
// Execute distributed task
const result = await orchestrator.executeTask(
'task_123',
'code_analysis',
'Analyze project dependencies',
{ files: ['package.json', 'src/**/*.ts'] }
);
Original: "Analyze all project files"
↓
Micro-tasks:
├── extract_imports (parallel per file)
├── validate_syntax (parallel per file)
├── check_dependencies (depends on imports)
└── generate_docs (depends on all above)
Original: "Process configuration files"
↓
Micro-tasks:
├── analyze_file (parallel per file)
└── transform_data (aggregate results)
# Cloudflare credentials
CLOUDFLARE_ACCOUNT_ID=your-account-id
CLOUDFLARE_API_TOKEN=your-api-token
CLOUDFLARE_SCRIPT_NAME=codmir-worker-minion
# Worker configuration
MAX_CONCURRENT_TASKS=100
TASK_TIMEOUT_MS=30000
LOAD_BALANCING_STRATEGY=least_loaded
# Integration settings
USE_WORKERS=true
FALLBACK_TO_AGENTS=true
WORKER_TASK_TYPES=code_analysis,file_processing,content_generation
{
type: 'least_loaded'
}
{
type: 'geographic',
config: { preferredRegion: 'us-east-1' }
}
{
type: 'capability_based',
config: { prioritizeSpecialized: true }
}
# Install Wrangler CLI
npm install -g wrangler
# Login to Cloudflare
wrangler login
# Deploy worker minions
npm run deploy-worker
# Deploy to specific environment
wrangler deploy --env production
Workers automatically scale based on demand:
const status = orchestrator.getStatus();
console.log({
totalWorkers: status.totalWorkers,
activeWorkers: status.activeWorkers,
activeTasks: status.activeTasks,
completedTasks: status.completedTasks
});
orchestrator.on('task_completed', (event) => {
console.log(`Task ${event.taskId} completed in ${event.totalTimeMs}ms`);
});
orchestrator.on('worker_registered', (worker) => {
console.log(`New worker: ${worker.id} in ${worker.region}`);
});
The Cloudflare Workers integration seamlessly extends the existing agent orchestration system:
This creates a powerful hybrid system that leverages the best of both worlds: the intelligence and flexibility of agents with the scalability and performance of edge computing.
FAQs
Distributed task execution using Cloudflare Workers as minions
We found that @codmir/cloudflare-workers demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.

Research
/Security News
Ten malicious OpenAPI React Query Codegen versions were published to npm in the Mini Shai-Hulud attack, all with valid provenance.

Security News
Socket joins more than 100 technology, cybersecurity, and financial organizations calling for a global surge in cyber defense.

Product
Enterprise security teams can now detect malware, credential theft, suspicious network activity, and risky updates across Microsoft Edge extensions.