---
title: "una.report/2"
url: https://una-lang.org/en/docs/agents/schemas/una.report-2/
release: v0.4.0
source: https://github.com/una-lang/una/blob/v0.4.0/docs/spec/13-diagnostics-and-abi.md
---

# una.report/2

`una.report/2` is a JSON document of the Agent ABI, defined in `spec/13 §6`. It replaced `una.report/1`. This page gathers what the specification says about it at v0.4.0: each section whole where it opens with the document, and otherwise the parts that name it.

## Build report

From `spec/13 §6`, in full.

`una report --json` produces:

```json
{
  "schema": "una.report/2",
  "package": { "name": "events-example", "version": "0.1.0", "profile": "app" },
  "edition": { "name": "0.1", "preview": false },
  "lock": { "solver_version": "...", "hash": "..." },
  "proven": { "semantic": 14, "security": "by typing", "authority": "by typing" },
  "obligations": { "proven": 14, "refuted": 0, "unknown": 0, "cached": 14 },
  "authority": [ { "function": "events.checkin.check_in", "public": true, "uses": ["@registrations: Registrations[find]", "@audit: Audit[record]", "@keys: Keys[hmac]"], "inferred": false } ],
  "handler_authority": [],
  "dependencies": [],
  "information": { "policy_calls": [ { "policy": "events.keys.attendee_key", "purpose": "...", "owner": "privacy", "site": { "file": "...", "start": { "line": 30, "col": 13 } } } ] },
  "escapes": { "checked": [ { "module": "events.types", "count": 1, "budget": 1 } ] },
  "assumptions": [ { "capability": "events.checkin.Registrations", "operations": ["find"], "ensures": [] } ],
  "premises": [ { "id": "H1", "statement": "...", "used_for": [] }, { "id": "H2", "statement": "...", "used_for": [] }, { "id": "H3", "statement": "...", "used_for": [] }, { "id": "H4", "statement": "...", "used_for": [] }, { "id": "Env", "statement": "...", "used_for": [] }, { "id": "H5", "statement": "...", "used_for": [] } ],
  "tcb": { "trusted_modules": [ { "module": "events.keys", "lines": 17 } ], "host_capabilities": ["Keys"], "solver": "z3 <version>", "proof_cache": ".una/cache/", "proof_cache_key": "~/.una/proof-cache.key", "registries": [], "dependency_trust": [], "serve_grants": [], "server": null, "tls": null },
  "requirements": [ { "id": "EVENTS_3", "status": "active", "derived": ["events.seating.availability"] } ],
  "coverage": { "pub_functions": 3, "with_ensures": 1, "with_derived_from": 1, "trivial_ensures": 0 },
  "native": { "target": "aarch64-apple-darwin", "arbitrary_precision": ["events.seating.clamp_seats.raw"], "kernels": { "variants": ["baseline"], "fma_allowlist": ["una_core::dense::variants::x86_64_v3", "una_core::dense::variants::x86_64_v4"] } },
  "out_of_model": ["timing", "termination and divergence", "resource consumption and allocation", "stack exhaustion", "external systems beyond declared signatures", "races between the check and the use of a file path", "hard links", "order of effects across concurrent tasks", "the time of a host stop", "interference of the host's load with the timing of an expression", "uncatchable termination", "waits at limits and at `start`", "which branch of `first of` wins, beyond its label"],
  "warnings": []
}
```

`trivial_ensures` counts `ensures` clauses the solver proves valid without any hypothesis (for example `ensures true`); they are reported as missing contracts.

`una report [path]` checks the package at tier 1. When the checks report diagnostics, it prints them as `una check` does; otherwise it prints the report, and exits with code 1 when an obligation is not proven. Its sections, in the order of the example (ADR 0034):

