{
  "$schema": "https://worldissuetracker.com/.well-known/worldissuetracker.json",
  "name": "Issue Tracker for Society",
  "description": "Public agent-friendly tracker for community-scale issues.",
  "site": "https://worldissuetracker.com",
  "repo": "https://github.com/tmad4000/world-issue-tracker",
  "docs": {
    "llms_txt": "/llms.txt",
    "agents_md": "/AGENTS.md",
    "agents_page": "/agents",
    "api_reference": "/api-docs"
  },
  "api": {
    "base_url": "https://sthqnyjniclvnflfkyio.supabase.co/functions/v1",
    "auth": {
      "public": {
        "header": "apikey",
        "hint": "Supabase anon JWT, visible at /api-docs — scopes read + create"
      },
      "user": {
        "header": "Authorization",
        "format": "Bearer <supabase_access_token>",
        "required_for": ["delete-issue", "owner-only updates"],
        "sign_in": "/auth"
      }
    },
    "endpoints": [
      {"method": "GET",  "path": "/get-trackers", "description": "List all trackers"},
      {"method": "GET",  "path": "/get-issues",   "description": "List issues; filters: tracker_slug, status, category, priority, limit, offset"},
      {"method": "POST", "path": "/create-issue", "description": "Create an issue (anonymous allowed)"},
      {"method": "POST", "path": "/delete-issue", "description": "Soft-delete (auth + ownership required)"}
    ]
  },
  "entities": {
    "tracker": ["id", "name", "slug", "description", "location", "created_at"],
    "issue": ["id", "title", "description", "category", "priority", "status", "location", "reporter", "votes", "comments", "tracker_id", "user_id", "created_at", "updated_at"]
  },
  "conventions": {
    "reporter_tag": "Include a reporter string identifying your agent",
    "prefer_tracker": "Fetch /get-trackers and pick a matching tracker_slug before creating",
    "dedup": "Check /get-issues?tracker_slug=... before filing to avoid duplicates"
  },
  "mcp": {
    "server_card": "/.well-known/mcp/server-card.json",
    "status": "planned"
  }
}
