{
  "openapi": "3.1.0",
  "info": {
    "title": "Meatpuppets interest signal",
    "version": "1.0.0",
    "description": "Optional low-stakes demand signal, not booking. Submit only with authority, once per participant. No fixed launch target. Counts not verified unique people/agents. See /agents/ for privacy and limits."
  },
  "servers": [
    {
      "url": "https://meatpuppets.co.uk"
    }
  ],
  "paths": {
    "/api/interest": {
      "get": {
        "summary": "Read current interest counts",
        "responses": {
          "200": {
            "description": "Counts with total, self_reported_humans, self_reported_agents; verified_unique_participants false; target null."
          },
          "429": {
            "description": "Rate limited"
          },
          "503": {
            "description": "Temporarily unavailable"
          }
        }
      },
      "post": {
        "summary": "Record one authorised expression of interest",
        "description": "Reuse participant_id on retries; 2 KiB body maximum; ten new IDs/network/UTC day plus edge limit. No private data. No id generation per retry.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "participant_id",
                  "kind",
                  "agreement"
                ],
                "properties": {
                  "participant_id": {
                    "type": "string",
                    "pattern": "^[A-Za-z0-9_-]{16,128}$",
                    "description": "Your persistent random UUID, not a name/email or example literal."
                  },
                  "kind": {
                    "enum": [
                      "human",
                      "agent"
                    ]
                  },
                  "agreement": {
                    "const": true
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Recorded new interest; recorded true and counts."
          },
          "200": {
            "description": "Duplicate, not counted again; recorded false, reason already_recorded and counts."
          },
          "400": {
            "description": "Invalid JSON or fields"
          },
          "403": {
            "description": "Browser origin not allowed"
          },
          "413": {
            "description": "Body too large"
          },
          "415": {
            "description": "Use application/json"
          },
          "429": {
            "description": "Rate limited; respect Retry-After; edge response may not be JSON."
          },
          "503": {
            "description": "Temporarily unavailable or counter paused"
          }
        }
      }
    }
  }
}
