Job queueing for serverless applications.
## Quirrel MCP Server: Job Queue Scheduling The **Quirrel MCP Server** integrates Quirrel job queue into Google Antigravity, enabling scheduled and delayed job execution with a developer-friendly API for background task management. ### Why Quirrel MCP? - **Simple Scheduling**: Schedule jobs with natural syntax - delays, cron patterns, and one-time executions - **Reliable Delivery**: Guaranteed job delivery with automatic retries and dead letter handling - **Development-Friendly**: Local development mode with UI for job inspection and debugging - **Type-Safe**: Full TypeScript support with type inference for job payloads - **Scalable**: Built for serverless and traditional deployments alike ### Key Features #### 1. Job Scheduling ```python # Schedule a delayed job job = await mcp.enqueue( queue="email-queue", payload={"to": "user@example.com", "template": "welcome"}, delay="5m" # Execute in 5 minutes ) print(f"Job ID: {job['id']}") print(f"Scheduled for: {job['run_at']}") ``` #### 2. Recurring Jobs ```python # Create a cron-scheduled job recurring = await mcp.schedule_cron( queue="reports", cron="0 9 * * 1", # Every Monday at 9 AM payload={"type": "weekly-summary"}, job_id="weekly-report" # Idempotent identifier ) # List scheduled jobs jobs = await mcp.list_pending(queue="reports") for job in jobs: print(f"Job {job['id']} runs at {job['run_at']}") ``` #### 3. Job Management ```python # Get job status status = await mcp.get_job(queue="email-queue", job_id="job_123") print(f"Status: {status['state']}") print(f"Attempts: {status['attempt_count']}") # Cancel a pending job await mcp.delete_job(queue="email-queue", job_id="job_123") # List all queues queues = await mcp.list_queues() for queue in queues: print(f"Queue: {queue['name']} - {queue['pending']} pending jobs") ``` #### 4. Batch Operations ```python # Enqueue multiple jobs jobs = await mcp.enqueue_many( queue="notifications", jobs=[ {"payload": {"user_id": 1}, "delay": "1m"}, {"payload": {"user_id": 2}, "delay": "2m"}, {"payload": {"user_id": 3}, "delay": "3m"} ] ) print(f"Enqueued {len(jobs)} jobs") ``` ### Configuration ```json { "mcpServers": { "quirrel": { "command": "npx", "args": ["-y", "@anthropic/mcp-quirrel"], "env": { "QUIRREL_BASE_URL": "https://api.quirrel.dev", "QUIRREL_TOKEN": "your-api-token", "QUIRREL_API_URL": "https://yourapp.com/api/queues" } } } } ``` ### Use Cases **Email Campaigns**: Schedule marketing emails and drip campaigns with precise timing, supporting both immediate and delayed delivery. **Report Generation**: Schedule resource-intensive report generation during off-peak hours with cron-based scheduling. **Webhook Retries**: Implement reliable webhook delivery with exponential backoff retries for failed deliveries. **Reminder Systems**: Build reminder and notification systems that trigger at user-specified times with timezone support. The Quirrel MCP enables robust job scheduling and background task management within your development workflow.
{
"mcpServers": {
"quirrel": {}
}
}