{
  "functions": [
    {
      "name": "ask_human",
      "description": "Ask a real human worker to complete a task via Loopuman. Use when you need verification, judgment, subjective evaluation, content moderation, fact-checking, or real-world observation. Returns the human's response. Typical response time: 30-120 seconds. Cost: $0.10-$1.00 per task.",
      "parameters": {
        "type": "object",
        "properties": {
          "task": {
            "type": "string",
            "description": "Clear description of what you need the human to do. Be specific about what answer format you expect."
          },
          "budget_cents": {
            "type": "integer",
            "description": "Payment in cents. Minimum 10 ($0.10). Typical: 25-100. Higher budgets attract faster responses.",
            "minimum": 10,
            "default": 50
          },
          "timeout_seconds": {
            "type": "integer",
            "description": "How long to wait for a human response. Default 300 seconds (5 minutes).",
            "minimum": 30,
            "maximum": 3600,
            "default": 300
          },
          "category": {
            "type": "string",
            "description": "Task category for routing to specialized workers.",
            "enum": ["general", "data_labeling", "content_moderation", "transcription", "translation", "research", "writing", "image_annotation", "survey"]
          }
        },
        "required": ["task", "budget_cents"]
      }
    },
    {
      "name": "post_task_to_humans",
      "description": "Post an asynchronous task for human workers on Loopuman. Does not wait for completion - use check_human_task to poll for results. Good for batch operations or tasks that don't need immediate answers.",
      "parameters": {
        "type": "object",
        "properties": {
          "title": {
            "type": "string",
            "description": "Short title for the task (max 200 chars)"
          },
          "description": {
            "type": "string",
            "description": "Detailed instructions for the human worker"
          },
          "budget_cents": {
            "type": "integer",
            "description": "Payment in cents. Minimum 10.",
            "minimum": 10
          },
          "category": {
            "type": "string",
            "enum": ["general", "data_labeling", "content_moderation", "transcription", "translation", "research", "writing", "image_annotation", "survey"]
          },
          "deadline": {
            "type": "string",
            "format": "date-time",
            "description": "Optional deadline in ISO 8601 format"
          }
        },
        "required": ["title", "description", "budget_cents"]
      }
    },
    {
      "name": "check_human_task",
      "description": "Check the status and result of a task previously posted to Loopuman humans.",
      "parameters": {
        "type": "object",
        "properties": {
          "task_id": {
            "type": "string",
            "description": "The task UUID returned from post_task_to_humans"
          }
        },
        "required": ["task_id"]
      }
    },
    {
      "name": "check_loopuman_balance",
      "description": "Check available balance on Loopuman account for posting human tasks.",
      "parameters": {
        "type": "object",
        "properties": {}
      }
    }
  ],
  "implementation_notes": {
    "base_url": "https://api.loopuman.com",
    "authentication": "X-API-Key header",
    "registration": "POST /api/v1/register with company_name and email",
    "sync_endpoint": "POST /api/v1/tasks/sync (for ask_human)",
    "async_endpoint": "POST /api/v1/tasks (for post_task_to_humans)",
    "status_endpoint": "GET /api/v1/tasks/{id} (for check_human_task)",
    "balance_endpoint": "GET /api/v1/balance (for check_loopuman_balance)",
    "openapi_spec": "https://api.loopuman.com/openapi.json"
  }
}
