# Open Edge Network

> An open, low-latency edge network for execution, policy and verification. Any developer, platform or autonomous agent can
> discover a route, read its price, pay per call and verify the result, with no account.

## Execution, policy and verification
- Execution: deterministic routes for web, compliance, commerce, search readiness, document, locale and media work, answered at the network edge.
- Policy: pre-execution checks return a verdict before an agent acts. Checks are heuristic: no findings is not proof of safety.
- Verification: verdicts carry a SHA-256 receipt over a canonical record. Anyone can confirm one at https://caelaralabs.com/verify/<sha256>, with no key.

## Latency
- Median 10 to 15 ms per route in the daily public benchmark (https://benchmarks.caelaralabs.com/api/v1/benchmarks), measured inside the hosting network. It excludes the
  network between a client and the edge and is not end-user latency.

## Pricing
- Execution is metered in Edge Gas Units (EGU), a floating pay-as-you-go unit: 1 EGU per atomic route
  and 5 EGU per composite route, times the multiplier.
- The live price of one EGU is quoted with every request in `X-Edge-Gas-Unit-Price-Usd`. The cost of a call is
  `X-Edge-Gas-Quote` x `X-Edge-Gas-Unit-Price-Usd`. A price change applies only to calls quoted after it.
- Per-call payment over HTTP 402 is charged at the terms in the 402 answer.
- Charged only on success: a per-call payment settles only after a successful answer, and Edge Gas Units burn only on a
  settled HTTP 200 that is not a partial answer.

## HTTP 402 protocol
- Without a key, a metered route answers 402 with the terms in the body and `X-Payment-Required`. Pay per call with the
  `X-PAYMENT` header and retry. Or send `X-Caelara-Key` (or `Authorization: Bearer <key>`).
- Every metered answer quotes the cost before execution: `X-Edge-Gas-Unit`, `X-Edge-Gas-Unit-Price-Usd`,
  `X-Edge-Gas-Quote` (units) and `X-Edge-Gas-Multiplier` (default 1.0). Price and multiplier apply only to calls quoted
  after they change.

## Per-call burn countdown (keys metered in EGU)
- `X-Edge-Gas-Burned`: units burned by this call. 0 on any answer other than a settled HTTP 200.
- `X-Edge-Gas-Remaining`: units left on the key.
- `X-Edge-Gas-Countdown`: `<remaining>/<allocated> (burned=<burned>)` for the key.
- `X-Edge-Gas-Pool`, `X-Edge-Gas-Receipt` (SHA-256 of the burn record), and `X-Edge-Gas-Reward` when a builder rebate is credited.
- Builders: send `X-Builder-Key` to receive non-cashable execution credits on settled calls. Credits are used only for
  network execution and cannot be withdrawn or transferred.

## Machine-readable
Every suite host (for example https://api.caelaralabs.com) serves these same files and the routes behind them.
- [/.well-known/x402.json](/.well-known/x402.json): payment, quote and countdown schema
- [/openapi.json](https://api.caelaralabs.com/openapi.json): routes and parameters
- [/mcp](https://api.caelaralabs.com/mcp): MCP server manifest

Powered by Caelara Labs
