TaxPilot

Search the docs

Search the Help centre, Developer docs and Legal centre.

Open TaxPilot

Maintaining the reference pages

Keep /help, /developers, /legal, /changelog, /compliance and /status accurate: where each page's content lives and how it is checked.

Updated November 22, 2026

TaxPilot's public reference pages read signed out, outside the app shell, under app/(public). Most of their content is data in apps/web/lib, so a change to the product and a change to its documentation can land in the same pull request.

Each collection is a typed Collection (lib/docs/types.ts) with sections and an array of Doc. A doc has a slug, title, one-sentence summary, section, updated date, related slugs and a list of blocks: h2, h3, p, list, steps, table, callout, code, figure, faq, defs and links. One renderer, components/docs/doc-blocks.tsx, draws every block, and the table of contents and search index read the same structure.

Text inside blocks accepts a small markup: **bold** for UI labels exactly as on screen, backticks for code and file names, [label](/path) for links and [[⌘+K]] for keys.

  1. Write or edit the doc in its collection file.Verify every UI label by finding it in the source. Don't describe a feature the code doesn't have.
  2. Add a diagram if a picture helps.Register an inline SVG under an id in components/docs/diagrams.tsx and reference it with a figure block. Use currentColor and CSS variables so it reads in light and dark.
  3. Set updated to the date you checked the content against the product.
  4. Run the docs test.npx vitest run test/docs.test.ts --maxWorkers=1 from apps/web.

test/docs.test.ts checks unique slugs and known sections, the summary format (one sentence of 20 to 240 characters ending in a full stop), at least one h2, that related slugs exist, that table rows match the header width, that figure ids are registered, and that every link resolves to a doc, a heading anchor or a known route. Legal docs must carry version metadata.

Changelog

The changelog merges two sources, newest first:

  • Product changes: add an entry at the top of PRODUCT_CHANGES in lib/changelog.ts with id, date, type, area, title, description and optional details. type is New, Improved, Fixed or Security; it drives the badge colour. area is one of the fixed values in ProductChange.
  • Tax rules changes: these come from each release's notes in src/repo.ts through listReleases(). Don't repeat them in lib/changelog.ts, so the two never drift.

Write entries for an accountant: what they can now do, in the product's own words, not in commit-message style.

Compliance versions

complianceRows() in lib/compliance.ts builds one row per release, newest first: tax year, status, the Income Tax Act assent date (enacted), the T2, AT1 and CO-17 form editions (versionCode looked up by publishedAs), every AT1 schedule edition, and the first filing spec's label. There is nothing to edit by hand: register a release or change a form's versionCode and the page follows. test/compliance.test.ts checks the order, the 2026.1 editions and that every release has an assent date and a CRA spec.

Status

The status page has two inputs. runHealthChecks() in lib/health.ts runs live server-side checks that load the real code paths (the app responds, rules releases load, every release's forms build, the filing adapters), and /api/health returns the same result as JSON: HTTP 200 when operational or degraded, 503 on an outage. Availability history comes from the hand-maintained log in lib/status.ts: COMPONENTS, INCIDENTS and MAINTENANCE. It isn't an external monitor, and the page says so.

  • When something goes wrong, add an Incident with id, title, impact (outage, degraded or maintenance), the affected components, a UTC start, and updates as it progresses (investigating, identified, monitoring, resolved). Leave end out while it's open.
  • Never back-fill guesses. dailyStatus and availability derive the 90-day bars and percentages from the log, so an invented entry shows as fact.
  • test/status.test.ts covers the derivations.
  • When NEXT_PUBLIC_STATUS_URL is set, the app's Service status links point to the hosted status page (STATUS_URL in lib/links.ts).

Legal documents are docs in lib/docs/legal/docs.ts with a legal block of LegalMeta:

  • version and effective (an ISO date, or "[date]" while it's a draft);
  • changes: a version history of { version, date, summary };
  • placeholders: facts counsel or the business must supply before publishing. They show as an Open items callout on the page.

/terms redirects to /legal/terms (next.config.ts).