Expand description
Shared wire types for the ZLayer platform.
This crate is the SDK-facing types crate: API DTOs, OCI image
references, and other serde-friendly wire shapes consumed by both
the daemon and clients. It is intentionally lightweight — no axum,
no tokio, no reqwest. Heavier server-side abstractions live in
zlayer-api, zlayer-core, and friends.
Re-exports§
pub use scratch::Scratch;pub use scratch::ScratchFile;
Modules§
- api
- Wire-type modules. Each maps to one logical area; downstream crates
import via
pub use zlayer_types::<area>::.... - auth
- Auth wire DTOs.
- builder
- Shared types for build-backend dispatch and sidecar wire protocol.
- client
- Client-facing wire types shared between the
ZLayerdaemon and SDK clients (CLI,zlayer-docker,zlayer-py, future language SDKs). - cluster
- Daemon-level cluster mode selection.
- image_
ref_ serde - Serde helpers to (de)serialize an
ImageReferenceas its OCI-spec canonical string form ([host[:port]/]name[:tag][@digest]) instead of the default struct shape{registry, repository, tag, digest}. - jwt
- JWT claims and related auth wire types.
- local_
image - Local image-store metadata sidecar.
- logs
- Canonical container-logs wire codec shared by
zlayer-api(the serializer) andzlayer-docker(the parser that re-frames our NDJSON as Docker logs). - nat_
wire - Wire-safe NAT-traversal DTOs shared across the daemon / overlayd boundary.
- overlay
- Overlay-network configuration types shared across
ZLayercrates. - overlayd
- IPC wire protocol between the main
zlayerdaemon andzlayer-overlayd. - package_
index - Wire types for the ZLayer package index (
packages.zlayer.dev). - scratch
- RAII scratch directory and file types anchored at the
ZLayerdata dir’stmp/subdirectory. Constructed via [zlayer_paths::ZLayerDirs::scratch_dir] and [zlayer_paths::ZLayerDirs::scratch_file]. These wraptempfile’s handles so call sites can name their return type without pulling intempfiledirectly. - secrets
- Secrets domain wire/storage types.
- spec
ZLayerV1 Service Specification- storage
- Storage
Stored*wire types. - toolchain_
lock - Wire types for the toolchain lockfile (
zlayer-toolchains.lock).
Structs§
- Image
Ref - Image reference that preserves the user’s RAW input string alongside
the parsed canonical
ImageReference. - Image
Reference - Canonical OCI image reference.
Functions§
- image_
ref_ candidates - Candidate
(name, reference)spellings for the LITERAL image string, in priority order, for cross-spelling lookups in a local store. - image_
str_ is_ unqualified - Standalone form of
ImageRef::is_unqualifiedoperating on a raw string.