- `package`: the name and version of `una.toml`, or of `ita.una` from edition `0.4`; a single file is named after its module, with version `0.0.0`. (v0.3, ADR 0109 rules 4 and 7.) Then `profile`, `"app"` or `"systems"`, and `max_memory`, the declared memory budget in MiB, only when the manifest declares one; the human form prints them as `profile: systems` and `max memory: 256 MiB`. Both keys are additive, and the schema stays `una.report/2`.
- `edition` (ADR 0121 rule 8): `name`, the package's edition, and `preview`, whether this release serves it as a preview (§7); the human form prints `edition: 0.1`, or `edition: 0.5 (preview)`. The key is additive, and the schema stays `una.report/2`. This release does not emit rule 8's third key, `preview_constructs`, each construct of a preview edition the package uses: it lands with the edition ledger of ADR 0121 rule 9 (#1752).
- `lock`: the solver version, and the hex SHA-256 of the lock's contents (for a single file, of the default lock's text; from edition `0.4`, of `ita.lock` as written, `spec/30 §7`).
- `proven`: the number of proven obligations as `semantic`; `security` and `authority` are `"by typing"`. `obligations`: the counts by status, then `cached`, how many of these results came from the proof cache of `spec/12 §9` rather than from the solver (ADR 0041).
- `authority`: every function of the package with `uses`, by qualified name, with `public`, its `uses` as written in a header, and whether they are inferred. (v0.2, ADR 0062.) A `uses of p` clause is listed as written, as `"of each"`. The effects of a lambda count for the function that writes it, within its `uses`.
- `handler_authority` (v0.2, ADR 0081), after `authority`: every handler of the package with `uses` clauses, by qualified name, with `capability`, the capability it implements by its qualified name, `public`, and its `uses` as written in its header, in the form of `authority`. A handler's `uses` are always written, so an entry has no `inferred`. The key is additive, and the schema stays `una.report/2` (ADR 0076).
- `dependencies` (edition `0.4`, ADR 0122 rule 58), after `handler_authority`: every package of the program other than the root, in name order, with its source, digest, the ceiling each dependent writes for it, its effective ceiling, the authority its code uses, and the trust it adds (`spec/30 §12` rule 8). A package with no dependencies has `[]`. The key is additive, and the schema stays `una.report/2`.
- `information.policy_calls`: every call of a policy, in source order, with the policy, its purpose and owner, and the site.
- `information.timing` (edition 0.4, ADR 0116 rule 21), after `policy_calls`: each `for ever within`, in source order, as `{"construct": "for ever within", "function": "m.f", "label": "internal", "site": {...}}`, with the timing label of its body (`spec/26 §7`), and (ADR 0117 rule 13) each `e within d` whose timing label is above `public`, as `{"construct": "within", ...}`, with the timing label of `e` (`spec/27 §5`), and each `first of` whose timing label is above `public`, as `{"construct": "first of", ...}`, with the join of the timing labels of its branches (`spec/27 §6`), and (#1708) each check point whose count data above `public`, at most `internal`, decide in a package whose program can run started tasks, as `{"construct": "task switch", ...}`, with that label (`spec/27 §8` rule 5), and (ADR 0116 amendment of 2026-11-09, accepted, #898) each reading of `Clock.now` whose timing label `L_clk` is above `public`, as `{"construct": "Clock.now", ...}`, with that label (`spec/14 §3`), all in source order. A `task switch` or a `Clock.now` in a handler's operation body names the handler, `m.h`, as its `function`. The report of a package that its diagnostics refuse has no `task switch` entry: the list is of an accepted package. The key is absent when the list is empty, so the reports of earlier editions do not change, and the schema stays `una.report/2`.
- `escapes.checked`: every module that uses `checked`, with the count and the budget of `una.toml`.
- `assumptions`: every capability the package declares, with its operations and their `ensures` clauses as `op: clause`.
- `premises` (ADR 0094 rule 5), after `assumptions`: the premises on the host that the acceptance of a package rests on, the Assumed zone's part that the deployment, not the package, must make true. They are assumed, never proven: neither `una check` nor the formal model establishes them. Each is an object `{"id": "H1", "statement": "...", "used_for": [...]}`, in this order, with the statement as written here:
  - **H1:** whether a read fails depends on the path and on which files exist, not on their content.
  - **H2:** whether a write fails, and which files it leaves, does not depend on what it writes.
  - **H3:** a response does not depend on the program's type annotations (the host is given text).
  - **H4:** every successful HTTP response is a `Response` of `spec/24`.
  - **Env:** the environment variables that exist are the same in both runs; their values may differ.
  - **H5:** what an operation answers through a binding where it is labeled l′, and whether it fails, is a function only of the arguments and of the part of the host state at or below l′.

  A premise is listed with what the package uses it for, in `used_for`: for H1 to H4 and `Env`, the operations of host capabilities (`spec/14 §3`, not a package capability of the same name) that the `uses` of the package's functions and handlers list and that the premise covers, as `Capability.op` in name order (`Files.read` for H1, `Files.write` for H2, every operation of `Http` for H3 and H4, every operation of `Env` for `Env`); for H5, every operation that the `uses` of a function's or a handler's header labels with `gives`, as `module.function: @binding.op gives label` or `module.handler: ...`, functions first and then handlers, each by module and in declaration order. An operation is listed when a header lists it, whether or not the body calls it, so `used_for` may over-list, never under-list. A premise the package does not use is listed with `[]`: the set of premises is the model's, not the package's. A labeled operation is accepted on the checker's rules alone until the formal model covers operation labels (#563, `docs/plan/formal-track-status.md`). Without `--json`, the section prints as `assumed of the host:`, one line per premise, `H1: used for Files.read`, or `used for nothing`. The key is listed for a package of every edition, since H1 to H4 and `Env` are premises of the model in each; it is additive, and the schema stays `una.report/2` (ADR 0076).
- `tcb`: the trusted modules with their line counts, the host capabilities the package's functions and handlers use (handlers since ADR 0081; `HttpServer` also for a package that serves, edition 0.4 preview, `spec/31 §7` rule 6), the solver as `z3 <version>`, and `proof_cache`, the proof cache of the package, `.una/cache/`. In v0.1 its entries were trusted, not authenticated (ADR 0041). (v0.2, ADR 0064.) `proof_cache_key` follows: the key file that authenticates the cache's entries and is in the Trusted zone. It is `~/.una/proof-cache.key` for the default, or the value of `UNA_PROOF_KEY` as given, and `null` when the run used no cache. `registries` and `dependency_trust` follow (ADR 0122 rule 58, `spec/30 §12` rule 8): each registry source of the program with the digest of its root metadata, and the trusted modules of dependencies that the root consented to, with their line counts, by package; `trusted_modules` keeps the root's own. (v0.4, ADR 0124 rules 7 and 28.) `solver_build` follows, an object with `source_sha256` and `library_sha256`, the digests of the Z3 source tarball and of the library built into `una`, present when `una` has the solver built in; then `solver_confinement`, `"own"` when the solver children confined themselves and `"outer"` when an outer sandbox did, present when a child ran; and, under `"outer"`, `solver_outer_denied`, the probes of the fixed list of ADR 0124 rule 7 (as its amendment of 2026-11-01 states it) that the outer sandbox denies, in that order, each named by its operation and, when it has one, its filter or place, such as `network-outbound`, `network-outbound tcp 127.0.0.1`, `network-bind unix-socket`, `file-write-finderinfo /Users` or `file-write-data (home)`. A probe is listed when it is denied under the outer sandbox, by the profile or by the system (the system denies some writes at some places whatever the profile), so the list does not say the profile denied a probe. Under `"outer"` the list names every probe that the minimum requires to be denied, and may also name recorded ones (reads, `file-revoke`, `process-exec*`, `process-fork`). The keys are additive, and the schema stays `una.report/2`.
- `requirements`: every requirement, by identifier, with its status and the functions derived from it.
- `coverage`: `pub_functions` counts the public functions, `with_ensures` those with at least one `ensures` clause that is not trivial, `with_derived_from` those with a `derived from` clause, and `trivial_ensures` the trivial clauses of public functions. An `ensures` clause is trivial when the solver proves it with no hypothesis, its parameters and `result` unconstrained: one more query per clause of a public function, cached like the others; a solver that cannot answer these queries gives U5003 or U8001 instead of the report.
- `native` (v0.2, ADR 0055): `target`, the host target of `una build` (`spec/16 §1`), and `arbitrary_precision`, the bindings whose `Int` the native backend keeps at arbitrary precision: every parameter and result of type `Int` of the package's functions whose refinements do not prove a range within a machine word, as `module.function.parameter` and `module.function.result` (NB-3, FW-1). A parameter's refinements are proven by each call and a result's by the function, so `clamp_seats`, whose result is `Seats = Int in 0..5000`, lists only its parameter. `kernels` (ADR 0120 rules 56 and 57, and its Appendix A amending ADR 0106) follows: `variants`, the variants of the dense kernels that an executable for the host target holds and chooses among once at start, by the processor's features (`baseline`, `x86_64_v3` and `x86_64_v4` on x86-64; `baseline` elsewhere), and `fma_allowlist`, the demangled symbol prefixes inside which an x86-64 release artifact may hold an FMA instruction, which the FMA disassembly gate of `docs/release-gates.md` reads. The allowlist is the same on every host, since it describes the x86-64 artifacts the gate scans. The key is additive, and the schema stays `una.report/2`. Without `--json`, they print as the lines `kernels:` and `fma allowlist:`. (v0.4, ADR 0124 rules 14 and 28, step 2.) `runtime_sha256` follows, the SHA-256 of the runtime library built into `una`, which every executable it builds links (`spec/16 §2` rule 8), present when `una` has the runtime built in, so absent in a development build; without `--json` it prints as the line `runtime sha256:`. The key is additive, and the schema stays `una.report/2`. (v0.4, ADR 0124 rule 28, step 3.) `linker` follows, the linker of `una build` on the host: `una <version>` where `una` links by itself (`spec/16 §6`), `cc` where the system linker links; without `--json` it prints as the line `linker:`. Then `debuggable`, whether an executable that `una build` makes without `--debuggable` lets a debugger attach: `false` where the internal linker signs it with the hardened runtime (`spec/16 §2` rule 9), `true` where the system linker links it. Both keys are additive, and the schema stays `una.report/2`.
- `generic_results` (v0.2, ADR 0067), after `native`: every public generic function of the package, by qualified name, with its `result_labels` as `una contract` prints them, or `[]` for one whose summaries are all empty (`spec/07 §7` rule 8), and its `of_raises`, as `una contract` prints them. The key is additive, and the schema stays `una.report/2`.
- `out_of_model`: the channels outside the model of `spec/07 §1`, in this order: timing, termination and divergence, resource consumption and allocation, stack exhaustion, external systems beyond declared signatures, races between the check and the use of a file path, hard links, order of effects across concurrent tasks, the time of a host stop, interference of the host's load with the timing of an expression, uncatchable termination, waits at limits and at `start`, and which branch of `first of` wins, beyond its label (`spec/14 §3` for hard links; v0.2, ADR 0065 and `spec/19 §3` for the order of effects, which the list gained with the release that implements `spec/19`; ADR 0116 rule 21 and `spec/26 §6` for the time of a host stop, the interference of the host's load and uncatchable termination, and ADR 0117 rule 13 and `spec/27 §6`, `§7`, `§9` and `§10` for the waits at `start`, at the limits of grants and at a `limiter`, and the winner of `first of`, additions within `una.report/2`). (Edition 0.4 preview, ADR 0123 rule 22, `spec/31 §7` rule 6.) A package with a `serve:` grant or a `serve` section gains, at the end of `out_of_model`, the three entries of the server.
- `tcb.serve_grants`, `tcb.server` and `tcb.tls` (edition 0.4 preview, ADR 0123 rule 22), after the other keys of `tcb`: each `serve:` grant with its address, scheme, limits and whether it checks `Host`, `[]` for none; the host's server code, `"una-http/serve"`, for a package that serves, else `null`; and `null` while no TLS server is built (`spec/31 §7` rule 6).
- `warnings` (edition 0.4 preview, ADR 0123 rule 22), after `out_of_model`: the report's warnings about the package's `serve:` grants, `[]` when none (`spec/31 §7` rule 6). The keys are additive, and the schema stays `una.report/2`.

Without `--json`, the same sections print as labeled lines.

(v0.2, ADR 0055.) The report is `una.report/2` from the first release that ships `una build` (`spec/16`), `v0.2.0-alpha.1`: it added the section `native`, and the `out_of_model` entry "interpreter stack exhaustion" became "stack exhaustion". Releases up to `v0.1.2` write `una.report/1`.

## The host-driven form: `serve`

From `spec/31 §7`, the parts that name this schema.

6. **The report** (`spec/13 §6`, ADR 0123 rule 22), additions within `una.report/2`, for a package with a `serve:` grant or a `serve` section, which **serves**:
   - `tcb.host_capabilities` lists `HttpServer` when the package serves, or when a function or handler of it uses `HttpServer`.
   - `tcb.serve_grants` lists each `serve:` grant of `run grants`, in order, as `{"address": "127.0.0.1:8080", "scheme": "http", "limits": {...}, "checks_host": true}`: `limits` holds every item of §2's table but the TLS files and `hosts`, with its default applied, sizes in bytes, times in seconds, a rate as `"N/second"`, and `null` for `none` or no rate; `checks_host` is `false` for `hosts=*`. A package that serves nothing has `[]`.
   - `tcb.server` is `"una-http/serve"`, the server code of the host, for a package that serves, and `null` otherwise; `tcb.tls` is `null` while no TLS server is built (§6 rule 10).
   - `out_of_model` gains, at its end: "what a server's peers send in reaction to its timing, and which requests its full queues refuse"; "what a peer receives when the host's deadlines cut an exchange"; and "which request a call of `next` receives when several serve threads hold requests, which the timing of every task of the run and of the serve threads decides" (ADR 0123 S4 amendment, section E).
   - `warnings`, a new key after `out_of_model`, a list of sentences, `[]` when none, in the order of the grants: a plain `http` grant on an address that is not loopback, a wildcard included; a grant with `hosts=*`; with `peer=none`; with `peer_buffers=none`; with `tls12`. Warnings appear in the report only.
   - The human form prints `server:` in the `tcb` lines, a `servers:` section with one line per grant, and each warning as a `warning:` line after `out of model`.
