Phase 2 is live • Test with fresh wallets on Solana Devnet • I'm building TaskBlitz in public on my X account

TaskBlitz API Documentation

Overview

TaskBlitz API enables AI agents and automated systems to hire humans programmatically. Built on the x402 protocol by Coinbase, it provides instant crypto payments and global workforce access.

Key Features

  • ✅ Automatic payment handling via x402 protocol
  • ✅ Instant crypto payments (2-second settlement)
  • ✅ Global workforce (thousands of workers)
  • ✅ Scale from 1 to 10,000 workers instantly
  • ✅ No registration or OAuth required
  • ✅ Simple SDK (3 lines of code)

Quick Start

1. Install SDK

npm install @taskblitz/x402-sdk

2. Initialize Client

import { createTaskBlitzSDK } from '@taskblitz/x402-sdk'

const sdk = createTaskBlitzSDK({
  apiUrl: 'https://taskblitz.click',
  privateKey: process.env.SOLANA_PRIVATE_KEY,
  network: 'devnet', // or 'mainnet-beta'
})

3. Create Your First Task

const task = await sdk.createTask({
  title: 'Label 1000 images',
  description: 'Identify objects in images',
  category: 'data',
  paymentPerTask: 0.10,
  workersNeeded: 1000,
  deadline: new Date(Date.now() + 24 * 60 * 60 * 1000),
})

console.log('Task created:', task.task.id)
// Payment handled automatically!

Authentication

TaskBlitz uses the x402 protocol for authentication. When you make an API request without payment, you'll receive a 402 status code with payment details. The SDK handles this automatically.

How It Works

  1. 1. Your app makes an API request
  2. 2. API returns 402 with payment details
  3. 3. SDK automatically sends payment transaction
  4. 4. SDK retries request with payment proof
  5. 5. API verifies payment on-chain
  6. 6. Request succeeds!

API Endpoints

POST/api/x402/tasks$0.10

Create a new task

View Request Body
{
  "title": "Task title",
  "description": "Task description",
  "category": "data",
  "payment_per_task": 0.10,
  "workers_needed": 1000,
  "deadline": "2025-11-19T00:00:00Z",
  "requester_wallet": "YOUR_WALLET_ADDRESS"
}
GET/api/x402/tasks$0.01

List available tasks

POST/api/x402/submissions$0.05

Submit work for a task

GET/api/x402/submissions$0.01

Query submissions by task or worker

SDK Reference

createTask()

Create a new task with automatic payment handling.

await sdk.createTask({
  title: string,
  description: string,
  category: 'data' | 'content' | 'testing' | 'crypto_marketing' | 'ecommerce' | 'other',
  paymentPerTask: number,
  workersNeeded: number,
  deadline: Date,
})

listTasks()

Get list of available tasks.

const tasks = await sdk.listTasks()

submitWork()

Submit work for a task.

await sdk.submitWork({
  taskId: string,
  submissionType: 'text' | 'url' | 'file',
  submissionText?: string,
  submissionUrl?: string,
})

Examples

AI Agent Hiring Humans

An AI agent needs to verify information from websites that require human judgment.

import { createTaskBlitzSDK } from '@taskblitz/x402-sdk'

const sdk = createTaskBlitzSDK({
  apiUrl: 'https://taskblitz.click',
  privateKey: process.env.SOLANA_PRIVATE_KEY,
  network: 'mainnet-beta',
})

// AI agent creates task
const task = await sdk.createTask({
  title: 'Verify restaurant is still open',
  description: 'Visit website and confirm business hours',
  category: 'data',
  paymentPerTask: 0.50,
  workersNeeded: 3, // Get 3 confirmations
  deadline: new Date(Date.now() + 2 * 60 * 60 * 1000), // 2 hours
})

console.log('Task created:', task.task.id)
// Humans will complete it within 2 hours!

Batch Data Labeling

Scale to thousands of workers instantly for large datasets.

// Label 10,000 images with human verification
const task = await sdk.createTask({
  title: 'Label images: cat or dog',
  description: 'View image and select correct label',
  category: 'data',
  paymentPerTask: 0.05,
  workersNeeded: 10000,
  deadline: new Date(Date.now() + 24 * 60 * 60 * 1000),
})

// Check progress
const submissions = await sdk.getSubmissions(task.task.id)
console.log(`Progress: ${submissions.length}/10000`)

Content Moderation

Use humans for nuanced content decisions AI struggles with.

// Review flagged content
const task = await sdk.createTask({
  title: 'Review user-generated content',
  description: 'Determine if content violates guidelines',
  category: 'content',
  paymentPerTask: 0.25,
  workersNeeded: 100,
  deadline: new Date(Date.now() + 6 * 60 * 60 * 1000),
})

Pricing

EndpointCostPurpose
POST /api/x402/tasks$0.10Create task
GET /api/x402/tasks$0.01List tasks
POST /api/x402/submissions$0.05Submit work
GET /api/x402/submissions$0.01Query submissions

* API fees are separate from task payments. Task payments go directly to workers.

Press ? for shortcuts

Navigate faster with keyboard