1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
//! # spacedb-meter — SpaceDB Layer 6 (metering & settlement)
//!
//! SpaceDB **measures**; it does not price or pay. This crate computes the three
//! resource amounts deterministically — storage ([`Usage::storage`], bytes × time ×
//! replica_count), compute ([`Usage::compute`], fuel + invocations), and transit
//! ([`Usage::transit`], bilaterally-corroborated served bytes) — accumulates them
//! in a [`MeterLedger`], and drains them into amounts-only [`UsageClaim`]s.
//!
//! Pricing ([`RateCard`]), the agent spend cap ([`Budget`]), and pre-deploy cost
//! estimates are open-core too. **Settlement is the seam**: the bundled
//! [`LocalSettlement`] is enough for a self-hoster, while a host implements
//! [`Settlement`] over its own money plane — for MATA that is the existing
//! `UsageClaim → Maestro counter-sign → EarningRecord → Iron Bank` loop — so
//! SpaceDB usage settles through it without ever depending on it.
//!
//! Open-core (MIT). No `spacedb-*` / `mata-*` dependencies.
pub use ;
pub use ;
pub use UsageClaim;
pub use RateCard;
pub use Budget;
pub use ;
pub use ;
/// Compiles the README's examples as doctests, so the documented API can never
/// drift from the real one. Not part of the public API, and not rendered into
/// the crate docs — it exists only under `cargo test --doc`.
;