# AGENTS.md - Mission for HIRE

missionforhire.aplusz.app is a single-file Cloudflare Pages advanced-mode worker. `_worker.js` edge-renders every SEO page, every Markdown twin, the REST API, the MCP server and every agent discovery file from one in-file dataset. There is no build step, no framework and no second data path.

## Layout

| Thing | Where |
|---|---|
| Everything server-side | `_worker.js` (root) |
| Cities / countries / missions | `CITIES`, `COUNTRY`, `VERBS` in `_worker.js` |
| Pricing constants | `PRICING`, `DAY` |
| Shared resolver | `fromPrice()` -> `quote()` |
| Translations | `STR` (one block per language) |
| Agent surface | the AGENT / AI SURFACE section of `_worker.js` |
| IndexNow submitter | `indexnow_push.py` (root) |
| MCP registry key + server.json | outside the repo, on the operator's machine |

## Non-negotiable rules

1. One resolver. Pages, `/api/*`, `/mcp` and the `.md` twins all call `quote()`. A second pricing path will drift and the drift gets quoted back at us.
2. Never advertise a route before it answers. A card pointing at a dead endpoint costs more trust than no card.
3. `basis` stays `indicative` everywhere. There is no verified or official tier on this site; do not invent one.
4. `_headers` files are ignored in advanced mode. Every header lives in `_worker.js`.
5. The extension guard blocks `.bak`, `.py`, `.toml`. `.md` is deliberately allowed - the twins and this file depend on it. Do not re-add `.md` to the guard.
6. Cloudflare Pages strips `.html` and retains assets from old deployments. Sitemap URLs stay extensionless; deleting a file locally does not evict it from the edge.
7. Adding a language, a city or a mission means `STR` / `CITIES` / `VERBS` plus a sitemap re-check plus an IndexNow re-ping, in the same change.
8. Absolute URLs only inside every discovery file. A relative URL works in a browser on the origin and fails for a client that fetched the card from a registry.

## Deploy

```
npx wrangler pages deploy . --project-name=missionforhire && python indexnow_push.py
```

## Data model

`quote(verb, city)` is the whole contract. Band comes from great-circle distance to the current operator base (<120 km local, same country, same region, else intercontinental); billable days = on-site + travel days (0/1/1/2), minimum 1; price = day rate x days + intensity + arrangement + travel allowance. Everything else in the response is description.

## The four layers

One file declares what exists (`AGENT_FILES`, `openapi.json`, the MCP card), one implements it (`apiRoute`, `mcpHandle`, `renderLeafMd`), and two publish it (the sitemap and the IndexNow push). Changing any one alone creates either a dead pointer or an invisible feature.
