openwrt-iac / uapi / docs / 4.0.1 / uapi deprecations log
Canonical list of wire-surface fields that have been deprecated but are still accepted during a deprecation window. Each entry lives here from the release that deprecated it through the release that removes it.
A field is in the table below if and only if it is currently accepted-but-deprecated. Once removed (in a major release), the entry moves to the "Removed in past releases" section. A breaking change that is not a removal or a rename, such as a value that a write now refuses or a read that changes, needs no announcement here. The migration doc of the next major and its CHANGELOG entry describe it.
Policy: a deprecation in a minor release means both forms (old and new) are
accepted; the old form is marked deprecated: true in build/openapi.json so
codegen tools surface a warning; the removal of the old form happens no sooner
than the next major. One exception to the marker, explained under "How to
migrate": a field that is not disappearing but losing only its write half cannot
say so through that flag, because it has no read/write split.
| Field | Replaced by | Deprecated since | Removal target | Migration |
|---|---|---|---|---|
Every entry above must also appear in the published spec's own description,
under
"Upcoming in v4". That is checked by make lint-doc-refs.
A field belongs in this section if and only if it is currently
accepted-but-deprecated. Once
removed in a major it moves to Removed in past releases below.
For each deprecated input field your client sends, switch to the replacement column. uapi accepts both during the window, so the migration can be staged: update writes first, observe nothing breaks, then drop the old field. Reads do not change during the window. When the release that opens a window also changes a read, its row says so.
The OpenAPI spec at /openapi.json carries deprecated: true on every
deprecated request field that disappears as a whole. Codegen tools that respect
that flag (openapi-generator, oapi-codegen, etc.) will emit warnings in the
generated client when you regenerate; that's the signal your client has surface
area to migrate.
A field that stays and loses only a write form carries no flag, and deliberately
so. OpenAPI's deprecated is a property-level flag with no read/write split, so
setting it would tell a generator the field was disappearing.
network/interfaces.ipaddr was the first case: it survived as a read field and
lost its write half, and the v3 spec says it precisely, with readOnly: true in
the response schema and no ipaddr at all in the request one.
network/interfaces.ip6prefix was the second case: it kept its array form and
lost only the string form on write in 4.0.0. While a window is open, the
announcement lives in this table and in the field's own description, which is
the honest signal available.
v4 ships every change that 3.x announced here, and docs/migration-v3-to-v4.md
says what each one changes for a client. Since 4.0.0 such a change needs no
announcement. A maintainer can still list one here ahead of v5, mirrored in the
published spec's own "Upcoming in v5" block, which make lint-doc-refs keeps
in sync with this section by count.
| Field | Replaced by | Deprecated since | Removed in |
|---|---|---|---|
network/interfaces.ip6prefix (a string on write) |
an array of prefixes | 3.2.0 | 4.0.0 |
A space-separated string is refused with 422 invalid_type. Send an array,
which is also what the read has returned since 3.2.0. A one-element array is
still stored as a scalar, which netifd, 6rd, map and 464xlat read the same way,
so the stored form does not change. No deprecated: true flag was ever set on
it, for the reason given under "How to migrate".
Also removed in 4.0.0, without an announcement in 3.x:
openvpn/instances, the whole endpoint, with the paths openvpn and
openvpn:instances of the scope tree. On OpenWrt main, the only platform
of 4.x, the openvpn package runs a tunnel as a netifd protocol and has no init
script, so the endpoint read sections that nothing runs and each write
answered 503 init_script_missing. A tunnel is now a network/interfaces
section with proto: "openvpn". The policy above asks for a deprecation in a
3.x minor first. v3 takes no more releases, and the path cannot work on the
platform of 4.x, so the maintainer made an exception (#466).
docs/migration-v3-to-v4.md has the field map and what a stored token does.| Field | Replaced by | Deprecated since | Removed in |
|---|---|---|---|
network/interfaces.name (request input) |
network/interfaces.id |
2.2.0 | 3.0.0 |
dhcp/hosts.mac (request and response) |
dhcp/hosts.macs |
2.5.0 | 3.0.0 |
dhcp/hosts.mac_aliases (request and response) |
dhcp/hosts.macs |
2.5.0 | 3.0.0 |
Also removed in 3.0.0, announced as response-shape changes rather than as ledger rows because neither survived as a read:
vnstat/interfaces, the whole endpoint. It modelled config interface
sections, which
vnstat never reads. Use the interfaces array on vnstat/config, remembering
that the values
differ in kind: the dead endpoint took uci interface names (lan), vnstat
wants device names
(br-lan).The 27 fields that wrote a uci option no OpenWrt component reads, in
mwan3/globals,
vnstat/config, lldpd/config, unbound/server, usteer/config and
prometheus_node_exporter_lua/config. Writes carrying them were already
ignored; what changes
is the read side, since each was returned with a default: annotation. The
per-field reasons
are in the 2.5.0 announcement, preserved in that release's changelog entry.
List-valued fields read back null, not [], when the uci key is absent.
uci cannot
store an empty list, so [] already meant "absent" and distinguished nothing.
It also lets a
list field carry x-uapi-clear-on-omit, which the old shape made impossible.
The request and
response envelopes keep [], where it means empty rather than absent.
network/interfaces.ipaddr lost its write half. It is readOnly in the
response schema
and absent from the request one. It still reads as the first entry of the uci
list ipaddr;
send ipaddrs.
dhcp/hosts.tag is array-only in both directions. The string form existed
only because
the 2.4.1 spec declared one.managed left the request half of every resource schema. It is derived
from uci's
.anonymous flag and no write path ever read it.<Name>Request and <Name>Response. This is what makes the three above
expressible: one
schema serving both directions could not say that a field is readable but not
writable.See docs/migration-v2-to-v3.md for the full upgrade path.