sync-validate

A review checklist for synchronization code, which keeps data consistent between systems. It checks pagination, cursors, saved state, two-way behavior, consistency delays, and deletion handling.

In plain words
What is it for?
Use it to audit sync implementations in TypeScript projects, especially code that reads changes in pages or synchronizes records between services.
Why use it?
It helps find loops, missed records, incorrect first runs, oversized batches, and data-loss risks before they reach production.

Skill for Claude CodeCodex

Install

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.

agentmods
npx agentmods add skills/colebemis/notion-workers/sync-validate
Any agent
npx skills add colebemis/notion-workers --skill sync-validate
Clone the repo
git clone --depth 1 https://github.com/colebemis/notion-workers

Made for: Claude Code, Codex.

Per session 31 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,021 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin 88% copy Near-identical to another mod in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5 $0.00031 $0.01021
Opus 5 $0.00015 $0.00511
Sonnet 5 $0.00006 $0.00204
Haiku 4.5 $0.00003 $0.00102

Measured 2d ago against content hash c49d7b830789, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

sync-validate 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 2d 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.

Origin

This is a copy

88% identical to sync-validate — 27 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

.agents/skills/sync-validate/SKILL.md · 61 lines

How it starts

The opening of the file, as written. The whole thing — 61 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Instructions

Read the sync capabilities in src/index.ts (and any imported modules). For each sync found, run through the checklist below. Report findings grouped by severity.

Before starting, read .agents/skills/sync-guide/SKILL.md for the full sync concepts reference.

Critical Issues (will break the sync or cause data loss)

  1. No pagination termination: Does hasMore eventually become false? Look for: infinite loops where nextState doesn't advance, missing base cases, conditions that can never be met.

  2. Cursor doesn't advance: Does nextState change between iterations? If the cursor is the same as the previous state, the sync will loop forever. Check that each execute call makes progress.

  3. Missing first-run handling: When state is undefined (first run), does the code handle it gracefully? Look for: state.cursor without state?.cursor, property access on potentially undefined state.

  4. Batch too large: Is the sync returning thousands of changes in one execution? Recommend batches of ~100. Large batches will fail.

  5. Replace mode when API supports change tracking: If mode is replace (or unset — it defaults to replace), does the source API support updated_at filters, event feeds, or similar change tracking? If so, recommend switching to incremental to avoid re-fetching everything each cycle.

  6. State persistence misunderstanding: In incremental mode, the cursor never resets between cycles. The next cycle starts exactly where the last one left off. Check for code that assumes a fresh start each cycle — this will cause records to be re-fetched or skipped permanently.

Structural Issues (bi-modal correctness)

  1. Single-mode cursor for incremental sync: Is the sync using the same cursor strategy for both backfill and delta? Unless the API sorts by updated_at and uses an opaque cursor (where one cursor naturally serves both), the sync should have a discriminated state union with separate backfill and delta phases.

Read the full file on GitHub · 61 lines

Changes

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.

  1. 2d ago First seen · 61 lines · 31 tokens per session scan A c49d7b830789

Subscribe to this mod's changes

sync-validate is a skill published in the GitHub repository colebemis/notion-workers (126 stars, last pushed 1mo ago), licensed MIT. It adds 31 tokens to every session and 1,021 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. It is 88% identical to sync-validate, differing in 27 lines, and is treated as a copy.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

brainstorming

You MUST use this before any creative work - creating features, building components, adding functionality, or modifying behavior. Explores user intent, requirements and design before implementation.

obra/superpowers · 37 tokens

auto-perf-optimize

Run agent-driven VS Code performance or memory investigations. Use when asked to launch Code OSS, automate a VS Code scenario, run the Chat memory smoke runner, capture renderer heap snapshots, take workflow screenshots, compare run summaries, or drive a repeatable scenario before heap-snapshot analysis.

microsoft/vscode · 62 tokens

chat-perf

Run chat perf benchmarks and memory leak checks against the local dev build or any published VS Code version. Use when investigating chat rendering regressions, validating perf-sensitive changes to chat UI, or checking for memory leaks in the chat response pipeline.

microsoft/vscode · 51 tokens

chat-pet-sprite-creation

Use when creating or changing VS Code chat pet sprite art, sprite sheets, state animations, eye treatments, Stable/Insiders variants, or pet transitions under src/vs/workbench/contrib/chat/browser/widget/media/chatPet.

microsoft/vscode · 53 tokens

cpu-profile-analysis

Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…

microsoft/vscode · 71 tokens