Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add tonydzi/second-brain-starter-kit --skill local-chatgpt-token-healgit clone --depth 1 https://github.com/tonydzi/second-brain-starter-kitWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/tonydzi/second-brain-starter-kit/local-chatgpt-token-heal)<a href="https://agentmods.dev/skills/tonydzi/second-brain-starter-kit/local-chatgpt-token-heal"><img src="https://agentmods.dev/badge/skills/tonydzi/second-brain-starter-kit/local-chatgpt-token-heal/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/tonydzi/second-brain-starter-kit/local-chatgpt-token-heal"><img src="https://agentmods.dev/badge/skills/tonydzi/second-brain-starter-kit/local-chatgpt-token-heal.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00076 | $0.01498 |
| Opus 5 | $0.00038 | $0.00749 |
| Sonnet 5 | $0.00015 | $0.00300 |
| Haiku 4.5 | $0.00008 | $0.00150 |
Grade A, and why
local-chatgpt-token-heal scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
⚠️ GRABLI: a bare `curl -H "User-Agent: Mozilla/5.0"` to `/backend-api/...` returns **403 for BOTH dead AND live tokens** — Cloudflare bot-blocks the curl UA before the auth layer. That curl is a USELESS token test. The How it starts
The opening of the file, as written. The whole thing — 71 lines — stays where its author put it; the contents beside it link to each section on GitHub.
OBJECTIVE: Get the ChatGPT nightly sync back to exit=0 by refreshing the dead bearer token — the correct, root-cause way (session cookie → fresh bearer), falling back to Chrome only when the cookie itself has died.
The root cause (why this skill exists)
The secrets\bearer.txt accessToken expires every ~5-9 days — that is OpenAI's design, there is no refresh-token for it. BUT the login session cookie (__Secure-next-auth.session-token, stored in secrets\session_token.txt) lives ~3 months and chatgpt.com/api/auth/session mints a fresh bearer from it on every call. So the fix is deterministic: cookie → new bearer, no browser, no LLM. The cookie also silently rotates (NextAuth rolling sessions) and token_heal.py captures the rotated one, so routine use keeps the cookie fresh indefinitely.
⚠️ GRABLI: a bare curl -H "User-Agent: Mozilla/5.0" to /backend-api/... returns 403 for BOTH dead AND live tokens — Cloudflare bot-blocks the curl UA before the auth layer. That curl is a USELESS token test. The authoritative check is token_heal.py --verify-only (urllib + full browser headers, reaches the real auth layer → 200/401).
LAYERS (do them in order, stop at the first that reaches exit=0)
L1 — deterministic re-mint (default; no browser, no LLM)
python "%IMPORTS_ROOT%\chatgpt\token_heal.py" # PowerShell: use %IMPORTS%\chatgpt\token_heal.py
- exit 0 → fresh bearer written + VERIFIED (HTTP 200), cookie rotated if server rotated it. DONE — go to "Finish".
- exit 5 → session cookie dead/absent → do L2.
- exit 6 → transient network/Cloudflare → wait a few min, retry L1 once; still 6 → note it and stop (not a token problem).
Note: nightly_sync.py already calls L1 automatically on pull exit 7 and retries the pull. So most of the time you never run this by hand — this skill is for when L1 itself returns 5 (cookie dead) and a human-in-the-loop Chrome step is needed, or when Anton runs /chatgpt-token-heal directly.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 3d ago Changed · +2 lines · -18 tokens per session 5b7eaa4200a3
- 12d ago First seen · 69 lines · 94 tokens per session scan A d367229d845f
local-chatgpt-token-heal is a skill published in the GitHub repository tonydzi/second-brain-starter-kit (6 stars, last pushed 3d ago), licensed MIT. It adds 76 tokens to every session and 1,498 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
wiki-lint
Run a deterministic, read-only health check on an Obsidian wiki. Use for lint, vault health check, audit wiki health, find orphans, find dead links, frontmatter audit, provenance audit, or wiki audit. Reports graph, link, frontmatter, provenance-ledger, empty-section, and stale-index findings; it does not reason…
wiki-ingest
Ingest supplied source material into an Obsidian vault with provenance and claim tracking: pasted text, files staged in the selected vault's inbox or .raw archive, or explicitly approved URLs. Use for a single source or bounded batch, not for saving an assistant answer. Triggers: ingest, ingest this file, ingest this…
autoresearch
Run a bounded, source-grounded research loop, draft a cited dossier, and optionally propose a separately reviewed canonical vault merge. Use when the user wants autonomous or deep research that may access the public web. Triggers: /autoresearch, autoresearch, research this topic, deep dive into, investigate, find…
canvas
Create, inspect, and update Obsidian JSON Canvas boards with text, file, link, group, and edge nodes. Use for canvas status, canvas lists, visual maps, zones, spatial layouts, adding vault notes or media to a .canvas file, and requests such as create canvas, add to canvas, or put this on the canvas.
defuddle
Plan and, with explicit network consent, use an optional external Defuddle cleaner to extract article-like HTTPS pages as Markdown. Use for defuddle, clean this URL, strip page clutter, readable Markdown from a web page, or preparing a web source for later wiki ingestion.
obsidian-bases
Explain, draft, and validate Obsidian Bases .base files with filters, formulas, properties, summaries, and table, card, or list views. Use for Obsidian Bases, database-like vault views, dynamic tables, reading lists, task trackers, filters, formulas, summaries, and .base file edits.