{
  "slug": "wrangler-whoami-adds-machine-readable-json-output-183d61d712e4",
  "title": "wrangler whoami adds machine-readable JSON output",
  "tools": [
    "wrangler"
  ],
  "tags": [
    "agent"
  ],
  "introduced_at": "2026-02-12T13:35:21.000Z",
  "announced_at": "2026-02-12T13:35:21.000Z",
  "effective_at": null,
  "date_basis": "source-publication",
  "status": "unknown",
  "how": {
    "incantation": "When a shell script needs to check Wrangler authentication without parsing text, run `wrangler whoami --json` and branch on its exit status; unauthenticated runs exit non-zero and output `{\"loggedIn\":false}`.",
    "examples": [
      "wrangler whoami --json",
      "if wrangler whoami --json > /dev/null 2>&1; then\n  echo \"Authenticated\"\nelse\n  echo \"Not authenticated\"\nfi"
    ],
    "gotchas": [
      "Version: 4.65.0",
      "--json (required): Boolean flag; default false. Return user information as JSON. Exits non-zero if not authenticated.",
      "When the user is not authenticated, the command exits with a non-zero status code and outputs `{\"loggedIn\":false}`."
    ]
  },
  "why_it_matters": "Check Wrangler authentication status in a shell script without parsing text output.",
  "sources": [
    "https://github.com/cloudflare/workers-sdk/releases/tag/wrangler%404.65.0",
    "https://developers.cloudflare.com/workers/wrangler/commands/general/"
  ],
  "rank": 0.98027,
  "judge": {
    "publish": true,
    "judge_model": "codex-cli/gpt-6-luna+typesafe/jev-1.13.0",
    "prompt_version": "extract-v7+enrich-v1+judge-v2x3+jev-publish-v1"
  },
  "review_state": "approved",
  "provenance": {
    "run_id": "backfill-20261007",
    "verdict_id": "backfill-20261007:backfill-20261007-2325e431f58c8b59-4:gate",
    "evidence_hash": "247b178f40e6e3fa51e2557f04897397512ecaad40dd0962358008cd049bd67b"
  },
  "review": {
    "draft_hash": "a84a9511579c8978adb246b4be24852543321be793b5da7f1aeb683f0f7c7fe6",
    "reviewer": "publication-gate",
    "reviewed_at": "2026-10-07T00:00:00.000Z",
    "decision": "backfill-20261007:gate",
    "reason": "3 of 3 judge runs approved with p_yes >= 0.9 (mean 0.98 >= 0.9; 2 needed) and Jev gave 0.82 (>= 0.6 needed)."
  }
}
