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 romshark/datapages --skill datapages-stategit clone --depth 1 https://github.com/romshark/datapagesWrote 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/romshark/datapages/datapages-state)<a href="https://agentmods.dev/skills/romshark/datapages/datapages-state"><img src="https://agentmods.dev/badge/skills/romshark/datapages/datapages-state/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/romshark/datapages/datapages-state"><img src="https://agentmods.dev/badge/skills/romshark/datapages/datapages-state.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.00053 | $0.00785 |
| Opus 5.5 | $0.00021 | $0.00314 |
| Sonnet 5.5 | $0.00011 | $0.00157 |
| Haiku 4.5 | $0.00005 | $0.00078 |
Grade A, and why
datapages-state scanned grade A with 0 findings 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 1mo 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.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 56 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Per-tab state
Read datapages first for the build loop, hard rules and naming conventions.
Declare T as an exported, package-level struct in the app package. State[T] rejects pointers, anonymous structs and types from other packages. A page is stateful when one of its actions, On handlers or stream hooks takes datapages.State[T].
Every stateful handler on a page must use the same T. An app-level action may take State[T] only when the calling page uses that type. A mismatch returns 409 with Datapages-Retry: reconnect. Keep actions used by pages with different state types stateless.
type StateIndex struct{ Filter string }
func (PageIndex) StreamOpen(
r *http.Request, state datapages.State[StateIndex],
) error {
state.Values.Filter = "all"
return nil
}
GET cannot take state. The server allocates state when the tab connects its SSE stream. A stateful page gets a stream even when it has no stream hooks or event handlers. The server runs stateful handlers for 1 tab serially. They can read and write state.Values without another mutex.
A disconnect deletes the instance. A reconnect starts with a zero value. Initialize it in StreamOpen from the URL or signals when needed.
GET may return datapages.EnableBackgroundStreaming(true) to keep the stream and state active while the tab is hidden. This also disables the default refresh when the tab becomes visible. datapages.DisableRefreshAfterHidden(true) disables that refresh without preserving the stream or state. Only pages with a stream refresh after being hidden. Returning either value from a page without a stream is an error.
Do not retain state.Values after the handler returns. Do not capture it in a goroutine or a component that renders later. Copy the required fields instead. A returned datapages.File is served after the tab's lock is released: its Body must not read state.Values.
State exists in 1 server process. Route a tab's stream and actions to the same server with Datapages-Instance as the routing key. The instance ID script is inline: a Content-Security-Policy must allow script-src 'unsafe-inline' or set a nonce through WithCSPNonce. See datapages-server.
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.
- 1mo ago Changed · +1 tokens per session 7cf23349f1af
- 1mo ago Changed 1f55f2300c37
- 2mo ago Changed · +2 lines 15f25e9327c2
- 2mo ago Changed · +4 lines cef4bfd61b1b
- 2mo ago First seen · 50 lines · 52 tokens per session scan A 941b9e28c4ca
datapages-state is a skill published in the GitHub repository romshark/datapages (122 stars, last pushed 6d ago), licensed MIT. It adds 53 tokens to every session and 785 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-20.
datapages-state compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| datapages-stateromshark/datapages | Skill | 122 | 6d ago | MIT | A | 53 | Claude Code, Codex |
| structpagesjackielii/structpages | Skill | 24 | 22d ago | BSD-3-Clause | A | 154 | Claude Code |
| golang-proHappyMonkeyAI/AgentsProtocol | Skill | 5 | 15d ago | MIT | A | 61 | Claude Code, Codex |
| fastapifastapi/fastapi | Skill | 105k | today | MIT | A | 57 | Claude Code, Codex |
| sanity-best-practicesvercel/eve | Skill | 6.2k | today | Apache-2.0 | A | 153 | Claude Code, Codex |
| pinchtabpinchtab/pinchtab | Skill | 11k | 7d ago | MIT | A | 94 | Codex |
| printing-press-amendmvanhorn/cli-printing-press | Skill | 5.1k | today | MIT | A | 222 | Claude Code |