Zeq Edge — /api/cf*
The edge in front of your state channels: per-site rule chains (page rules / WAF / redirects), a 60-Zeqond analytics rollup, and cache control. The route namespace is /api/cf/* (the internal admin surface); the product is Zeq Edge.
Concept: Zeq Edge app.
Source: shared/api-core/src/routes/cf.ts · tables cf_sites · cf_rules · cf_request_aggregates · cf_cache_keys.
Endpoints
| Method | Path | Auth | Notes |
|---|---|---|---|
POST | /api/cf/sites | Bearer (zsm_) | Register a protected site (hostname → origin, bound to a machine). |
GET | /api/cf/sites?slug=<machine_slug> | Bearer | List a machine's sites. |
GET | /api/cf/sites/:id | Bearer | Single-site detail + analytics. |
POST | /api/cf/sites/:id/rules | Bearer | Add a rule (page_rule / waf / redirect). |
DELETE | /api/cf/sites/:id/rules/:rule_id | Bearer | Remove a rule. |
GET | /api/cf/sites/:id/analytics?window=… | Bearer | Aggregated stats over the rolling window. |
POST | /api/cf/sites/:id/purge | Bearer | Cache purge (paths[] or all). |
Every mutating call checks the caller's zsm_ key against cf_sites.machine_slug — a site is only editable by the machine that owns it.
See also
- Zeq Edge — register a site, CNAME flattening, the rule engine.
- State Channels — the hosted pages Zeq Edge sits in front of.