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 agentmods add instructions/mvpr-ext-projects/planday-bridge/agents-mdgit clone --depth 1 https://github.com/MVPR-Ext-Projects/planday-bridgeWhat 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 | $0.02170 | $0.02170 |
| Opus 5 | $0.01085 | $0.01085 |
| Sonnet 5 | $0.00434 | $0.00434 |
| Haiku 4.5 | $0.00217 | $0.00217 |
Grade A, and why
planday-bridge AGENTS.md 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.
How it starts
The opening of the file, as written. The whole thing — 152 lines — stays where its author put it; the contents beside it link to each section on GitHub.
planday-bridge — context for AI coding agents
If you are an AI agent working in this repo, read this first. It carries the domain knowledge and the non-obvious traps, most of which cost real time to rediscover.
Humans: README.md for the developer tour, SETUP.md to just get it running.
What this is
Two things over the Planday workforce-management API:
- A translator producing Planday's Timesheet Report — worked hours and staff cost per shift — which has no single endpoint and must be assembled from three.
- An MCP server exposing all 125 Planday operations.
Architecture
Everything derives from the vendored OpenAPI specs. Do not hand-write endpoint wrappers — regenerate instead, or coverage silently rots.
specs/*.json vendored from openapi.planday.com/{area}/swagger/v1.0/swagger.json
scripts/generate.ts specs -> src/generated/operations.json (pnpm gen)
src/generated/ 125 operations, 294 schemas. COMMITTED - do not gitignore.
src/planday/ auth, http (+ offset loop), validation, invoke (the dispatcher)
src/timesheet/ columns -> transform (pure) -> build -> summarise -> csv
src/bridge/ handler + setup page, shared by both HTTP entrypoints
src/fixtures/ seeded sample portal + schema-driven synthesiser
src/source.ts LiveSource | DummySource behind one interface
apps/mcp/ the MCP server (19 tools, 3 layers)
apps/bridge/ standalone HTTP server (local + Docker)
api/index.ts serverless entrypoint; vercel.json rewrites everything here
powerquery/ Timesheet.pq (GENERATED), Timesheet-direct.pq (hand-written)
Every call goes through src/planday/invoke.ts. Both HTTP entrypoints delegate to
src/bridge/handler.ts — never add a route to one without the other, or the hosted and
local builds diverge.
Traps
Each of these was found the hard way.
- The spec URLs are undocumented.
https://openapi.planday.com/{area}/swagger/v1.0/swagger.jsonfor area inabsence hr pay payroll portal punchclock reports revenue scheduling. Nothing on Planday's docs site links to them, and the docs site itself is a JS app that fetches them at runtime. openapi.planday.com/api/{area}is a documentation page, not an endpoint. Aiming Power Query or an HTTP client at one is the most common Planday integration mistake.- Every request needs two headers,
Authorization: BearerandX-ClientId. Omitting the second gives a 401 that reads like a bad token. The spec mentions neither it nor a base URL — there is noserversblock. Both are injected bysrc/planday/http.ts. limitis hard-capped at 50 on list endpoints (maximum: 50); raising it is silently ignored. Walkoffsetagainstpaging.total. The paging envelope is{ data, paging: { offset, limit, total } }and is identical across all nine areas. The three report endpoints are not paged — they are bulk date-range calls.- 113 of 125 operations have no
operationId. Ids are synthesised inscripts/generate.tsas{area}.{method}.{pathSlug}, purely from method + path so they stay stable across regeneration. Never make an id depend on ordering or a counter. - Planday's
date-timeis a .NET DateTime. Its own documented example for the punch-clock parameters is2025-01-01T00:00- no seconds, no offset - which strict RFC 3339 rejects. Left on the ajv-formats default, our validator refused requests that Planday accepts, across 24 parameters in 6 operations. Overridden invalidation.ts. format: timeis a .NETTimeOnly, not RFC 3339. ajv-formats demands a timezone offset in both fast and full mode, which would reject every legitimate shift time — Planday pairs a local wall-clock time with a separatetimeZonefield.src/planday/validation.tsoverridestimeanddate-spanfor this reason. UsecreateAjv()from there — never construct a bare Ajv, or tests will validate under looser rules than the dispatcher enforces.- Two POSTs are reads.
reports.post.schedulingHistoryandabsence.post.accounts.balance.employeesare queries whose filters are too big for a query string. They are inREAD_ONLY_POSTSin the generator; tiering by HTTP verb alone would put the entire Timesheet Report behind the write gate. firstApprovedis a snapshot, not a timestamp. Planday exposes no approval time at all. The column isfirst_approved_hours; comparing it toapprovedis what surfacesedited_after_approval.shiftIdis nullable for punch-clock entries never matched to a shift. The row key isshiftId ?? "pc-<punchclockId>". Power BI needs a real primary key, and this is the case a hand-rolled Power Query merge gets wrong.- Salaried staff never appear in
shiftsPayroll— only insalariedPayroll. Their shifts legitimately carry hours with no cost. Do not "fix" this. - Never read a file relative to
import.meta.url. It is undefined once the code is bundled into a serverless function, and the lambda dies at cold start while every local test stays green. This bit once — the operation catalogue was loaded that way. It is nowimport catalogue from "./operations.json" with { type: "json" }so bundlers inline it.test/deploy.test.tsis the only test that would catch a repeat. - Planday gates each area by its own authorization policy. A perfectly valid token can
be refused on payroll alone. Anything touching cost must degrade — payroll, then
time-and-cost, then hours with no cost — never throw.
pnpm whoamiprobes each area.
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.
- 2d ago First seen · 152 lines · 2,170 tokens per session scan A 7834e50aaf01
planday-bridge AGENTS.md is an instructions file published in the GitHub repository MVPR-Ext-Projects/planday-bridge (0 stars, last pushed 7d ago), licensed MIT. It adds 2,170 tokens to every session, about $0.0109 per session on Opus 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-08-31.
Other instructions, from other repositories
mcp-server-excel llm-testing-philosophy.instructions.md
Instructions for sbroenne/mcp-server-excel, covering llm testing philosophy, what are llm tests?, the golden rule, what never belongs in a test and ❌ xfail or skip markers.
mcp-server-excel readme-management.instructions.md
Instructions for sbroenne/mcp-server-excel, covering readme management - quick reference, core entry documents, feature documentation, critical rules and tool & action counts must match.
mcp-server-excel development-workflow.instructions.md
Instructions for sbroenne/mcp-server-excel, covering development workflow, branch protection, development process, pr review comment workflow and retrieve inline code review comments using github cli.
mcp-server-excel extension-development.instructions.md
Instructions for sbroenne/mcp-server-excel, covering vs code extension development instructions, extension overview, changelog and changesets (critical), version management and automatic version management (unified release workflow).
mcp-server-excel copilot-instructions.md
Instructions for sbroenne/mcp-server-excel, covering github copilot instructions - excelmcp, repository map, environment, working rules and build and validation.
mcp-server-excel excel-connection-types-guide.instructions.md
Instructions for sbroenne/mcp-server-excel, covering excel connection types - llm quick reference, critical: loadto operation limitations, connection action compatibility, decision tree: connection vs power query and recommended workflows.