In this section: Build
Start
Reference code
- obsp (C)
- Conformance runner (reference service)
- obsp (Go)
- Plugfests (non-normative groundwork)
- Python reference pipelines (draft profiles, synthetic data)
- obsp-eo
- obsp-model-run (draft OIP-0012, MODEL-OBSERVER)
- obsp-sensing (draft OIP-0011, NETWORK-SENSING, provisional)
- obsp-space
- Rust reference workspace
- Performance bench (WP-RI-11)
- The 0.2 candidate (DRAFT)
- obsp-core (Rust reference library)
- obsp-federation
- obsp-node-embedded
- Node agent (obsp-node)
- Evidence verifier (obsp-verify)
- obsp-sdk (TypeScript / ES modules)
Tools
API reference
- All APIs
- Observatory Protocol service administration (production services)
- Observatory Protocol CloudEvents (draft OIP-0024 binding)
- Observatory Protocol correction subscriptions
- Observatory Protocol credential status (reference service)
- Observatory Protocol discovery (reference service)
- Observatory Protocol exchange API (reference)
- Observatory Protocol federation sync (draft OIP-0004)
- Observatory Protocol Field Topic Contract (MQTT 5 and Sparkplug B)
- Observatory Protocol participant gateway
- gRPC services
- Observatory Protocol implementations and conformance registry (reference service)
- Observatory Protocol transparency log (reference service)
- Observatory Protocol WIS 2.0 notifications (draft OIP-0009 binding)
Public services
Bindings and crosswalks
Public reference services
On this page
- Discovery (reference service) Serves this authority's /.well-known/obsp document, keeps a federated index of other authorities, and resolves authority-form UNIs, after draft OIP-0016. Code: obsp_public/discovery.py. API:…
- Transparency log (reference service) A standalone append-only log of digests, usable by releases, plans, proofs, conformance reports and registry records, status lists and authority documents. An entry records a statement about a…
- Check an inclusion receipt Paste an inclusion receipt of the transparency log: your browser checks the leaf, the audit path (RFC 9162), the signed tree head and its signature, with nothing sent anywhere.
- Implementations and conformance registry (reference service) Implementers submit a signed conformance claim with its evidence; the registry checks it, records the level the evidence supports, logs the record and publishes it. A record says what this registry…
- Credential status (reference service) A W3C Bitstring Status List publisher for the participant credentials of draft OIP-0015 (CRED-4). Code: obsp_public/status.py. API: obsp-credential-status.openapi.yaml.
Four services an open protocol needs, as reference code: an implementations and conformance registry, discovery, a credential status publisher and a transparency log. They run locally and in continuous integration only; this repository hosts none of them and holds no credential for doing so. They are drafts built on drafts: each one says which change proposal it follows, and nothing here makes a draft normative.
| Service | README | OpenAPI | Threat note | Drafts it follows |
|---|---|---|---|---|
| Implementations and conformance registry | README-registry.md | obsp-registry | registry | OIP-0023, OIP-0008 |
Discovery (/.well-known/obsp, federated index, UNI resolution) |
README-discovery.md | obsp-discovery | discovery | OIP-0016, OIP-0008 |
| Credential status (Bitstring Status List) | README-status.md | obsp-credential-status | status | OIP-0015 |
| Transparency log, with witness cosigning of its tree heads (reference-log feature) | README-log.md | obsp-transparency-log | log | OIP-0008 (tree heads); RFC 9162; witnesses: none (no draft) |
Production services
reference/rust/obsp-services answers the same routes with the same
documents on axum and PostgreSQL, and adds key management, identity and access, an admin API and an audit log. These
Python services stay the reference: parity/run_parity.py runs their flows and vectors against
both and compares the answers (make rust-services). For that run only, OBSP_TEST_CLOCK=<RFC 3339 time> fixes the
services’ clock.
Why Python, beside the conformance runner
The services are Python (standard library http.server, plus jsonschema, PyYAML from requirements.txt) rather
than a new Rust crate, for three reasons. They reuse the conformance runner’s code unchanged: its RFC 8032 Ed25519,
deterministic CBOR and OIP-0008 envelope (envelope.py) and its
RFC 9162 tree hash, audit paths, inclusion check and consistency proofs (tlog.py), so
a report the runner signs and a receipt it issues verify here with the same code. They validate with the protocol’s own
JSON Schemas through the Python SDK. And they run in make check, which has no Rust toolchain in continuous
integration, so the tests and the smoke script gate every push.
Shared behaviour
obsp_public/web.py gives every service the same edges:
- Errors are RFC 9457 problem documents valid against
error-problem; no traceback reaches a caller. - Input limits: request target at most 2048 bytes (414), a body size limit per service (413), a
Content-Lengthon every body (411), JSON nested at most 64 levels. - Rate limiting: a token bucket per client address (
--rate,--burst; writes cost more than reads); 429 withRetry-AfterandretryAfterSeconds. - Operator token for every write except registry submissions (which are authenticated by their signatures): the
service reads
OBSP_OPERATOR_TOKENat start-up, keeps only its SHA-256 digest and compares in constant time. Without it the service is read-only. - Structured logs: one JSON line per request on standard error (time, service, method, route template, status, duration, sizes, request id). No client address, query string, header or body is logged.
GET /healthzandGET /metrics(Prometheus text exposition: requests by route template and status, time spent, rate-limited and rejected requests, service gauges).- Binds
127.0.0.1unless the operator names another host. There is no TLS: put a service behind the operator’s own TLS terminator and access control before exposing it.
Draft contracts are read straight from the proposals’ patches by obsp_public/drafts.py, so
nothing is copied and nothing drifts; when a proposal is accepted the live schema is used instead.
Run
export PYTHONPATH=services/public-services:sdk/python/src:services/conformance-runner:.
export OBSP_OPERATOR_TOKEN=... # optional; enables writes
python3 -m obsp_public log serve --data var/log --key log-key.json [--witnesses policy.json] --port 8101
python3 -m obsp_public registry serve --data var/registry --key-records keys/ --key log-key.json --port 8102
python3 -m obsp_public discovery serve --document authority.json --peers peers.json [--offline] --port 8103
python3 -m obsp_public status serve --state var/status.json --key status-key.json \
--issuer uni:grid-operator:site001 --list participants --port 8104
python3 -m obsp_public sign --key key.json --in doc.json --out signed.json [--member signature|extensions]
python3 -m obsp_public witness cosign --key witness-key.json --state var/witness.json --log-jwk log.jwk \
--head sth.json [--proof consistency.json] [--out cosigned.json]
python3 -m obsp_public witness check --log-jwk log.jwk --policy policy.json --head cosigned.json
python3 -m obsp_public witness compare --log-jwk log.jwk --head a.json --head b.json [--proof p.json]
A key file is {"alg": "ed25519", "seed": "<32 bytes, unpadded base64url>", "kid": "uni:key:..."}, as for the runner.
Which keys an operator uses, and who holds them, is the operator’s decision.
Tests and smoke test
services/public-services/tests/test_public_*.py, loaded into make test by tests/test_public_services.py: Merkle
consistency proofs at every size, the log store and its tamper checks, each registry rule, the discovery rules against
the OIP-0016 vectors and negative fixtures, the witness (its checks and persisted state, k-of-n policies, split-view
detection, the cosignature routes, the shared vectors also run by obsp-verify), the status lists against the OIP-0015 schema and example, the limits, the
route parity with the OpenAPI documents, and smoke.py, which starts every service from its command line
on 127.0.0.1 and runs one flow through all four (make services-smoke).